【发布时间】:2014-04-02 05:40:49
【问题描述】:
我正在使用 Imakefile 制作 Makefile。 我收到编译错误。
rm -f /vobs/eagle/build/linux/debug/lib/libTestRtip.so
/usr/bin/g++ -Wl,-soname,libTestRtip.so /vobs/eagle/build/linux/debug/obj/TestRtip.oo - L/vobs/eagle/build/linux/debug/lib -L/vobs- ads/outsource/ace610_linux_64bit/ACE_wrappers/lib/linux -L/vobs- ads/outsource/log4cxx/linux/lib64 -shared -o /vobs/eagle/build/linux/debug/lib/libTestRtip.so
/usr/bin/ld: /vobs/eagle/build/linux/debug/obj/TestRtip.oo: relocation R_X86_64_32 against `.rodata' can not be used when making a shared object; recompile with -fPIC
/vobs/eagle/build/linux/debug/obj/TestRtip.oo: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [/vobs/eagle/build/linux/debug/lib/libTestRtip.so] Error 1
我不知道在Imakefile的哪里添加-fPIC。
【问题讨论】:
-
请发布编译的全部输出