From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Schwingen Date: Mon, 09 May 2011 08:32:16 +0200 Subject: [U-Boot] RFC: auto-generate ARM mach-types.h file from ARM machine database In-Reply-To: <20110509053746.5FCCFD6BB32@gemini.denx.de> References: <20110505214836.GA5313@discworld.dascon.de> <4DC5259C.7040208@discworld.dascon.de> <20110509053746.5FCCFD6BB32@gemini.denx.de> Message-ID: <4DC78A70.4070904@discworld.dascon.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Am 05/09/2011 07:37 AM, schrieb Wolfgang Denk: > Dear Michael Schwingen, > > In message <4DC5259C.7040208@discworld.dascon.de> you wrote: >> If I put rules in arch/arm/config.mk, then the first of these rules >> becomes the default rule which is executed in subdir makes (like "make >> -C arch"), which breaks compilation completely, since config.mk is >> included before the rules are defined in the subdir Makefiles. > You are not suppoed to put any make rules in config.mk files. > >> It seems the current scheme allows only variable definitions in >> config.mk files, which is not sufficient here. > As the name implies, these files contain configuration (= variable) > settings. Nothing else. > >> rules.mk would be fine, however, there is no provision to include rules >> from lower directories, since all the building in subdirectories is >> handled by recursively calling make (this is one of the problems that >> arise by recursively calling make for each directory, but that is a >> different topic). > But lower level directories inherit all settings from the top level > Makefile? Yes. However, the rule to generate autoconf.mk is in the toplevel Makefile, and I need the rule to generate mach-types.h at the same level, as autoconf.mk depends on it. The lower-level *Makefiles* are executed too late to generate anything that is needed for autoconf.mk. cu Michael