You need to rebuild libpcre
with position independent code. The straightforward way to do that is to build or install the libpcre
shared objects (e.g. libpcre.so
) which are built with -fPIC
.
Since the library archive was in /usr/lib/x86_64-linux-gnu, the shared objects might be there also. Try adding -L/usr/lib/x86_64-linux-gnu
to LDFLAGS
of php. This will also save you from symlinking to /usr.
manpreet
Best Answer
2 years ago
I'm trying to compile PHP myself as I want to use PHPBrew to switch between multiple versions of PHP.
I already solved a ton of problems in the process, but with this particular one I can't get any further. I'm getting this error message in the
make
process:I needed to add a symlink from
/usr/libpcre.a -> /usr/lib/x86_64-linux-gnu/libpcre.a
before, as otherwise he would complain about not beeing able to findlibpcre.a
.I also tried to add
"EXTRACFLAGS=-fPIC"
tomake
, but it wouldn't change anything. It's the first time I'm compiling something, so I'm not even sure if I get the basics right.This is under Ubuntu 13.10 (not seeing the same problems on 12.04). This is my PHPBrew command:
Wich results in the following configure options being generated:
I think I have all relevant packages installed:
Any help is really appreciated!