Re: [RFC] kbuild: drop use of "ld -r" for intermediate links of vmlinux

2014-02-20 Thread Sam Ravnborg
On Wed, Feb 19, 2014 at 11:31:00AM +1030, Alan Modra wrote: > On Tue, Feb 18, 2014 at 10:48:01PM +0100, Sam Ravnborg wrote: > > > Another possibility is to use thin archives to package up the objects. > > > Thin archives are like normal archives except they just contain paths > > > to the objects,

Re: [RFC] kbuild: drop use of "ld -r" for intermediate links of vmlinux

2014-02-18 Thread Alan Modra
On Tue, Feb 18, 2014 at 10:48:01PM +0100, Sam Ravnborg wrote: > > Another possibility is to use thin archives to package up the objects. > > Thin archives are like normal archives except they just contain paths > > to the objects, not the object contents. Paths are flattened when > > adding one th

Re: [RFC] kbuild: drop use of "ld -r" for intermediate links of vmlinux

2014-02-18 Thread Sam Ravnborg
On Wed, Feb 19, 2014 at 01:28:56AM +1030, Alan Modra wrote: > On Sun, Feb 16, 2014 at 09:37:24PM +0100, Sam Ravnborg wrote: > > The trick used is that for each directory a linker script is > > generated that name all the file to be linked - and for > > sub-directories this is just the linker script

Re: [RFC] kbuild: drop use of "ld -r" for intermediate links of vmlinux

2014-02-18 Thread Alan Modra
On Sun, Feb 16, 2014 at 09:37:24PM +0100, Sam Ravnborg wrote: > The trick used is that for each directory a linker script is > generated that name all the file to be linked - and for > sub-directories this is just the linker script for that directory. > > The file continue to be named "built-in.o"

[RFC] kbuild: drop use of "ld -r" for intermediate links of vmlinux

2014-02-16 Thread Sam Ravnborg
The approach today is that all files that ends up in vmlinux are linked directory by directory using "ld -r". The following patch moves away from all the intermediate links and do one huge link of all the .o files used for the final vmlinux. The trick used is that for each directory a linker scri