From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike Frysinger Date: Thu, 13 Aug 2009 16:23:50 -0400 Subject: [U-Boot] [PATCH] Add support to mkconfig for setting simple #defines in config.h In-Reply-To: <20090813201511.D439E833DBD2@gemini.denx.de> References: <1249653783-16727-1-git-send-email-galak@kernel.crashing.org> <200908131602.20315.vapier@gentoo.org> <20090813201511.D439E833DBD2@gemini.denx.de> Message-ID: <200908131623.52013.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Thursday 13 August 2009 16:15:11 Wolfgang Denk wrote: > Mike Frysinger wrote: > > > Consider a target such as BOARDNAME_66MHz_NANDBOOT_PCISLAVE. > > > > > > It could then invoke "$(MKCONFIG) -D $@ -a configname arch cpu board". > > > mkconfig would break up the -D argument into: > > > > > > #define CONFIG_BOARDNAME > > > #define CONFIG_66MHz > > > #define CONFIG_NANDBOOT > > > #define CONFIG_PCISLAVE > > > > then yes, a sed would have to be used. maybe something like: > > DEFINES="`echo "_$*" | sed 's:_:\n#define CONFIG_:g'`${DEFINES}" ; shift > > > ;; > > Nope, this doesn't work. > > We have many names with more than one underscore in it (all the > CONFIG_CMD_* and CONFIG_SYS_* and CONFIG_BOOTP_* and ...). i'm only giving POSIX compliant versions of proposed code. the issue you raised i dont care about -- that's for the OP to handle. -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. Url : http://lists.denx.de/pipermail/u-boot/attachments/20090813/94a9ea16/attachment.pgp