major target cleanup. it is now possible to have subtargets that can override many target settings, including arch - merge adm5120, adm5120eb. target profiles still need to be adapted for subtargets

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@8694 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
Felix Fietkau
2007-09-08 19:55:42 +00:00
parent 9647361f81
commit 6bcd07afdd
95 changed files with 345 additions and 351 deletions

View File

@@ -5,6 +5,7 @@
# See /LICENSE for more information.
#
override TARGET_BUILD=
include $(INCLUDE_DIR)/prereq.mk
include $(INCLUDE_DIR)/kernel.mk
include $(INCLUDE_DIR)/host.mk

View File

@@ -1,60 +1,20 @@
#
#
# Copyright (C) 2006-2007 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
KERNEL_BUILD:=1
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
ifneq ($(DUMP),)
TMP_CONFIG:=$(TMP_DIR)/.kconfig-$(BOARD)-$(KERNEL)
$(TMP_CONFIG): $(GENERIC_LINUX_CONFIG) $(LINUX_CONFIG)
$(SCRIPT_DIR)/config.pl + $^ > $@
-include $(TMP_CONFIG)
.SILENT: $(TMP_CONFIG)
ifneq ($(DUMP),1)
override MAKEFLAGS=
endif
ifneq ($(CONFIG_PCI),)
FEATURES += pci
endif
ifneq ($(CONFIG_USB),)
FEATURES += usb
endif
ifneq ($(CONFIG_PCMCIA)$(CONFIG_PCCARD),)
FEATURES += pcmcia
endif
# remove duplicates
FEATURES:=$(sort $(FEATURES))
ifeq ($(DUMP),1)
all: dumpinfo
else
ifneq ($(DUMP),1)
all: compile
endif
ifneq (,$(findstring uml,$(BOARD)))
LINUX_KARCH:=um
else
LINUX_KARCH:=$(shell echo $(ARCH) | sed -e 's/i[3-9]86/i386/' \
-e 's/mipsel/mips/' \
-e 's/mipseb/mips/' \
-e 's/powerpc/ppc/' \
-e 's/sh[234]/sh/' \
-e 's/armeb/arm/' \
)
endif
STAMP_PREPARED:=$(LINUX_DIR)/.prepared
STAMP_CONFIGURED:=$(LINUX_DIR)/.configured
include $(INCLUDE_DIR)/quilt.mk
@@ -90,106 +50,54 @@ define BuildKernel
$(STAMP_PREPARED): $(DL_DIR)/$(LINUX_SOURCE)
-rm -rf $(KERNEL_BUILD_DIR)
-mkdir -p $(KERNEL_BUILD_DIR)
$(call Kernel/Prepare)
$(Kernel/Prepare)
touch $$@
$(STAMP_CONFIGURED): $(STAMP_PREPARED) $(LINUX_CONFIG) $(GENERIC_LINUX_CONFIG) $(TOPDIR)/.config
$(call Kernel/Configure)
$(Kernel/Configure)
touch $$@
$(LINUX_DIR)/.modules: $(STAMP_CONFIGURED) $(LINUX_DIR)/.config FORCE
$(call Kernel/CompileModules)
$(Kernel/CompileModules)
touch $$@
$(LINUX_DIR)/.image: $(STAMP_CONFIGURED) FORCE
$(call Kernel/CompileImage)
$(Kernel/CompileImage)
touch $$@
mostlyclean: FORCE
$(call Kernel/Clean)
ifeq ($(DUMP),1)
dumpinfo:
@echo 'Target: $(BOARD)'
@echo 'Target-Kernel: $(KERNEL)'
@echo 'Target-Name: $(BOARDNAME) [$(KERNEL)]'
@echo 'Target-Path: $(subst $(TOPDIR)/,,$(PWD))'
@echo 'Target-Arch: $(ARCH)'
@echo 'Target-Features: $(FEATURES)'
@echo 'Linux-Version: $(LINUX_VERSION)'
@echo 'Linux-Release: $(LINUX_RELEASE)'
@echo 'Linux-Kernel-Arch: $(LINUX_KARCH)'
@echo 'Target-Description:'
@getvar $(call shvar,Target/Description)
@echo '@@'
@echo 'Default-Packages: $(DEFAULT_PACKAGES)'
ifneq ($(DUMPINFO),)
@$(DUMPINFO)
endif
endif
$(Kernel/Clean)
define BuildKernel
endef
endef
define Profile/Default
NAME:=
PACKAGES:=
endef
download: $(DL_DIR)/$(LINUX_SOURCE)
prepare: $(STAMP_CONFIGURED)
compile: $(LINUX_DIR)/.modules
$(MAKE) -C image compile TARGET_BUILD=
confname=$(subst .,_,$(subst -,_,$(1)))
define Profile
$(eval $(call Profile/Default))
$(eval $(call Profile/$(1)))
$(eval $(call shexport,Profile/$(1)/Config))
$(eval $(call shexport,Profile/$(1)/Description))
DUMPINFO += \
echo "Target-Profile: $(1)"; \
echo "Target-Profile-Name: $(NAME)"; \
echo "Target-Profile-Packages: $(PACKAGES)"; \
if [ -f ./config/profile-$(1) ]; then \
echo "Target-Profile-Kconfig: yes"; \
fi; \
echo "Target-Profile-Config: "; \
getvar "$(call shvar,Profile/$(1)/Config)"; \
echo "@@"; \
echo "Target-Profile-Description:"; \
getvar "$(call shvar,Profile/$(1)/Description)"; \
echo "@@"; \
echo;
ifeq ($(CONFIG_LINUX_$(call confname,$(KERNEL)_$(1))),y)
PROFILE=$(1)
endif
endef
$(eval $(call shexport,Target/Description))
download: $(DL_DIR)/$(LINUX_SOURCE)
prepare: $(STAMP_CONFIGURED)
compile: $(LINUX_DIR)/.modules
$(MAKE) -C image compile
oldconfig menuconfig: $(STAMP_PREPARED) FORCE
$(call Kernel/Configure)
$(SCRIPT_DIR)/config.pl '+' $(GENERIC_LINUX_CONFIG) $(LINUX_CONFIG) > $(LINUX_DIR)/.config
oldconfig menuconfig: $(STAMP_PREPARED) FORCE
$(Kernel/Configure)
$(LINUX_CONFCMD) > $(LINUX_DIR)/.config
$(MAKE) -C $(LINUX_DIR) $(KERNEL_MAKEOPTS) $@
$(SCRIPT_DIR)/config.pl '>' $(GENERIC_LINUX_CONFIG) $(LINUX_DIR)/.config > $(LINUX_CONFIG)
$(SCRIPT_DIR)/kconfig.pl '>' $(GENERIC_LINUX_CONFIG) $(LINUX_DIR)/.config > $(LINUX_CONFIG)
install: $(LINUX_DIR)/.image
$(MAKE) -C image compile install
install: $(LINUX_DIR)/.image
TARGET_BUILD="" $(MAKE) -C image compile install
clean: FORCE
rm -f $(STAMP_DIR)/.linux-compile
clean: FORCE
rm -rf $(KERNEL_BUILD_DIR)
rebuild: FORCE
rebuild: FORCE
@$(MAKE) mostlyclean
@if [ -f $(LINUX_KERNEL) ]; then \
$(MAKE) clean; \
fi
@$(MAKE) compile
image-prereq:
$(SUBMAKE) -s -C image prereq
image-prereq:
$(SUBMAKE) -s -C image prereq TARGET_BUILD=
prereq: image-prereq
prereq: image-prereq
endef

