What library does the arg "-lphp5" refer to for GCC?

0

Where can I get the library -lphp5 refers to? Is it a part of a metapackage for YUM?

Can I find the source somewhere? I'm having some configuration issues with PHC and this seems to be at the root of them.

KeatsKelleher

Posted 2010-09-10T18:37:30.520

Reputation: 133

Answers

2

On an overview level, it means link with the php5 library. If PHC is this: http://www.phpcompiler.org then it makes sense that it would be looking for the PHP lib. Where is this installed on your machine? You should be able to do: locate libphp5 and find it. If locate doesn't see it, you need to install PHP.

On a more specific level, -l means to look for a library. -lNAME will make the linker look for libNAME.so first, and then if it can't find it, try libNAME.a. Where will it look? Generally /usr/lib, /lib, some compiler specific directories, and any directories provided with -L. How can you make PHC find it if it isn't in a common path? You should be able to set something in the build script for PHC.

Rich Homolka

Posted 2010-09-10T18:37:30.520

Reputation: 27 121

0

You are probably getting this when installing PHP5.

From PHP5 Install Problems - libphp5.so not created :

When compiling you are receiving the message that the libphp5.so is not found, you must configure with the following option:

./configure --with-apxs2=/usr/local/apache/bin/apxs

You'll see immediately when compiling with "make install" that the library will be created.

If that's the case, why don't you install a binary release of PHP5, instead of compiling it from the sources?

harrymc

Posted 2010-09-10T18:37:30.520

Reputation: 306 093

When compiling for phc, you generally need --enable-embed too. – Paul Biggar – 2010-09-11T23:59:31.310