libxml2.a and -fPIC
Dmitry Sivachenko
demon at FreeBSD.org
Wed Aug 15 12:38:27 UTC 2012
Hello!
I am writing some kind of shared library at work which uses libxml2.
I want to link statically with it.
When I try, I get the following error:
/usr/bin/ld: /usr/local/lib/libxml2.a(error.o): relocation R_X86_64_32 against
`a local symbol' can not be used when making a shared object; recompile with -fPIC
If I add -fPIC to CFLAGS and recompile libxml2 port, this error disappears.
Is it possible to make this change to port so libxml2.a is always built with -fPIC?
Thanks!
More information about the freebsd-gnome
mailing list