View File

@@ -46,11 +46,9 @@ define Kernel/Configure/2.6
-$(MAKE) $(KERNEL_MAKEOPTS) CC="$(KERNEL_CC)" oldconfig prepare scripts
endef
define Kernel/Configure/Default
$(SCRIPT_DIR)/config.pl '+' $(GENERIC_LINUX_CONFIG) \
$(if $(wildcard ./config/profile-$(PROFILE)),'+' $(LINUX_CONFIG) ./config/profile-$(PROFILE), $(LINUX_CONFIG)) \
> $(LINUX_DIR)/.config.target
$(LINUX_CONFCMD) > $(LINUX_DIR)/.config.target
$(SCRIPT_DIR)/metadata.pl kconfig $(TMP_DIR)/.packageinfo $(TOPDIR)/.config > $(LINUX_DIR)/.config.override
$(SCRIPT_DIR)/config.pl 'm+' $(LINUX_DIR)/.config.target $(LINUX_DIR)/.config.override >$(LINUX_DIR)/.config
$(SCRIPT_DIR)/kconfig.pl 'm+' $(LINUX_DIR)/.config.target $(LINUX_DIR)/.config.override > $(LINUX_DIR)/.config
$(call Kernel/Configure/$(KERNEL))
rm -rf $(KERNEL_BUILD_DIR)/modules
@rm -f $(BUILD_DIR)/linux
@@ -88,7 +86,6 @@ define Kernel/CompileImage/Default
endef
define Kernel/Clean/Default
rm -f $(LINUX_DIR)/.linux-compile
rm -f $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)/.configured
rm -f $(LINUX_KERNEL)
$(MAKE) -C $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION) clean

