J'ai compilé apache2 et php5 comme suit : (sous mandriva 2008.1)
$ su Mot de passe [root@localhost ] # cd /usr/src [root@localhost ] # tar -zxvf httpd-2.2.8.tar.gz [root@localhost ] # tar -zxvf php-5.2.6.tar.gz [root@localhost ] # cd httpd-2.2.8 [root@localhost httpd-2.2.8] # ./configure --prefix=/usr/local/apache [root@localhost httpd-2.2.8] # make [root@localhost httpd-2.2.8] # make install [root@localhost httpd-2.2.8] # /usr/local/apache/bin/apachectl start //je suis aller vérifier que 127.0.0.1 affichait bien "It Works!" [root@localhost httpd-2.2.8] # /usr/local/apache/bin/apachectl stop [root@localhost httpd-2.2.8] # cd ../php-5.2.6 [root@localhost php-5.2.6] # ./configure --with-apxs2=/usr/local/apache/bin/apxs [root@localhost php-5.2.6] # make [root@localhost php-5.2.6] # make install [root@localhost php-5.2.6] # cp php.ini-dist /usr/local/lib/php.ini //ensuite j'ai modifier le fichier /usr/local/apache/conf/httpd.conf comme suit : // LoadModule php5_module modules/libphp5.so // DirectoryIndex index.php index.html // AddType application/x-httpd-php .php // AddType application/x-httpd-php-source .phps //j'ai également modifier le fichier /usr/local/apache/htdocs/index.html comme suit : // index.html -> index.php // <?php echo "PHP Works!"; ?> //après enregistrement, j'ai re démarré apache [root@localhost php-5.2.6] # /usr/local/apache/bin/apachectl start //je suis aller vérifier que 127.0.0.1 affichait bien "It Works!" et "PHP Works!", tout est ok !
maintenant, ce que je souhaite, c'est installer mysql dans /usr/local/mysql, et faire en sorte que apache et php en tienne compte.
mais le problème est : comment faire ?
merci d'avance pour votre aide, tom
