This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See crosstool-NG for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Newlib complains of undefined references to __bss_start__, __bss_end__ & __end__


On 07. aug. 2012 16:00, Carlos de Sa wrote:
> Hi,
> 
> I'm trying to build an arm-eabi toolchain using gcc 4.7.1, binutils
> 2.22 and newlib 1.20. This appears to build sucessfully. However when
> testing a simple c program it complains -
> 
> crosstool-ng-1.15.3/.build/src/newlib-1.20.0/newlib/libc/sys/arm/crt0.S:406:
> error: undefined reference to '__bss_start__'
> crosstool-ng-1.15.3/.build/src/newlib-1.20.0/newlib/libc/sys/arm/crt0.S:406:
> error: undefined reference to '__bss_end__'
> crosstool-ng-1.15.3/.build/src/newlib-1.20.0/newlib/libc/sys/arm/crt0.S:406:
> error: undefined reference to '__end__'
> collect2: error: ld returned 1 exit status
> 
>>From the above it appears that the generated toolchain in
> ~/x-tools/arm-unknown-eabi/ still has references to the build
> directory in crosstool-ng-1.15.3/.build also also undefined linker
> symbols?
> 
> any idea how to solve this?
> 
> TIA.
> 
> Regards
> Carlos
> 

That seems to me to be a mismatch between the start up code in crt0.S
and the linker script you use.

>From what I have understood when building an ARM toolchain you do not
use the start up code and linker scripts from newlib. You supply your
own in your project.

How does your .config file look like?

Regards
Per A.



--
For unsubscribe information see http://sourceware.org/lists.html#faq


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]