From 98bb1f27817ddbfef0bd6dee99e33110dd8570cf Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Wed, 28 Jun 2017 14:34:53 +0200 Subject: [PATCH] pkg: add prepare targets --- pkg/nordic_softdevice_ble/Makefile | 4 +++- pkg/pkg.mk | 4 +++- pkg/tlsf/Makefile | 4 +++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/pkg/nordic_softdevice_ble/Makefile b/pkg/nordic_softdevice_ble/Makefile index 27e380fec5..4b9ae428b1 100644 --- a/pkg/nordic_softdevice_ble/Makefile +++ b/pkg/nordic_softdevice_ble/Makefile @@ -12,10 +12,12 @@ SOFTDEVICE := components/softdevice/s1xx_iot/s1xx-iot-prototype3_nrf52_softdevic BLE_6LOWPAN_LIB := components/iot/ble_6lowpan/lib/ble_6lowpan.a MODULE_MAKEFILE := $(PKG_DIR)/Makefile.module -.PHONY: all clean distclean +.PHONY: all prepare clean distclean all: $(BINDIR)/ble_6lowpan.a $(BINDIR)/softdevice.hex +prepare: $(PKG_SRCDIR)/.extracted + $(BINDIR)/ble_6lowpan.a: $(PKG_SRCDIR)/.extracted cp $(PKG_SRCDIR)/$(BLE_6LOWPAN_LIB) $@ diff --git a/pkg/pkg.mk b/pkg/pkg.mk index 937811e3a8..b8166f9f32 100644 --- a/pkg/pkg.mk +++ b/pkg/pkg.mk @@ -4,7 +4,9 @@ PKG_DIR?=$(CURDIR) PKG_BUILDDIR?=$(PKGDIRBASE)/$(PKG_NAME) -.PHONY: git-download clean +.PHONY: prepare git-download clean + +prepare: git-download ifneq (,$(wildcard $(PKG_DIR)/patches)) git-download: $(PKG_BUILDDIR)/.git-patched diff --git a/pkg/tlsf/Makefile b/pkg/tlsf/Makefile index cc32ba1ff8..7d63aff2c3 100644 --- a/pkg/tlsf/Makefile +++ b/pkg/tlsf/Makefile @@ -8,10 +8,12 @@ PKG_DIR=$(CURDIR) PKG_BUILDDIR=$(PKGDIRBASE)/$(PKG_NAME) PKG_SRCDIR=$(PKG_BUILDDIR)/src -.PHONY: all clean distclean +.PHONY: all prepare clean distclean all: $(PKG_SRCDIR)/$(PKG_NAME).a +prepare: $(PKG_SRCDIR)/Makefile + $(PKG_SRCDIR)/$(PKG_NAME).a: $(PKG_SRCDIR)/Makefile $(Q)make -C $(