Operating System - HP-UX
1819804 Members
3209 Online
109607 Solutions
New Discussion юеВ

Add OCI8 on an install Apache+PHP

 
joseph_45
New Member

Add OCI8 on an install Apache+PHP

I install the HP package (depot) with Apache 1.3.27 and PHP 4.2.2
I want to add the oci8.so to connect my database.
I install Oracle client on my machine and now i want to compile PHP to get an oci.so with :
./configure --with-oci8=/my_oracle_path

I can't make this oci8.so

Who can help me to configure my system (HP-UX 11)?

Thanks
8 REPLIES 8
benoit Bruckert
Honored Contributor

Re: Add OCI8 on an install Apache+PHP

Hi Joseph,
It's easier to run PHP on HPUX in static mode, which means that you have to compile also APache (just 1 binary).
The best thing is to start from gcc2.95.2, binutils, gmake you can downlaod at http://hpux.cict.fr
Then download sources from apache and PHP,
unzip/untar the packets.
STart from the apache sources :
./configure --prefix= . --disable-module=all --enable-module=so --activate-module=src/modules/php4/libphp4.a
then cd to php sources :
./configure --with-oci8= --with-apache= --disable-mysql(if you don't want to use mysql !)...
Then
make
make install
cd to apache sources,
make
You have then an httpd ready with PHP built in + included OCI8.
Try a search on PHP on the forum, many questions with answers about PHP on HPUX...

hth
Benoit
_________
"Un enfant prodige ?
c'est un enfant dont les parents ont beaucoup d'imagination."
Jean Cocteau
Une application mal pans├йe aboutit ├а une usine ├а gaze (GHG)
Nick Brennan
Occasional Advisor

Re: Add OCI8 on an install Apache+PHP

Hi Joseph,

If you download the HPApache2 bundle and install, this comes bundled with a compiled version of PHP 4.2.2 and the Oracle plug-in. If you then check in /opt/hpapache2/hp_apache_docs/php.admin.guide you'll see how to enable the plug-in. It's pretty straightforward. (Make sure you have the patch it requires).

Cheers
Nick
Yeeee - Haaaaaaaaaa!
joseph_45
New Member

Re: Add OCI8 on an install Apache+PHP

thanks for your response.

When i try the first solution that i experiment since several days, i have always problems, now my server say "If only this line appears then php is not working"

And the second solution is good but i see the version is compliant with Oracle 8.1.6 ... and i have the 8.1.7

Any help, thanks
benoit Bruckert
Honored Contributor

Re: Add OCI8 on an install Apache+PHP

Hi Joseph,
WHen do you have this error ? During compile time, during running of apache ???
Can you try httpd -v and post the output ?
regards
Benoit
______
Barre ? c'est mon compagnon de chambre :
il dort ?? cot?? de moi a l'Assembl??e.
Andr?? Santini.
Une application mal pans├йe aboutit ├а une usine ├а gaze (GHG)
joseph_45
New Member

Re: Add OCI8 on an install Apache+PHP

result of httpd -v

Server version: Apache/1.3.27 (Unix)
Server built: Dec 17 2002 10:41:33
benoit Bruckert
Honored Contributor

Re: Add OCI8 on an install Apache+PHP

And httpd -l ??
You should have
Compiled-in modules:
http_core.c
mod_so.c
mod_php4.c
if you don't have the mod_php4.c, it means that php is not included in the binary. (But it can works in dynamic as a share objects.
last test: in your apache directory,
create this file fred.php:
phpinfo();
?>
Then in a browser type the url, with the file fred.php
You should have an html pages with many informations about php, variables,....
Can you check ?

regards
Benoit
Une application mal pans├йe aboutit ├а une usine ├а gaze (GHG)
joseph_45
New Member

Re: Add OCI8 on an install Apache+PHP

That's good.
My page PHP display informations of my binary httpd.
Just an a last question, when i do "httpd -l" i have :
Compiled-in modules:
http_core.c
mod_so.c
mod_php4.c
suexec: disabled; invalid wrapper /u02/app/apache/bin/suexec

What's this error ?
benoit Bruckert
Honored Contributor

Re: Add OCI8 on an install Apache+PHP

Well,
This error isn't important, the su mode isn't included in the bin, but you don't use it !
In the phpinfo page, what is the line you have about configuration.
I.E the line with the configure command, you should have --with-oci8 and many others commands is it true ??

regards
Benoit
Une application mal pans├йe aboutit ├а une usine ├а gaze (GHG)