|
From: Dean K. <kol...@qw...> - 2004-12-10 23:46:27
|
I changed to ld 2.15.92.0.2, which is in Fedora Core 3, and reproduced the problem. As I understand it, x86-64 shared libraries cannot use absolute addresses in the instructions, because the library may be shared between multiple executables. Also, most rip-relative instructions can only use a 32-bit offset. Therefore in x86-64 shared libraries, when accessing an address in another .o, you have to go through the Global Offset Table. The computed address has to be 64 bits, a 32 bit offset doesn't work between shared .o files. The new linker is enforcing this. For libdv, the error messages are correct. Within a .o, smaller than 2 GB, rip-relative addresses can be used without going through the GOT. I found a new version of the ABI at http://ftp.lug.ro/suse/people/matz/ABI/abi-095.pdf with an expanded section 3.5 with position independent code examples. I made some fixes to use the GOT and put them at http://www.users.qwest.net/~kdean6/libdv_fixes.tar.bz2 Extract the files into the libdv subdirectory and rebuild. |