LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-17-2005, 09:06 AM   #1
krunal
LQ Newbie
 
Registered: Apr 2005
Posts: 14

Rep: Reputation: 0
problems in installing php with mysql


hi

i tried to install php using following command :
--------------------------------------------------------------------------------------

'./configure' '--enable-versioning' '--enable-memory-limit' '--with-layout=GNU' '--with-config-file-scan-dir=/usr/local/etc/php' '--with-mysql=/usr/local' '--disable-all' '--with-regex=php' '--disable-cli' '--with-apxs2=/usr/local/sbin/apxs' '--prefix=/usr/local' 'i386-portbld-freebsd5.4'

--------------------------------------------------------------------------------------

after running "Make" and "make install" when i tried to restart apache, it gave me the following error:

--------------------------------------------------------------------------------------

Syntax error on line 274 of /usr/local/etc/apache2/httpd.conf:
Cannot load /usr/local/libexec/apache2/libphp4.so into server: /usr/local/libexec/apache2/libphp4.so: Undefined symbol "mysql_drop_db"
--------------------------------------------------------------------------------------

Line number 274 in httpd.conf is :

LoadModule php4_module libexec/apache2/libphp4.so

--------------------------------------------------------------------------------------

In the above configure command if i remove the path to mysql i.e.

'--with-mysql' instead of '--with-mysql=/usr/local'

then apache does not give any error. But i don't want it to do that way.

Please help.
 
Old 08-17-2005, 09:50 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,516

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
Quote:
--with-mysql=/usr/local
Are you sure the /usr/local is you mysql install directory. It should be something like /usr/local/mysql
 
Old 08-18-2005, 08:15 AM   #3
krunal
LQ Newbie
 
Registered: Apr 2005
Posts: 14

Original Poster
Rep: Reputation: 0
i re-installed mysql at /usr/local/mysql.
but the same problem persisted.(when i installed using -with--mysql=/usr/local/mysql)
Then i installed php without giving the path to mysql i.e. only '-with--mysql'.
And then installed the package "php4-mysql".
Now it is working fine.

Any thoughts on what was the previous problem ?
 
Old 08-18-2005, 09:38 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,516

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
When you compile php with the "--with-mysql" you use the built-in mysql support of php. When you add the path to your mysql installation then php uses the header files of your version of mysql to compile the mysql support. I don't know how you installed mysql, or what php4-mysql package is, but I suspect that you missed those header files, or they were the wrong version and that package fixed it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems installing MySql & PHP from rpms? Nelsond Fedora 3 08-12-2005 12:09 PM
problems installing MySQL & PHP on FC4 alpineedge3 Linux - Newbie 9 07-23-2005 06:00 PM
Installing PHP 5 on Apache_v2 MySQL q.sa Linux - Software 1 06-20-2005 02:14 AM
Installing Apache, MySQL and PHP foo_mulan Linux - Newbie 1 07-16-2004 07:28 AM
Installing MySQL.4.0.17 and php support for Mysql on RedHat 9.0 Neha Linux - Software 13 12-29-2003 01:06 AM


All times are GMT -5. The time now is 02:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration