mirror of
https://github.com/hak5/wifipineapple-openwrt.git
synced 2025-10-29 16:57:19 +00:00
next round of cleanup, convert target/ - make -j works now ;)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@8242 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (C) 2006 OpenWrt.org
|
||||
# Copyright (C) 2006-2007 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
@@ -12,6 +12,7 @@ include $(INCLUDE_DIR)/depends.mk
|
||||
STAMP_PREPARED:=$(PKG_BUILD_DIR)/.prepared_$(shell find ${CURDIR} $(PKG_FILE_DEPEND) $(DEP_FINDPARAMS) | md5s)
|
||||
STAMP_CONFIGURED:=$(PKG_BUILD_DIR)/.configured
|
||||
STAMP_BUILT:=$(PKG_BUILD_DIR)/.built
|
||||
override MAKEFLAGS=
|
||||
|
||||
include $(INCLUDE_DIR)/quilt.mk
|
||||
|
||||
|
||||
@@ -11,6 +11,8 @@ include $(INCLUDE_DIR)/host.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
include $(INCLUDE_DIR)/prereq.mk
|
||||
|
||||
override MAKEFLAGS=
|
||||
|
||||
GENERIC_LINUX_CONFIG:=$(GENERIC_PLATFORM_DIR)/config-$(shell [ -f "$(GENERIC_PLATFORM_DIR)/config-$(KERNEL_PATCHVER)" ] && echo "$(KERNEL_PATCHVER)" || echo template )
|
||||
LINUX_CONFIG_DIR ?= ./config$(shell [ -d "./config-$(KERNEL_PATCHVER)" ] && printf -- "-$(KERNEL_PATCHVER)" || true )
|
||||
LINUX_CONFIG ?= $(LINUX_CONFIG_DIR)/default
|
||||
@@ -172,6 +174,7 @@ oldconfig menuconfig: $(STAMP_PREPARED) FORCE
|
||||
$(SCRIPT_DIR)/config.pl '>' $(GENERIC_LINUX_CONFIG) $(LINUX_DIR)/.config > $(LINUX_CONFIG)
|
||||
|
||||
install: $(LINUX_DIR)/.image
|
||||
$(MAKE) -C image install
|
||||
|
||||
clean: FORCE
|
||||
rm -f $(STAMP_DIR)/.linux-compile
|
||||
@@ -184,4 +187,7 @@ rebuild: FORCE
|
||||
fi
|
||||
@$(MAKE) compile
|
||||
|
||||
image-prereq:
|
||||
$(MAKE) -C image prereq
|
||||
|
||||
prereq: image-prereq
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (C) 2006,2007 OpenWrt.org
|
||||
# Copyright (C) 2006-2007 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
@@ -24,6 +24,7 @@ include $(INCLUDE_DIR)/package-defaults.mk
|
||||
include $(INCLUDE_DIR)/package-dumpinfo.mk
|
||||
include $(INCLUDE_DIR)/package-ipkg.mk
|
||||
|
||||
override MAKEFLAGS=
|
||||
export CONFIG_SITE:=$(INCLUDE_DIR)/site/$(REAL_GNU_TARGET_NAME)
|
||||
|
||||
ifeq ($(DUMP)$(filter prereq clean refresh update,$(MAKECMDGOALS)),)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (C) 2006 OpenWrt.org
|
||||
# Copyright (C) 2006-2007 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
@@ -47,3 +47,4 @@ define RequireCommand
|
||||
$$(eval $$(call Require,$(1),$(2)))
|
||||
endef
|
||||
|
||||
.NOTPARALLEL:
|
||||
|
||||
@@ -24,7 +24,8 @@ define subdir
|
||||
$(call warn,$(1),d,BD $(1)/$(bd))
|
||||
$(foreach target,$(SUBTARGETS),
|
||||
$(call warn_eval,$(1)/$(bd),t,T,$(1)/$(bd)/$(target): $($(1)/$(bd)/$(target)) $(call $(1)//$(target),$(1)/$(bd)))
|
||||
@+$$(MAKE) -j1 -C $(1)/$(bd) $(target)
|
||||
+$$(MAKE) -j1 -C $(1)/$(bd) $(target)
|
||||
$$(if $(call debug,$(1)/$(bd),v),,.SILENT: $(1)/$(bd)/$(target))
|
||||
|
||||
# legacy targets
|
||||
$(call warn_eval,$(1)/$(bd),l,T,$(1)/$(bd)-$(target): $(1)/$(bd)/$(target))
|
||||
@@ -36,12 +37,18 @@ endef
|
||||
# Parameters: <subdir> <name> <target>
|
||||
define stampfile
|
||||
$(1)/stamp-$(3):=$(STAGING_DIR)/stampfiles/.$(2)_$(3)
|
||||
$(call rdep,$(1),$$($(1)/stamp-$(3)),)
|
||||
$(if __rdep_$(1),,
|
||||
$(call rdep,$(1),$$($(1)/stamp-$(3)),)
|
||||
__rdep_$(1):=1
|
||||
)
|
||||
|
||||
$$($(1)/stamp-$(3)):
|
||||
@+$(MAKE) $(1)/$(3)
|
||||
@+$(MAKE) $$($(1)/flags-$(3)) $(1)/$(3)
|
||||
@mkdir -p $$$$(dirname $$($(1)/stamp-$(3)))
|
||||
@touch $$($(1)/stamp-$(3))
|
||||
|
||||
$$(if $(call debug,$(1),v),,.SILENT: $$($(1)/stamp-$(3)))
|
||||
|
||||
.PRECIOUS: $$($(1)/stamp-$(3)) # work around a make bug
|
||||
|
||||
$(1)//clean:=$(1)/stamp-$(3)/clean
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
#
|
||||
# Copyright (C) 2006 OpenWrt.org
|
||||
# Copyright (C) 2007 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
|
||||
define AddProfile
|
||||
ifeq ($(CONFIG_LINUX_$(1)),y)
|
||||
$(call Profile/$(1))
|
||||
@@ -13,13 +12,10 @@ define AddProfile
|
||||
endif
|
||||
endef
|
||||
|
||||
include $(TMP_DIR)/.target.mk
|
||||
-include $(TMP_DIR)/.target.mk
|
||||
|
||||
ifeq ($(IB),1)
|
||||
$(TMP_DIR)/.target.mk: $(TOPDIR)/.target.mk
|
||||
$(CP) $< $@
|
||||
else
|
||||
$(TMP_DIR)/.target.mk: $(TMP_DIR)/.targetinfo
|
||||
$(SCRIPT_DIR)/metadata.pl target_mk < $(TMP_DIR)/.targetinfo > $@
|
||||
endif
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ endif
|
||||
SCAN_COOKIE?=$(shell echo $$$$)
|
||||
export SCAN_COOKIE
|
||||
|
||||
tmp/.packageinfo tmp/.targetinfo prepare-tmpinfo: FORCE
|
||||
prepare-tmpinfo: FORCE
|
||||
mkdir -p tmp/info
|
||||
+$(NO_TRACE_MAKE) -s -f include/scan.mk SCAN_TARGET="packageinfo" SCAN_DIR="package" SCAN_NAME="package" SCAN_DEPS="$(TOPDIR)/include/package*.mk" SCAN_DEPTH=4 SCAN_EXTRA=""
|
||||
+$(NO_TRACE_MAKE) -s -f include/scan.mk SCAN_TARGET="targetinfo" SCAN_DIR="target/linux" SCAN_NAME="target" SCAN_DEPS="profiles/*.mk $(TOPDIR)/include/kernel*.mk" SCAN_DEPTH=2 SCAN_EXTRA=""
|
||||
@@ -39,6 +39,8 @@ tmp/.packageinfo tmp/.targetinfo prepare-tmpinfo: FORCE
|
||||
[ "$$t" -nt "$$f" ] || ./scripts/metadata.pl $${type}_config < "$$f" > "$$t" || { rm -f "$$t"; echo "Failed to build $$t"; false; break; }; \
|
||||
done
|
||||
./scripts/metadata.pl package_mk < tmp/.packageinfo > tmp/.packagedeps || { rm -f tmp/.packagedeps; false; }
|
||||
./scripts/metadata.pl target_mk < $(TMP_DIR)/.targetinfo > tmp/.target.mk
|
||||
touch $(TOPDIR)/tmp/.build
|
||||
|
||||
.config: ./scripts/config/conf prepare-tmpinfo
|
||||
@+if [ \! -f .config ]; then \
|
||||
@@ -101,7 +103,7 @@ prereq:: .config
|
||||
|
||||
%::
|
||||
@+$(PREP_MK) $(NO_TRACE_MAKE) -s prereq
|
||||
@+$(MAKE) $@
|
||||
@+$(MAKE) -r $@
|
||||
|
||||
help:
|
||||
cat README
|
||||
@@ -117,7 +119,7 @@ symlinkclean:
|
||||
rm -rf tmp
|
||||
|
||||
ifeq ($(findstring v,$(DEBUG)),)
|
||||
.SILENT: symlinkclean clean dirclean distclean config-clean download help tmpinfo-clean .config scripts/config/mconf scripts/config/conf menuconfig tmp/.prereq-build tmp/.prereq-package tmp/.prereq-target tmp/.packageinfo tmp/.targetinfo prepare-tmpinfo
|
||||
.SILENT: symlinkclean clean dirclean distclean config-clean download help tmpinfo-clean .config scripts/config/mconf scripts/config/conf menuconfig tmp/.prereq-build tmp/.prereq-package tmp/.prereq-target prepare-tmpinfo
|
||||
endif
|
||||
.PHONY: help FORCE
|
||||
.NOTPARALLEL:
|
||||
|
||||
Reference in New Issue
Block a user