Apache-PHP-Oracle linking problem

Apache-PHP-Oracle linking problem

Post by Jonathan Ledli » Tue, 31 Aug 1999 04:00:00



I'm trying to set up Apache with PHP which has been set up with Oracle
support.  The PHP part seems to go fine (I installed it into the Apache
source tree) and most of the Apache compilation seems to go well, except
when it's linking everything together.  Here's the error I get:

<=== src/modules/proxy
===> src/modules/php3
gcc -c  -I../../os/unix -I../../include   -DSOLARIS2=260 -DUSE_HSREGEX
-DUSE_EXPAT -I../../lib/expat-lite `../../apaci`  mod_php3.c
cp libmodphp3.a libphp3.a
ar r libphp3.a mod_php3.o
ranlib libphp3.a
<=== src/modules/php3
<=== src/modules
gcc -c  -I./os/unix -I./include   -DSOLARIS2=260 -DUSE_HSREGEX
-DUSE_EXPAT -I./lib/expat-lite `./apaci` modules.c
gcc -c  -I./os/unix -I./include   -DSOLARIS2=260 -DUSE_HSREGEX
-DUSE_EXPAT -I./lib/expat-lite `./apaci` buildmark.c
gcc  -DSOLARIS2=260 -DUSE_HSREGEX -DUSE_EXPAT -I./lib/expat-lite
`./apaci`    \
-o httpd buildmark.o modules.o modules/php3/libphp3.a
modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a
ap/libap.a regex/libregex.a lib/expat-lite/libexpat.a  -R/oracle/lib
-L/oracle/lib -Lmodules/php3 -L../modules/php3 -L../../modules/php3
-lmodphp3   -lclntsh -lsocket -lnsl -lm -ldl -laio
-lpam -lm -ldl -lsocket -lnsl  -lresolv  -lsocket -lnsl -lgdbm -ldl
Undefined                       first referenced
symbol                             in file
olog                                modules/php3/libphp3.a(oracle.o)
ld: fatal: Symbol referencing errors. No output written to httpd
make[2]: *** [target_static] Error 1
make[2]: Leaving directory `/opt/src/apache_1.3.9/src'
make[1]: *** [build-std] Error 2
make[1]: Leaving directory `/opt/src/apache_1.3.9'
make: *** [build] Error 2

The PHP FAQ suggests re-ordering the libraries in the Makefile (I assume
they are just talking about the Makefile in apache/src and not the other
makefiles in subdirs).  I have tried various combinations including the
one suggested in the installation instructions, which is:
-L$ORACLE_HOME/lib -lclntsh -lpsa -lcore4 -lnlsrtl3 -lclntsh -lm
This doesn't work either, particularly because I don't have the psa or
core4 libraries (or they just aren't in my path).

Any suggestions are appreciated in advance.
- jonathan

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.

 
 
 

Apache-PHP-Oracle linking problem

Post by Rasmus Lerdo » Tue, 31 Aug 1999 04:00:00



>-o httpd buildmark.o modules.o modules/php3/libphp3.a
>modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a
>ap/libap.a regex/libregex.a lib/expat-lite/libexpat.a  -R/oracle/lib
>-L/oracle/lib -Lmodules/php3 -L../modules/php3 -L../../modules/php3
>-lmodphp3   -lclntsh -lsocket -lnsl -lm -ldl -laio
>-lpam -lm -ldl -lsocket -lnsl  -lresolv  -lsocket -lnsl -lgdbm -ldl
>Undefined                       first referenced
>symbol                             in file
>olog                                modules/php3/libphp3.a(oracle.o)
>ld: fatal: Symbol referencing errors. No output written to httpd
>make[2]: *** [target_static] Error 1
>make[2]: Leaving directory `/opt/src/apache_1.3.9/src'
>make[1]: *** [build-std] Error 2
>make[1]: Leaving directory `/opt/src/apache_1.3.9'
>make: *** [build] Error 2

>The PHP FAQ suggests re-ordering the libraries in the Makefile (I assume
>they are just talking about the Makefile in apache/src and not the other
>makefiles in subdirs).  I have tried various combinations including the
>one suggested in the installation instructions, which is:
>-L$ORACLE_HOME/lib -lclntsh -lpsa -lcore4 -lnlsrtl3 -lclntsh -lm
>This doesn't work either, particularly because I don't have the psa or
>core4 libraries (or they just aren't in my path).

Well, poke around a bit with 'nm -o' in your Oracle library directory and
figure out which library defines the olog symbol and add that one.

Oracle loves to change things fro versions to version and from
platform to platform.

-Rasmus

 
 
 

1. Solaris - PHP- Apache- Oracle : Problem getting PHP installed

hello all-
I hope someone can help me. I am having difficulties getting PHP to
compile properly on my solaris 7 system.

It dies during the make. The error has to do with the stub.lo file-the
exact error is:
stub.lo: File Not Recognized:File Truncated.
collect2: ld returned 1 exit status

I configured PHP with the following parameters:
./configure --with-apxs=/usr/local/apache/apxs --with-
oracle=/opt/myoraclehome

Apache was already installed with most modules, includeding the
mod_so module.
I also went in and had to hand configure the apxs file as specified in
the PHP FAQ.

Anyone have any ideas? As usual, I am on a deadline, and totally
stumped.

Thanks!
Brittney McChristy

Sent via Deja.com http://www.deja.com/
Before you buy.

2. screen print

3. Problems with Apache/Oracle/PHP

4. subscribe

5. Apache w/ PHP and SSL: w/ PHP OK - w/out PHP NOK

6. SCO Incoming PPP/Windows 98 Followup

7. strange linking problems w/ apache with php including ldap support on solaris

8. Fonts in Linux :)

9. PHP/Oracle and PHP Training

10. Apache+PHP+ODBC+ORACLE

11. Install Apache with PHP and Oracle

12. apache+php+oracle

13. Need to compile Apache/PHP with Oracle