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

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

Post by Frederic Fau » Tue, 09 Jan 2001 05:29:00



Hi,

        I've been assigned the task of building an Apache server with
support for Sybase, PHP4, OpenSSL 0.9.6/mod_ssl ?, and apache 1.3.14.

I followed Israel Denis Jr/Eugene Otto's "The Soothingly Seamless
Setup of Apache, SSL, MySQL, and PHP" at DevShed, but compilation of
apache fails if I add PHP.  The same procedure w/out PHP works OK
(either port 80 or port 443.) As a non-developper, I'm totally in the
dark.

[/home/samba/temp/Apache/apache_1.3.14]# SSL_BASE=../openssl-0.9.6
/configure --enable-module=ssl
--activate-module=src/modules/php4/libphp4.a --enable-module=php4
--prefix=/usr/local/apache

Configuring for Apache, Version 1.3.14
(snip)
-L/home/samba/temp/Apache/openssl-0.9.6  -o helpers/dummy
helpers/dummy.c   -rdynamic -Lmodules/php4 -L../modules/php4
-L../../modules/php4 -lmodphp4  -lpam  -ldl -lresolv -lm -ldl -lcrypt
-lnsl  -lresolv   -lm -lcrypt  -lssl -lcrypto
/usr/bin/ld: cannot find -lmodphp4
collect2: ld returned 1 exit status
make: *** [dummy] Error 1

Any idea?

Thx
FF.

 
 
 

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

Post by moonie; » Wed, 10 Jan 2001 16:34:34



>Hi,

>    I've been assigned the task of building an Apache server with
>support for Sybase, PHP4, OpenSSL 0.9.6/mod_ssl ?, and apache 1.3.14.

>I followed Israel Denis Jr/Eugene Otto's "The Soothingly Seamless
>Setup of Apache, SSL, MySQL, and PHP" at DevShed, but compilation of
>apache fails if I add PHP.  The same procedure w/out PHP works OK
>(either port 80 or port 443.) As a non-developper, I'm totally in the
>dark.

>[/home/samba/temp/Apache/apache_1.3.14]# SSL_BASE=../openssl-0.9.6
>/configure --enable-module=ssl
>--activate-module=src/modules/php4/libphp4.a --enable-module=php4
>--prefix=/usr/local/apache

>Configuring for Apache, Version 1.3.14
>(snip)
>-L/home/samba/temp/Apache/openssl-0.9.6  -o helpers/dummy
>helpers/dummy.c   -rdynamic -Lmodules/php4 -L../modules/php4
>-L../../modules/php4 -lmodphp4  -lpam  -ldl -lresolv -lm -ldl -lcrypt
>-lnsl  -lresolv   -lm -lcrypt  -lssl -lcrypto
>/usr/bin/ld: cannot find -lmodphp4
>collect2: ld returned 1 exit status
>make: *** [dummy] Error 1

>Any idea?

>Thx
>FF.

Looks like PHP4 isn't installed. (or mod_php)
--
moonie ;)

Registered Linux User #175104
   (Registered at: http://counter.li.org)

KDE2
Kernel 2.4.0-test5
XFree86 4.0 Nvidia .94 drivers
RAID 0 Striped
Test-Pilots-R-Us ;)
ICQ #83003404
AIM mooniesdl3


 
 
 

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

Post by Frederic Fau » Thu, 11 Jan 2001 05:38:50




Quote:>>-L/home/samba/temp/Apache/openssl-0.9.6  -o helpers/dummy
>>helpers/dummy.c   -rdynamic -Lmodules/php4 -L../modules/php4
>>-L../../modules/php4 -lmodphp4  -lpam  -ldl -lresolv -lm -ldl -lcrypt
>>-lnsl  -lresolv   -lm -lcrypt  -lssl -lcrypto
>>/usr/bin/ld: cannot find -lmodphp4
>>collect2: ld returned 1 exit status
>>make: *** [dummy] Error 1
>Looks like PHP4 isn't installed. (or mod_php)

This is the first time I need to compile Apache with add-ons instead
of just using an RPM, so please bear with me.

Following instructions, I compiled and installed PHP4 before compiling
Apache, so I don't understand what you mean. Are there differents ways
other than doing the following?

# cd php-4.0.0
# ./configure --with-apache=../apache_1.3.12 --enable-track-vars
# make
# make install
# cp php.ini-dist /usr/local/lib/php.ini

(here, compiled and installed OpenSSL and mod_ssl)

# cd apache_1.3.12
# SSL_BASE=../openssl-0.9.x \
RSA_BASE=../rsaref-2.0/local \
./configure \
--enable-module=ssl \
--activate-module=src/modules/php4/libphp4.a \
--enable-module=php4 \
--prefix=/usr/local/apache \
--enable-shared=ssl
# make

Maybe you mean that the above installs PHP4 as a stand-alone app
instead of an Apache module?

Thx much for any tip
FF.

 
 
 

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

Post by Frederic Fau » Sat, 13 Jan 2001 03:14:55




Quote:>Looks like PHP4 isn't installed. (or mod_php)

        Finally found what kept Apache from compiling. For those
interested, here's how to build Apache with SSL and PHP4:

Follow the "The Soothingly Seamless Setup of Apache, SSL, MySQL, and
PHP" at
http://www.devshed.com/Server_Side/PHP/SoothinglySeamless/print.html

Watch out: Whether using PHP4.0.2 or PHP4.0.4, there's no libphp4.a
library like it says in the documentation. Instead, just cp
libmodphp4.a libphp4.a.

Also, SSL_BASE=SYSTEM didn't work for me when configuring Apache.
Instead, I had to use SSL_BASE=../openssl.x.y.

Finally, even if OpenSSL is already through RPM (eg. because you need
it to access the host through SSH), you still need to compile the
source in eg. /tmp/openssl

HTH
FF.