views:

47

answers:

0

Hi all, I tried to compile sigintr.c in DD-WRT/src/router/rflow with arm-linux-gcc. The problem I encountered is:

sigintr.o: In function siginterrupt': sigintr.c:(.text+0x88): undefined reference to_sigintr'

collect2: ld returned 1 exit status make[1]: * [rflow] Error 1

I can find '_sigintr' in libc.so, but unfortunately it is marked as "HIDDEN" Here is the output of arm-linux-readelf

$ arm-linux-readelf ./arm-none-linux-gnueabi/libc/armv4t/lib/libc-2.8.so_mod -s | grep sigintr

852: 00000000 0 FILE LOCAL DEFAULT ABS sigintr.c

9639: 0012aed0 128 OBJECT LOCAL HIDDEN 32 _sigintr

I tried to use arm-linux-objcopy to modify the visibility of _sigintr

$ arm-linux-objcopy --globalize-symbol _sigintr ./libc-2.8.so ./libc-2.8.so_mod $ arm-linux-readelf ./arm-none-linux-gnueabi/libc/armv4t/lib/libc-2.8.so_mod -s | grep sigintr

852: 00000000 0 FILE LOCAL DEFAULT ABS sigintr.c

9639: 0012aed0 128 OBJECT GLOBAL HIDDEN 32 _sigintr

The same error encountered when recompiling. Is there a solution to change the visibility of this symbol or another way to compile without errors. Thanks and Regards for your help