Results 1 to 10 of 10
  1. #1

    Has anoyone successfully installed php 5 and mysql 4.0.x at the same time?

    I have mysql 4.0.17 and php 4.3.8 installed in my dev box, running fine.

    I'm trying to go to 5 but configure is failing on the mysql hooks. Can someone give me their ./configure line for installing php 5 with a mysql that's > 4.0 and < than 4.1.

    Or at least tell me what to put at the end of the with-mysql= line. path to what exactly? I've tried everything,

    thanks.

  2. #2
    Join Date
    Mar 2003
    Location
    California USA
    Posts
    13,681
    Depends on how mysql is installed.. If its frpm rpms,

    --with-mysql=/usr
    Steven Ciaburri | Industry's Best Server Management - Rack911.com
    Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
    Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
    FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance

  3. #3
    It's installed from rpms but /usr doesn't work. What type of files should the path be to? like, what are some of them called so I can look for them?

  4. #4
    Join Date
    Mar 2003
    Location
    California USA
    Posts
    13,681
    what error are you getting exactly. If its rpm based, all you need is /usr
    Steven Ciaburri | Industry's Best Server Management - Rack911.com
    Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
    Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
    FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance

  5. #5
    First of all FYI I have php 4.3.8 running on the same machine and it works and uses mysql just fine, if that helps.

    My mysql is 4.0.17


    This is what configure says right before it dies:

    checking for MySQL support... yes
    checking for specified location of the MySQL UNIX socket... /var/lib/mysql/mysql.sock
    checking for MySQL UNIX socket location... /var/lib/mysql/mysql.sock
    checking for mysql_close in -lmysqlclient... no
    checking for mysql_error in -lmysqlclient... no
    configure: error: mysql configure failed. Please check config.log for more information.



    This is what the log says toward the end:


    configure:55758: checking for MSSQL support via FreeTDS
    configure:56352: checking for MySQL support
    configure:56398: checking for specified location of the MySQL UNIX socket
    configure:56455: checking for MySQL UNIX socket location
    configure:56611: checking for mysql_close in -lmysqlclient
    configure:56630: gcc -o conftest -g -O2 -Wl,-rpath,/usr//lib -L/usr//lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib conftest.c -lmysqlclient -lpng -lz -ljpeg -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
    /usr/bin/ld: cannot find -lmysqlclient
    collect2: ld returned 1 exit status
    configure: failed program was:
    #line 56619 "configure"
    #include "confdefs.h"
    /* Override any gcc2 internal prototype to avoid an error. */
    /* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply. */
    char mysql_close();

    int main() {
    mysql_close()
    ; return 0; }
    configure:56835: checking for mysql_error in -lmysqlclient
    configure:56854: gcc -o conftest -g -O2 -Wl,-rpath,/usr//lib -L/usr//lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib -Wl,-rpath,/usr/local -L/usr/local conftest.c -lmysqlclient -lz -lpng -lz -ljpeg -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
    /usr/bin/ld: cannot find -lmysqlclient
    collect2: ld returned 1 exit status
    configure: failed program was:
    #line 56843 "configure"
    #include "confdefs.h"
    /* Override any gcc2 internal prototype to avoid an error. */
    /* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply. */
    char mysql_error();

    int main() {
    mysql_error()
    ; return 0; }

  6. #6
    Join Date
    Mar 2003
    Location
    California USA
    Posts
    13,681
    rpm -qa | grep -i mysql
    Steven Ciaburri | Industry's Best Server Management - Rack911.com
    Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
    Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
    FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance

  7. #7
    uh oh. I think I know what you're going to say.

    rpm -qa | grep -i mysql
    MySQL-server-4.0.17-0
    MySQL-devel-4.0.18-0
    libmysql12-4.0.15-1mdk
    MySQL-client-4.0.17-0

    Hey, one more q- when I upgrade, I know I need MySQL-client and MySQL-server, but do I also need MySQL-devel or MySQL-shared?

  8. #8
    Join Date
    Mar 2003
    Location
    California USA
    Posts
    13,681
    Your problem lies in the fact that you dont have the dynamic libs installed, I believe.

    http://dev.mysql.com/downloads/mysql/4.0.html
    Steven Ciaburri | Industry's Best Server Management - Rack911.com
    Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
    Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
    FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance

  9. #9
    oooohh, I thought the-devel was all I neded but I need -shared. I see.

    Wow it worked! I guess it doesn't matter that my revision numbers are different? I just installed the shared-4.0.24 without upgrading the -server and -client rpms.

    I can't run php 4 and php 5 at the same time as apache modules, right? I've read I have to run one as cgi?

    Anyway thanks very much (I heard rack911 was good).

  10. #10
    Join Date
    Mar 2003
    Location
    California USA
    Posts
    13,681
    That is correct on the php 4 / php 5. One needs to be ran as a cgi. The shared libs are not "really" a big deal when it comes to version numbers. Client/server tends to be more picky.
    Steven Ciaburri | Industry's Best Server Management - Rack911.com
    Software Auditing - 400+ Vulnerabilities Found - Quote @ https://www.RACK911Labs.com
    Fully Managed Dedicated Servers (Las Vegas, New York City, & Amsterdam) (AS62710)
    FreeBSD & Linux Server Management, Security Auditing, Server Optimization, PCI Compliance

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •