ralf.corsepius at rtems.org
Mon Feb 7 17:46:50 UTC 2011
On 02/07/2011 06:27 PM, Kirspel, Kevin wrote:
> I am building a RTEMS port to an STM32 Cortex-M3. I am building the port for RTEMS version 4.9. I have built binutils-2.18 and gcc-4.3.2 with thumb2 support (I had to change t-rtems under GCC to output thumb2 multilib).
... except that these versions are hopelessly outdated (You will really
want to use the rtems-4.11 versions), there shouldn't be much wrong with
> When configuring RTEMS, the configure script cannot find newlib.
Do you have newlib inside of your gcc-source tree?
> Looking at config.log, I get the following error when checking for newlib:
> configure:4709: checking for RTEMS newlib
> configure:4736: arm-rtems-gcc --pipe -o conftest -mcpu=cortex-m3 -mthumb -mstructure-size-boundary=8 -O0 -g conftest.c>&5
> collect2: ld terminated with signal 11 [Segmentation fault]
This looks like you are using an installed arm-rtems-gcc (likely
something even more outdated than rtems-4.9) to building your compiler.
=> There is something going wrong much earlier.
> /usr/local/gcc-4.3.2/lib/gcc/arm-rtems/4.3.2/../../../../arm-rtems/bin/ld: warning: cannot find entry symbol _start; defaulting to 00008000
> /usr/local/gcc-4.3.2/lib/gcc/arm-rtems/4.3.2/../../../../arm-rtems/bin/ld: /usr/local/gcc-4.3.2/lib/gcc/arm-rtems/4.3.2/../../../../arm-rtems/lib/libg.a(lib_a-dummysys.o)(not_required_by_rtems): warning: interworking not enabled.
> first occurrence: /home/kirspelk/tmp/ccOqIF65.o: thumb call to arm
> /usr/local/gcc-4.3.2/lib/gcc/arm-rtems/4.3.2/../../../../arm-rtems/bin/ld: BFD (GNU Binutils) 2.18 assertion fail ../../binutils-2.18/bfd/elf32-arm.c:6532
> /home/kirspelk/tmp/ccOqIF65.o: In function `main':
> /home/kirspelk/sandbox/opti_touch/b_rtems_cortexm3/arm-rtems/c/cortexm3/cpukit/conftest.c:12: dangerous relocation:
> configure:4743: $? = 1
> It looks like configure is looking in the "gcc-4.3.2/arm-rtems/lib" directory to determine a valid newlib library. The thumb2 newlib library is under "gcc-4.3.2/arm-rtems/lib/thumb/thumb2". How should I go about correcting this issue?
Theoretically, extending arm/t-rtems, adding newlib to the source tree
(usually adding a sym-link) should be all that is required.
> Is this even the issue or is it something else?
Likely - Unfortunately, provided what you tell, it's hard to guess what
this could be. Likely several things at once.
More information about the users