From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andreas Engel Date: Mon, 08 Sep 2008 16:44:57 +0200 Subject: [U-Boot] [PATCH] [ARM] Moved conditional compile into Makefile In-Reply-To: <20080908140658.853C2248A5@gemini.denx.de> References: <20080908085608.GA3956@game.jcrosoft.org> <1220877053-30412-1-git-send-email-andreas.engel@ericsson.com> <20080908133035.GB3956@game.jcrosoft.org> <20080908140658.853C2248A5@gemini.denx.de> Message-ID: <48C53A69.6010006@ericsson.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Wolfgang Denk schrieb: > Dear Jean-Christophe PLAGNIOL-VILLARD, > > In message <20080908133035.GB3956@game.jcrosoft.org> you wrote: >> what append if CONFIG_PL010_SERIAL and CONFIG_PL011_SERIAL is active at the >> same time? > > Then something is missing. In this particular case, this will not work anyway. The driver is not prepared to support both a PL010 and a PL011 at the same time. And I doubt that there's some real hardware out there which actually contains both types of uarts. >> serial_pl01x.c will be compile twice >> >> so please move to >> +COBJS-$(CONFIG_PL010_SERIAL)$(CONFIG_PL011_SERIAL) += serial_pl01x.o > > This alone is not sufficient, since then you need to add a rule for > the resulting COBJS-yy. There's already such a rule in common/Makefile. > But as I learned all of this is completely unnecessary. > > As Detlev Zundel pointed out, just doing "COBJS-y = $(sort COBJS-y)" > would fix any such problems in a clean and readable way. > > I recommend to add such a statement instead. Yes, that's definitely better, as it also catches cases with more than two y's. Regards, Andreas