Surfer
09-27-2002, 05:13 AM
Hi,
I need to re-compile PHP on my Raq4i. Here are the specs I need:
PHP (PHP 4.2.2 and above) :
1.1) compiled as Apache Module :
- with MySQL support
- with Curl (for PayPal IPN)
- enable socket
1.2) compiled as CGI
- all the options for compiling as Apache Module plus
enable pcntl (process control -- to allow the script to
act as a daemon)
- note : you shouldnt compile with Optimizer coz pcntl
doesnt work with optimizer
Anyone that can help me with this? Where do I start?
Thanks
:D
blacknight
09-27-2002, 04:35 PM
I posted instructions on compililng PHP from source some time back. If you need to add extra libraries etc., it's not that difficult AS LONG AS you have the correct required libraries installed.
If you have a look on the PHP site you will find comprehensive details for installing extra libraries etc.,
Surfer
09-28-2002, 04:18 AM
Thanks, I'll try to find your instructions. I don't think I need any extra libraries...
:D
blacknight
09-29-2002, 03:00 PM
If you're still having problems let me know...
AprilHost
10-01-2002, 07:06 AM
Surfer,
Did you actually find the instructions? If yes, please psot the instructions URL here.
cyrusTvirus
10-01-2002, 07:57 AM
Have a look here.
http://www.uk2raq.com/raqfaq/raqfaqshow.php?faq=43
Surfer
10-17-2002, 06:19 AM
Originally posted by blacknight
If you're still having problems let me know...
I found this thread http://www.webhostingtalk.com/showthread.php?threadid=61449
I am going to start installing PHP today! I'll let you know how it goes!
:D
Surfer
10-17-2002, 06:22 AM
BTW:
How do I do this?
1.2) compiled as CGI
- all the options for compiling as Apache Module plus
enable pcntl (process control -- to allow the script to
act as a daemon)
Thanks
blacknight
10-17-2002, 02:11 PM
to compile as CGI (eg. /usr/bin/php) take out the reference to apxs in the configure command
Surfer
10-17-2002, 02:55 PM
Thanks for your reply!
I figured this out! What I have understood so far is that I basically do the same as the apache module (but without apxs) and then don't do the final "make install" command. I then put the binary "PHP" file where I want it.
My problem so far is that I get an error when I am trying the "make" command. Configure went fine!
Error (last couple of lines):
libtool: link: warning: library `/usr/lib/libgdbm.la' was moved.
./.libs/libphp4.a(browscap.lo): In function `browser_reg_compare':
/home/php4_2/php-4.2.3/ext/standard/browscap.c:193: undefined reference to `php_regcomp'
/home/php4_2/php-4.2.3/ext/standard/browscap.c:196: undefined reference to `php_regexec'
/home/php4_2/php-4.2.3/ext/standard/browscap.c:199: undefined reference to `php_regfree'
./.libs/libphp4.a(reg.lo): In function `_php_regcomp':
/home/php4_2/php-4.2.3/ext/standard/reg.c:50: undefined reference to `php_regcomp'
./.libs/libphp4.a(reg.lo): In function `_free_reg_cache':
/home/php4_2/php-4.2.3/ext/standard/reg.c:69: undefined reference to `php_regfree'
./.libs/libphp4.a(reg.lo): In function `php_reg_eprint':
/home/php4_2/php-4.2.3/ext/standard/reg.c:119: undefined reference to `php_regerror'
/home/php4_2/php-4.2.3/ext/standard/reg.c:124: undefined reference to `php_regerror'
/home/php4_2/php-4.2.3/ext/standard/reg.c:129: undefined reference to `php_regerror'
/home/php4_2/php-4.2.3/ext/standard/reg.c:140: undefined reference to `php_regerror'
./.libs/libphp4.a(reg.lo): In function `php_ereg':
/home/php4_2/php-4.2.3/ext/standard/reg.c:207: undefined reference to `php_regexec'
./.libs/libphp4.a(reg.lo): In function `php_reg_replace':
/home/php4_2/php-4.2.3/ext/standard/reg.c:321: undefined reference to `php_regexec'
./.libs/libphp4.a(reg.lo): In function `php_split':
/home/php4_2/php-4.2.3/ext/standard/reg.c:580: undefined reference to `php_regexec'
./.libs/libphp4.a(url.lo): In function `php_url_parse':
/home/php4_2/php-4.2.3/ext/standard/url.c:74: undefined reference to `php_regcomp'
/home/php4_2/php-4.2.3/ext/standard/url.c:80: undefined reference to `php_regexec'
/home/php4_2/php-4.2.3/ext/standard/url.c:115: undefined reference to `php_regfree'
/home/php4_2/php-4.2.3/ext/standard/url.c:118: undefined reference to `php_regcomp'
/home/php4_2/php-4.2.3/ext/standard/url.c:118: undefined reference to `php_regexec'
/home/php4_2/php-4.2.3/ext/standard/url.c:127: undefined reference to `php_regfree'
/home/php4_2/php-4.2.3/ext/standard/url.c:154: undefined reference to `php_regfree'
/home/php4_2/php-4.2.3/ext/standard/url.c:157: undefined reference to `php_regfree'
collect2: ld returned 1 exit status
make[1]: *** [php] Error 1
make[1]: Leaving directory `/home/php4_2/php-4.2.3'
make: *** [all-recursive] Error 1
blacknight
10-17-2002, 03:05 PM
If you've already used the same source to compile the Apache module you'll need to run 'make clean' first.
The run configure without the apxs.
make
make install
The location of php.ini won't make any difference unless you've taken out a lot of other options from the config (at least it shouldn't as far as I can remember)
Beware of using the CGI, as it is an extra security risk.
Surfer
10-17-2002, 05:11 PM
Thanks that could be it!
Should I really run "make install"?
:D