This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Problems with refernces to __builtin_xxx linking a shared library
- To: gcc at gcc dot gnu dot org
- Subject: Problems with refernces to __builtin_xxx linking a shared library
- From: Michael Skriver <skriver at cs dot auc dot dk>
- Date: Mon, 14 Feb 2000 11:18:01 +0100
I'm having problems with refernces to __builtin_new,
__builtin__pure_virtual etc. when I'm building a shared c++ library with
the options -shared -nostartfiles -nodefaultlibs.
Here is the actual return of the compile
gcc -shared -nostartfiles -nodefaultlibs test.cc -o test.so
returns:
Text relocation remains referenced
against symbol offset in file
test::test(int) 0x20 /var/tmp/cc5sKHSk.o
terminate(void) 0xa0 /var/tmp/cc5sKHSk.o
__builtin_delete 0x50 /var/tmp/cc5sKHSk.o
__builtin_delete 0x78 /var/tmp/cc5sKHSk.o
__builtin_new 0x8 /var/tmp/cc5sKHSk.o
__throw 0x98 /var/tmp/cc5sKHSk.o
__throw 0x38 /var/tmp/cc5sKHSk.o
ld: fatal: relocations remain against allocatable but non-writable
sections
collect2: ld returned 1 exit status
Is it possible to provide these functions in seperate library linked
against this one? Getting rid off _delete and _new is easy by doing
overloading, but the throw and pure vitual calls are driving me nuts :).
How do i fool the linker to accept other, than the standard, rutines for
them. Is there any documentation on these rutines ?
Michael Skriver
skriver@cs.auc.dk