View File

@@ -1,11 +1,9 @@
# Use the default kernel version if the Makefile doesn't override it
ifeq ($(LINUX_VERSION),)
ifeq ($(KERNEL),2.4)
LINUX_VERSION:=2.4.34
else
LINUX_VERSION:=2.6.21.5
endif
ifeq ($(KERNEL),2.4)
LINUX_VERSION?=2.4.34
else
LINUX_VERSION?=2.6.21.5
endif
LINUX_RELEASE?=1
@@ -22,6 +20,6 @@ endif
# disable the md5sum check for unknown kernel versions
LINUX_KERNEL_MD5SUM?=x
KERNEL:=2.$(word 2,$(subst ., ,$(strip $(LINUX_VERSION))))
KERNEL_PATCHVER:=$(shell echo $(LINUX_VERSION) | cut -d. -f1,2,3 | cut -d- -f1)
KERNEL?=2.$(word 2,$(subst ., ,$(strip $(LINUX_VERSION))))
KERNEL_PATCHVER=$(shell echo $(LINUX_VERSION) | cut -d. -f1,2,3 | cut -d- -f1)

View File

@@ -5,15 +5,15 @@
# See /LICENSE for more information.
#
include $(INCLUDE_DIR)/kernel-version.mk
ifeq ($(__target_inc),)
include $(INCLUDE_DIR)/target.mk
endif
ifeq ($(DUMP),1)
KERNEL?=<KERNEL>
BOARD?=<BOARD>
LINUX_VERSION?=<LINUX_VERSION>
else
include $(INCLUDE_DIR)/target.mk
export GCC_HONOUR_COPTS=s
ifeq ($(KERNEL),2.6)
@@ -30,9 +30,8 @@ else
KERNEL_CROSS:=$(TARGET_CROSS)
endif
PLATFORM_DIR := $(TOPDIR)/target/linux/$(BOARD)
PATCH_DIR ?= ./patches$(shell [ -d "./patches-$(KERNEL_PATCHVER)" ] && printf -- "-$(KERNEL_PATCHVER)" || true )
KERNEL_BUILD_DIR ?= $(BUILD_DIR_BASE)/linux-$(BOARD)$(if $(BUILD_SUFFIX),_$(BUILD_SUFFIX))
KERNEL_BUILD_DIR ?= $(BUILD_DIR_BASE)/linux-$(BOARD)$(if $(SUBTARGET),_$(SUBTARGET))$(if $(BUILD_SUFFIX),_$(BUILD_SUFFIX))
LINUX_DIR ?= $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)
MODULES_SUBDIR:=lib/modules/$(LINUX_VERSION)
@@ -46,8 +45,18 @@ else
PKG_BUILD_DIR ?= $(KERNEL_BUILD_DIR)/$(PKG_NAME)$(if $(PKG_VERSION),-$(PKG_VERSION))
endif
GENERIC_PLATFORM_DIR := $(TOPDIR)/target/linux/generic-$(KERNEL)
GENERIC_PATCH_DIR := $(GENERIC_PLATFORM_DIR)/patches$(shell [ -d "$(GENERIC_PLATFORM_DIR)/patches-$(KERNEL_PATCHVER)" ] && printf -- "-$(KERNEL_PATCHVER)" || true )
ifneq (,$(findstring uml,$(BOARD)))
LINUX_KARCH:=um
else
LINUX_KARCH:=$(shell echo $(ARCH) | sed -e 's/i[3-9]86/i386/' \
-e 's/mipsel/mips/' \
-e 's/mipseb/mips/' \
-e 's/powerpc/ppc/' \
-e 's/sh[234]/sh/' \
-e 's/armeb/arm/' \
)
endif
define KernelPackage/Defaults

View File

