[vtkusers] compilation with -fPIC necessary?
Obada Mahdi
omahdi at gmx.de
Thu Mar 16 18:29:27 EST 2006
Hi Sebastiaan!
Actually, you (almost) always need "-fPIC" when creating shared
libraries. Do I understand you correctly that the "-fPIC" flag is
present when compiling VTK for shared libraries on AMD64, but not on the
EMT64? That could be a problem.
However, that "libmpich.a" issue is not related to VTK:
On Thu, 16 Mar 2006, Sebastiaan wrote:
> Linking CXX shared library ../bin/libvtkParallel.so
> /usr/lib/gcc/x86_64-pc-linux-gnu/4.1.0/../../../../x86_64-pc-linux-gnu/bin/ld:
> /usr/X11R6/lib64/libmpich.a(isend.o): relocation R_X86_64_32 against `a local
> symbol'
> can not be used when making a shared object; recompile with -fPIC
Linking static libraries when creating a shared library just does not
work generally. Any chance there is a dynamic version like
"libmpich.so" or so a available? If not, you really need to recompile
the "mpich" library in order to create shared VTK libraries.
HTH,
Obada
More information about the vtkusers
mailing list