[ELDK] ELDK 4.2 - undefined refrence to 'raise'

Wolfgang Denk wd at denx.de
Tue Sep 15 10:54:07 CEST 2009


Dear "J.Hwan.Kim",

In message <4AAF3216.7090305 at gmail.com> you wrote:
> 
> I met a error when compiling some package, which displayed following 
> message.
> It dislayed "undefined reference to 'raise'".
> I'm using ELDK4.2.

ELDK 4.2 contains an EABI compliant ARM cross compiler.

> arm-linux-gcc  -O2 -fomit-frame-pointer 
> -I/home/frog/Work/JTAGProbe/flash/include -Wall   -mabi=aapcs-linux 
> -mcpu=arm9tdmi -DELF -DVERSION=\"1.0\" -DCONFIG_ARCH_S3C2410 
> -DCONFIG_NAND_FLASH -D__ASSEMBLY__   -c -o crt0.o crt0.S
> make[1]: Leaving directory `/home/frog/Work/JTAGProbe/flash/update'
> arm-linux-ld -N -Ttext 0x30200000      -T elf.lds -o update.elf 
> update/crt0.o update/main.o lib/lib.a `arm-linux-gcc  -O2 
> -fomit-frame-pointer -I/home/frog/Work/JTAGProbe/flash/include -Wall   
> -mabi=aapcs-linux -mcpu=arm9tdmi -DELF -DVERSION=\"1.0\" 
> -DCONFIG_ARCH_S3C2410 -DCONFIG_NAND_FLASH --print-libgcc-file-name`
> /opt/eldk/usr/bin/../lib/gcc/arm-linux-gnueabi/4.2.2/libgcc.a(_dvmd_lnx.o): 

What you do here is mixing several envrionments: you obviously try to
build some bare metal application using a custom libraries and a
custom C runtime envrionment (update/crt0.o), but it seesm this
environment is not EABI conformant resp. incomplete.

...
> undefined reference to `raise'
> 
> Why is this error message displayed?

Your software environment fails to implement the raise() function,
which is required for EABI compatibility.

> Please tell me how can I solve this problem?

Add an implementation of raise() to your code. You can use the code
from lib_arm/eabi_compat.c from the U-Boot sources as an example.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
        Ordnung ist die Lust der Vernunft,
        aber Unordnung die Wonne der Phantasie         - Paul Claudel


More information about the eldk mailing list