@@ -27,14 +27,14 @@ define PackageDir
{ \
$$(call progress,Collecting $(SCAN_NAME) info: $(SCAN_DIR)/$(2)) \
echo Source-Makefile: $(SCAN_DIR)/$(2)/Makefile; \
$(NO_TRACE_MAKE) --no-print-dir DUMP=1 -C $(SCAN_DIR)/$(2) 2>/dev/null || echo "ERROR: please fix $(SCAN_DIR)/$(2)/Makefile" >&2; \
$(NO_TRACE_MAKE) --no-print-dir DUMP=1 -C $(SCAN_DIR)/$(2) $(SCAN_MAKEOPTS) 2>/dev/null || echo "ERROR: please fix $(SCAN_DIR)/$(2)/Makefile" >&2; \
echo; \
} > $$@ || true
endef
$(FILELIST):
rm -f tmp/info/.files-$(SCAN_TARGET)-*
$(call FIND_L, $(SCAN_DIR)) $(SCAN_EXTRA) -mindepth 1 $(if $(SCAN_DEPTH),-maxdepth $(SCAN_DEPTH)) -name Makefile | xargs grep -HE 'call (Build/DefaultTargets|Build(Package|Kernel)|.+Package)' | sed -e 's#^$(SCAN_DIR)/##' -e 's#/Makefile:.*##' | uniq > $@
$(call FIND_L, $(SCAN_DIR)) $(SCAN_EXTRA) -mindepth 1 $(if $(SCAN_DEPTH),-maxdepth $(SCAN_DEPTH)) -name Makefile | xargs grep -HE 'call (Build/DefaultTargets|Build(Package|Target)|.+Package)' | sed -e 's#^$(SCAN_DIR)/##' -e 's#/Makefile:.*##' | uniq > $@
tmp/info/.files-$(SCAN_TARGET).mk: $(FILELIST)
( \

View File

@@ -34,10 +34,10 @@ define subdir
$(foreach target,$(SUBTARGETS),$(call subtarget,$(1),$(target)))
endef
# Parameters: <subdir> <name> <target>
# Parameters: <subdir> <name> <target> <depends>
define stampfile
$(1)/stamp-$(3):=$(STAGING_DIR)/stamp/.$(2)_$(3)
$$($(1)/stamp-$(3)): $(TMP_DIR)/.build
$$($(1)/stamp-$(3)): $(TMP_DIR)/.build $(4)
@+$(SCRIPT_DIR)/timestamp.pl -n $$($(1)/stamp-$(3)) $(1) $(4) || \
$(MAKE) $$($(1)/flags-$(3)) $(1)/$(3)
@mkdir -p $$$$(dirname $$($(1)/stamp-$(3)))

View File

@@ -5,17 +5,147 @@
# See /LICENSE for more information.
#
define AddProfile
ifeq ($(CONFIG_LINUX_$(1)),y)
$(call Profile/$(1))
PROFILE=$$(ID)
ifneq ($(DUMP),)
all: dumpinfo
endif
ifneq ($(__target_inc),1)
__target_inc=1
TARGET_BUILD?=0
target_conf=$(subst .,_,$(subst -,_,$(subst /,_,$(1))))
ifeq ($(DUMP),)
PLATFORM_DIR:=$(TOPDIR)/target/linux/$(BOARD)
SUBTARGET:=$(strip $(foreach subdir,$(patsubst $(PLATFORM_DIR)/%/target.mk,%,$(wildcard $(PLATFORM_DIR)/*/target.mk)),$(if $(CONFIG_TARGET_$(call target_conf,$(BOARD)_$(subdir))),$(subdir))))
else
PLATFORM_DIR:=${CURDIR}
endif
TARGETID:=$(BOARD)$(if $(SUBTARGET),/$(SUBTARGET))
PLATFORM_SUBDIR:=$(PLATFORM_DIR)$(if $(SUBTARGET),/$(SUBTARGET))
define Target
KERNEL_TARGETS+=$(1)
ifeq ($(DUMP),1)
ifeq ($(SUBTARGET),)
BuildTarget=$$(BuildTargets/DumpAll)
endif
endif
endef
-include $(TMP_DIR)/.target.mk
ifeq ($(IB),1)
$(TMP_DIR)/.target.mk: $(TOPDIR)/.target.mk
$(CP) $< $@
ifneq ($(TARGET_BUILD),1)
include $(PLATFORM_DIR)/Makefile
ifneq ($(PLATFORM_DIR),$(PLATFORM_SUBDIR))
include $(PLATFORM_SUBDIR)/target.mk
endif
else
ifneq ($(SUBTARGET),)
-include ./$(SUBTARGET)/target.mk
endif
endif
define Profile/Default
NAME:=
PACKAGES:=
endef
define Profile
$(eval $(call Profile/Default))
$(eval $(call Profile/$(1)))
$(eval $(call shexport,Profile/$(1)/Config))
$(eval $(call shexport,Profile/$(1)/Description))
DUMPINFO += \
echo "Target-Profile: $(1)"; \
echo "Target-Profile-Name: $(NAME)"; \
echo "Target-Profile-Packages: $(PACKAGES)"; \
if [ -f ./config/profile-$(1) ]; then \
echo "Target-Profile-Kconfig: yes"; \
fi; \
echo "Target-Profile-Config: "; \
getvar "$(call shvar,Profile/$(1)/Config)"; \
echo "@@"; \
echo "Target-Profile-Description:"; \
getvar "$(call shvar,Profile/$(1)/Description)"; \
echo "@@"; \
echo;
ifeq ($(CONFIG_TARGET_$(call target_conf,$(BOARD)_$(if $(2),$(2)_)$(1))),y)
PROFILE=$(1)
endif
endef
$(eval $(call shexport,Target/Description))
include $(INCLUDE_DIR)/kernel-version.mk
GENERIC_PLATFORM_DIR := $(TOPDIR)/target/linux/generic-$(KERNEL)
GENERIC_PATCH_DIR := $(GENERIC_PLATFORM_DIR)/patches$(shell [ -d "$(GENERIC_PLATFORM_DIR)/patches-$(KERNEL_PATCHVER)" ] && printf -- "-$(KERNEL_PATCHVER)" || true )
GENERIC_LINUX_CONFIG:=$(firstword $(wildcard $(GENERIC_PLATFORM_DIR)/config-$(KERNEL_PATCHVER) $(GENERIC_PLATFORM_DIR)/config-default))
LINUX_CONFIG?=$(firstword $(wildcard $(foreach subdir,$(PLATFORM_DIR) $(PLATFORM_SUBDIR),$(subdir)/config-$(KERNEL_PATCHVER) $(subdir)/config-default)))
LINUX_SUBCONFIG?=$(firstword $(wildcard $(PLATFORM_SUBDIR)/config-$(KERNEL_PATCHVER) $(PLATFORM_SUBDIR)/config-default))
ifeq ($(LINUX_CONFIG),$(LINUX_SUBCONFIG))
LINUX_SUBCONFIG:=
endif
LINUX_CONFCMD=$(if $(LINUX_CONFIG),$(SCRIPT_DIR)/kconfig.pl + $(GENERIC_LINUX_CONFIG) $(if $(LINUX_SUBCONFIG),+ $(LINUX_CONFIG) $(LINUX_SUBCONFIG),$(LINUX_CONFIG)),true)
ifeq ($(DUMP),1)
BuildTarget=$(BuildTargets/DumpCurrent)
ifneq ($(BOARD),)
TMP_CONFIG:=$(TMP_DIR)/.kconfig-$(call target_conf,$(TARGETID))
$(TMP_CONFIG): $(GENERIC_LINUX_CONFIG) $(LINUX_CONFIG) $(LINUX_SUBCONFIG)
$(LINUX_CONFCMD) > $@ || rm -f $@
-include $(TMP_CONFIG)
.SILENT: $(TMP_CONFIG)
.PRECIOUS: $(TMP_CONFIG)
ifneq ($(CONFIG_PCI),)
FEATURES += pci
endif
ifneq ($(CONFIG_USB),)
FEATURES += usb
endif
ifneq ($(CONFIG_PCMCIA)$(CONFIG_PCCARD),)
FEATURES += pcmcia
endif
# remove duplicates
FEATURES:=$(sort $(FEATURES))
endif
endif
define BuildTargets/DumpAll
dumpinfo:
@$(foreach SUBTARGET,$(KERNEL_TARGETS),$(SUBMAKE) -s DUMP=1 SUBTARGET=$(SUBTARGET); )
endef
define BuildTargets/DumpCurrent
dumpinfo:
@echo 'Target: $(TARGETID)'; \
echo 'Target-Board: $(BOARD)'; \
echo 'Target-Kernel: $(KERNEL)'; \
echo 'Target-Name: $(BOARDNAME) [$(KERNEL)]'; \
echo 'Target-Path: $(subst $(TOPDIR)/,,$(PWD))'; \
echo 'Target-Arch: $(ARCH)'; \
echo 'Target-Features: $(FEATURES)'; \
echo 'Linux-Version: $(LINUX_VERSION)'; \
echo 'Linux-Release: $(LINUX_RELEASE)'; \
echo 'Linux-Kernel-Arch: $(LINUX_KARCH)'; \
echo 'Target-Description:'; \
getvar $(call shvar,Target/Description); \
echo '@@'; \
echo 'Default-Packages: $(DEFAULT_PACKAGES)'; \
$(DUMPINFO)
endef
include $(INCLUDE_DIR)/kernel.mk
ifeq ($(TARGET_BUILD),1)
include $(INCLUDE_DIR)/kernel-build.mk
BuildTarget?=$(BuildKernel)
endif
endif #__target_inc

View File

@@ -33,13 +33,12 @@ export SCAN_COOKIE
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=""
+$(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="" SCAN_MAKEOPTS="TARGET_BUILD=1"
for type in package target; do \
f=tmp/.$${type}info; t=tmp/.config-$${type}.in; \
[ "$$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