正如问题所述,我需要应用这些编译器/链接器设置中的任何一个。我正在使用 Code::Blocks 10.05。我浏览了所有构建设置屏幕。我找不到在哪里应用这些设置。我得到以下输出:
-------------- Build: Release in 39dll-4-Linux ---------------
Linking dynamic library: ./39DLL.so
/usr/bin/ld: obj/Release/buffer.o: relocation R_X86_64_32 against `CBuffer::retval' can not be used when making a shared object; recompile with -fPIC
obj/Release/buffer.o: could not read symbols: Bad value
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 0 seconds)
0 errors, 0 warnings