[U-Boot] [PATCH 3/5] common: Add .u_boot_list into all linker files

Daniel Schwierzeck daniel.schwierzeck at gmail.com
Wed Oct 3 20:05:45 CEST 2012


2012/10/3 Marek Vasut <marex at denx.de>:
> Dear Daniel Schwierzeck,
>
>> 2012/10/3 Marek Vasut <marex at denx.de>:
>> > Dear Daniel Schwierzeck,
>> >
>> > [...]
>> >
>> >> this can't work because u-boot.lst is genereated in top-level directory
>> >> but linking of standalone code happens in the according subdirectories.
>> >> Thus the linker can't find u-boot.lst.
>> >>
>> >> Example for MIPS standalone:
>> >>
>> >> /opt/eldk-5.2.1/mips/sysroots/i686-eldk-linux/usr/bin/mips32-linux/mips-
>> >> lin ux-ld.bfd -G 0 -static -n -nostdlib -EB -g -Ttext 0x80200000 -T
>> >> mips.lds \
>> >>
>> >>                       -o hello_world -e hello_world hello_world.o
>> >>                       libstubs.o \
>> >>                       -L/opt/eldk-5.2.1/mips/sysroots/mips32-
>> >
>> > linux/usr/lib/mips-linux/4.6.4
>> >
>> >> -lgcc
>> >> /opt/eldk-5.2.1/mips/sysroots/i686-eldk-linux/usr/bin/mips32-linux/mips-
>> >> li nux-ld.bfd: cannot open linker script file u-boot.lst: No such file
>> >> or directory
>> >
>> > Do you have any suggestion? I recall compiling it for mips ...
>>
>> Do we really need u-boot.lst in standalone applications? I think there is
>> no need for u_boot_cmd or DM.
>
> Wait, it got linked into standalone apps? I thought it broke your precious mips
> ...

it did. MIPS, NDS32 and Sparc have extra LDS files for standalone
applications where you also
added "INCLUDE u-boot.lst". Because standalone applications are always
built unconditionally,
all MIPS boards fail at final link of the application binary.

-- 
Best regards,
Daniel


More information about the U-Boot mailing list