LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   php 5.2.11 source make install problem (https://www.linuxquestions.org/questions/linux-software-2/php-5-2-11-source-make-install-problem-757795/)

kingkashif 09-25-2009 04:28 PM

php 5.2.11 source make install problem
 
hello everyone..

well i had PHP 5.1.6 installed using yum on my centos 5.3 system but i wanted 5.2.x so i downloaded it's source and compiled installed it ..

The make install process went on successfully but in the end i did see some warnings .. now
when i do
Code:

/usr/local/bin/php --version
then i get it's version but with following warnings..
Code:

PHP Warning:  PHP Startup: dbase: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: dom: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: gd: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: imap: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: mbstring: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: mysql: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: mysqli: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: PDO: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: pdo_mysql: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: pdo_sqlite: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: SQLite: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: xmlreader: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: xmlwriter: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP Warning:  PHP Startup: xsl: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP    compiled with module API=20060613, debug=0, thread-safety=0
These options need to match
 in Unknown on line 0
PHP 5.2.11 (cli) (built: Sep 25 2009 23:09:30)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies

don't know why

i configure php with following

Code:

./configure –with-config-file-path=/etc –with-config-file-scan-dir=/etc/php.d –with-apxs2 –with-libdir=lib –with-mysql –with-mysqli –with-zlib
Thanks in advance for looking at the post and your help .. :)


regards

kingkashif 09-26-2009 06:12 AM

any one ?

erikig 09-26-2009 08:20 PM

PHP Compile/Installation Error
 
Quote:

Originally Posted by kingkashif (Post 3697607)
any one ?

Hey kingkashif,

I was having the exact same issue with my newly compiled PHP install .
"Module compiled with module"
etc etc
"These options need to match"

This happens because when PHP is being compiled it generates new modules (*.a and *.so) files (in your case dbase.a & so, dom.a & so, gd, imap etc).

In order not to overwrite the original .so files it places a copy of the new (*.a & *.so) files in a different folder during "make install"

In my case "make install" copied the new modules to: /usr/lib/20060613/
The default modules directory was: /usr/lib/php/modules

If you want to know where make install will be copying the files do a dry run of make install thusly:

Code:

make install -n
All I had to do was backup the orginal modules:

Code:

cd /usr/lib/php/modules
tar -cvzf 20090926.php-modules.tgz
mv 20090926.php-modules.tgz /safe/backup/directory

Then copy the new modules in:

Code:

cp -a /usr/lib/20060613/* /usr/lib/php/modules
I was a little thrown off and I came across your question, hope that helps.

Thanks

Eric


All times are GMT -5. The time now is 10:04 AM.