I'm having an issue defining abort in my own C library when using a linking group and libgcc.a is outside of the link group. For instance, if my Makefile included:
arm-eabi-ld --entry=__start -T ld.script -o foo.bin foo.o --start-group -lmylib -lmylib2 --end-group "c:/devkitpro/devkitarm/bin/../lib/gcc/arm-eabi/4.5.0/libgcc.a"
abort is not found in mylib.a and I will get an undefined reference to `abort' in the following functions: unwind_phase2, __gnu_Unwind_Resume, _Unwind_GetDataRelBase, _Unwind_GetTextRelBase.
The link will complete successfully if I use the following:
arm-eabi-ld --entry=__start -T ld.script -o foo.bin foo.o --start-group -lmylib -lmylib2 "c:/devkitpro/devkitarm/bin/../lib/gcc/arm-eabi/4.5.0/libgcc.a" --end-group
With CodeSourcery, my original link command works correctly. Might this be a bug with devkitARM?
Linker Group Issue
-
- Site Admin
- Posts: 1986
- Joined: Tue Aug 09, 2005 3:21 am
- Location: UK
- Contact:
Re: Linker Group Issue
No, this is the default behaviour with gcc for a baremetal arm target. It's possible Codesourcery have modified their build to avoid some circular dependencies.
Is it worth looking at replacing whatever functions are being used from libgcc?
Is it worth looking at replacing whatever functions are being used from libgcc?
Who is online
Users browsing this forum: No registered users and 2 guests