I am forwarding to you instructions I received from HP on how to build PHP on HPUX 11

Note the change to the libtool hack...
##############################################
INSTALL_php_on_HP_apache.txt

-----------------------------------------------------------------------
Installation Instructions for PHP 4.0

Note: At some points you will need to use sudo if you are not root.
The following instructions are relevant only for the official HP
distribution of Apache (1.3.12), the version of gcc on the Open
Source Developer's Toolkit CD-ROM (X.Y.Z), and php-4.0.2.
Apache and gcc must be installed on your system before attempting
to compile PHP and mod_php.

QUICK INSTALL (DSO)

For this to work your Apache httpd must have mod_so enabled.
Check using httpd -l.  

  $ /opt/apache/bin/httpd -l

You should see something like:

Compiled-in modules:
  http_core.c
  mod_so.c

Chances are you will see a lot more modules than these two. That's ok, 
as long as mod_so.c shows up you can proceed with the following steps:

-----------------------------------------------------------------------
1. Unpack your distribution file.  

You can get the latest version from "http://www.php.net/";

  $ cd /opt
  $ mkdir php
  $ mv <wherever it is>/php-4.0.<?>.tar.gz /opt/php
  $ cd /opt/php

  $ gunzip -c php-4.0.x.tar.gz | tar xf -
  $ cd php-4.0.x

-----------------------------------------------------------------------
2. Configure PHP

When running configure, you should use at least the following
command line:

  $ ./configure --enable-libgcc --with-apxs=/opt/apache/bin/apxs

You can add other options if you like.  You can use the --help
option to configure to get a complete list.

After configure runs, you must edit the file libtool.  

  $ vi ./libtool

At line 184, you should change the line from:

  deplibs_check_method="unknown"
to
  deplibs_check_method="pass_all"

so that PHP and mod_php are properly compiled.

-----------------------------------------------------------------------
3. Compile and install the files.

Run make.  This should complete normally.

  $ make

Run make install.  This will fail when it attempts to call apxs.

  $ make install

Program will crash after apxs call.
Copy the call to apxs along with all its arguments.

Rename the file "libs/libphp4.sl" to "libs/libphp4.so".
  
  $ mv lib/libphp4.sl lib/libphp4.so

Re-run the command that you copied earlier but change the reference
of "lib/libphp4.sl" to "lib/php4.so":

  $ /opt/apache/bin/apxs -i -a -n php4 libs/libphp4.so

-----------------------------------------------------------------------
4. Setup the server

Next you must copy php.ini-dist to the appropriate place (normally
/usr/local/lib/php.ini) and edit it as necessary to set PHP options.

  $ sudo cp php.ini-dist /usr/local/lib/php.ini

The only thing left to do is to edit your httpd.conf file:

Look for the string "php4" and make sure that the "LoadModule"
and "AddModule" directives are outside any "IfDefine SSL" directives.

  $ vi /opt/apache/conf/httpd.conf 

  LoadModule php4_module        libexec/libphp4.so

  AddModule mod_php4.c

Also make sure the PHP 4 mime type is there and uncommented.  
You need a line that looks like this:

   AddType application/x-httpd-php .php

-----------------------------------------------------------------------
5. Testing it all worked

Restart your server. 

  $ sudo /opt/apache/bin/apachectl restart

You should be able to serve up PHP files now.  Make a test file called "test.php" and 
put some PHP tags in it such as <?phpinfo()?>.

  $ vi /opt/apache/htdocs/test.php

add

  <html> <head> </head> <body> <p> <?phpinfo()?> </p> </body> </html>

Enter following URL in your browser.

  http://<your server>/test.php

##############################################

Good Luck,

Jim


>>> "Impu" <[EMAIL PROTECTED]> 01/15 9:55 AM >>>
Hi,
      I will highly appreciate anyone who can help me with this problem. I
am simply unable to get this going, and need somebody to point me to the
right direction. Really a network engineer, but need to launch some of my
project to the web to impress folks :))

By the way, since PHP came, I now see all the good application require
PHP...but only binary available is for Windows only :(((

Ok, here I go...  My Server environment is HP-UX 10.20

Basically, I have downloaded PHP 4.0.6, Apache 1.3.22 and I already have
installed copy of mySQL 3.23.46.  So, from PHP Directory, I ran this command

./configure --with-mysql=/usr/local/mysql --with-apache=../apache_1.3.22

configure runs and find various dependencies.  In short, it finds gcc,
bison, gnu make and so on.  No error at all during configure script.

But as soon as I run make, I get

Making all in Zend
make[1]: Entering directory `/mnt/i3107tis/D0003/source/php/php-4.0.6/Zend'
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_language_scanner.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_ini_scanner.c
/bin/sh ../libtool --silent --mode=link gcc  -g -O2  -o libZend_c.la
zend_lang
uage_scanner.lo zend_ini_scanner.lo
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_language_parser.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_ini_parser.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_alloc.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_compile.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_constants.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_dynamic_array.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
  -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21 -g   -c ./zend_execute.c
/bin/sh ../libtool --silent --mode=compile
gcc -DHAVE_CONFIG_H -I. -I. -I../main
   -DSUPPORT_UTF8 -DXML_BYTE_ORDER=21  -g -O2 -c zend_execute_API.c
zend_execute_API.c: In function `zend_set_timeout':
zend_execute_API.c:720: storage size of `t_r' isn't known
zend_execute_API.c:721: `sigset_t' undeclared (first use in this function)
zend_execute_API.c:721: (Each undeclared identifier is reported only once
zend_execute_API.c:721: for each function it appears in.)
zend_execute_API.c:721: parse error before "sigset"
zend_execute_API.c:726: `ITIMER_PROF' undeclared (first use in this
function)
zend_execute_API.c:728: `sigset' undeclared (first use in this function)
zend_execute_API.c:730: `SIG_UNBLOCK' undeclared (first use in this
function)
zend_execute_API.c: In function `zend_unset_timeout':
zend_execute_API.c:746: storage size of `no_timeout' isn't known
zend_execute_API.c:750: `ITIMER_PROF' undeclared (first use in this
function)
make[1]: *** [zend_execute_API.lo] Error 1
make[1]: Leaving directory `/mnt/i3107tis/D0003/source/php/php-4.0.6/Zend'
make: *** [all-recursive] Error 1


Thank you very much for your help!

Impu
[EMAIL PROTECTED] 



-- 
PHP Install Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED] 
For additional commands, e-mail: [EMAIL PROTECTED] 
To contact the list administrators, e-mail: [EMAIL PROTECTED] 


--
PHP Install Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to