Hello all - first post here!

I am trying to create a shared library using xerces, and I am running into some 
problems. 

I am using the following line to build my shared lib:

g++ -O3 -Wall -fopenmp -fPIC -shared -o libviewerNativeDLL.so  ViewerNative.o 
-L/usr/lib64/ ../../lib/IDT.a ../../lib/Linux/libxerces-c.a 
../../lib/Linux/libxerces-c-3.1.so -lcurl -lidn -ldl -lssl 
../../lib/Linux/libfftw3f.a  -lpthread


and I am getting the following return message:

/usr/bin/ld: ../../lib/Linux/libxerces-c.a(PlatformUtils.o): relocation 
R_X86_64_32 against `.rodata.str1.8' can not be used when making a shared 
object; recompile with -fPIC
../../lib/Linux/libxerces-c.a: could not read symbols: Bad value


Do I really have to rebuild xerces and edit the makefile to include the fPIC 
flag, or am I doing something else wrong?

Thanks

Derek

Reply via email to