This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

R_MIPS_32 handling


Hi,

I have a testcase that has a R_MIPS_32 in a .rel.debug_info against an externally defined symbol. Since .debug_info is non-alloc, ld isn't able to convert it into a dynamic reloc and create the shared object. Can anyone comment on how this reloc should be handled?

Reduced testcase:

$ cat /home/ryan/efun.c
extern void err (int, const char *, ...);
static void (*efunc)(int, const char *, ...) = err;

$ mips-unknown-linux-uclibc-gcc -O ~/efun.c -g -fpic -shared
/home/ryan/tools/mips-unknown-linux-uclibc/mips-unknown-linux-uclibc/bin/ld: non-dynamic relocations refer to dynamic symbol err
/home/ryan/tools/mips-unknown-linux-uclibc/mips-unknown-linux-uclibc/bin/ld: failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status


Regards,

Ryan Mansfield


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]