From: Mike Frysinger Date: Wed, 18 Nov 2009 19:15:37 -0500 Subject: [U-Boot] why is the compilation of cmd_pcmcia.c hardcoded? In-Reply-To: References: Message-ID: <200911181915.38142.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 Wednesday 18 November 2009 03:17:21 Robert P. J. Day wrote: > i'm curious as to why common/Makefile hardcodes the compilation of > cmd_pcmcia.c thusly: > > COBJS-y += cmd_pcmcia.o > > since i'm interested in building for a beagleboard, i have no interest > in PCMCIA support, yet that source file will be compiled for me, even > though the selection macro CONFIG_CMD_PCMCIA does exist and is defined > by a number of other board configurations. > > what seems stranger is that, even though that config macro exists, > it isn't used in the Makefile but *is* tested in the source file > itself to determine whether the "pinit" command will be compiled: you didnt read enough of the code. specifically, you missed the fact that other config options can compile code in this file even if CONFIG_CMD_PCMCIA is disabled. if you feel like re-architecting and splitting the code to take this into consideration, that's one thing. but it isnt a simple 'move the config option into the makefile' fix. -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/20091118/ca4ab624/attachment.pgp