From mboxrd@z Thu Jan 1 00:00:00 1970 From: Masahiro Yamada Date: Fri, 04 Oct 2013 19:37:53 +0900 Subject: [U-Boot] [PATCH v3 0/6] Second step towards Kbuild: Descend down like Kbuild In-Reply-To: References: <1380529418-28532-1-git-send-email-yamada.m@jp.panasonic.com> Message-ID: <20131004193752.EEAB.AA925319@jp.panasonic.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Simon > Can you please explain why you need to change the .lds files - sorry it is > not obvious to me. This series changes how objects are linked. Before this series, drivers/bios_emulator/libatibiosemu.o drivers/block/libblock.o drivers/pcmcia/libpcmcia.o ... are directly linked into ./u-boot at the final link stage. After this series, drivers/bios_emulator/built-in.o drivers/block/built-in.o drivers/pcmcia/built-in.o ... are combined into drivers/libdrivers.o and then drivers/libdrivers.o is linked into ./u-boot. This means that all symbols in drivers/bios_emulator/built-in.o drivers/block/built-in.o drivers/pcmcia/built-in.o ... are also included in drivers/libdrivers.o > --- a/board/tqc/tqm8xx/u-boot.lds > +++ b/board/tqc/tqm8xx/u-boot.lds > @@ -23,8 +23,8 @@ SECTIONS > board/tqc/tqm8xx/libtqm8xx.o (.text*) > disk/libdisk.o (.text*) > drivers/net/libnet.o (.text*) > - drivers/pcmcia/libpcmcia.o (.text.pcmcia_on) > - drivers/pcmcia/libpcmcia.o (.text.pcmcia_hardware_enable) > + drivers/libdrivers.o (.text.pcmcia_on) > + drivers/libdrivers.o (.text.pcmcia_hardware_enable) > > . = DEFINED(env_offset) ? env_offset : .; > common/env_embedded.o (.ppcenv*) This is to avoid multiple definition error at the link stage. .test.pcmcia_on and .text.pcmcia_hardware_enable are included in both drivers/pcmcia/built-in.o and drivers/libdrivers.o so I replaced the former with the latter. > diff --git a/board/LEOX/elpt860/u-boot.lds b/board/LEOX/elpt860/u-boot.lds > index f9c2beb..b30b667 100644 > --- a/board/LEOX/elpt860/u-boot.lds > +++ b/board/LEOX/elpt860/u-boot.lds > @@ -34,7 +34,6 @@ SECTIONS > arch/powerpc/cpu/mpc8xx/libmpc8xx.o (.text*) > board/LEOX/elpt860/libelpt860.o (.text*) > arch/powerpc/lib/libpowerpc.o (.text*) > -/* drivers/rtc/librtc.o (.text*) */ > > . = env_offset; > common/env_embedded.o Becuase only a comment line is deleted, this change has no impact and I might not have needed to touch it actually. I deleted it just because we don't have drivers/rtc/librtc.c any more. Best Regards Masahiro Yamada