Install DBD::mysql failed

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Yun Guan

    #1

    Install DBD::mysql failed

    Hello mysql gurus,

    I am trying to run perl on mysql database on Red Hat box. I want to install
    DBI and DBD:mysql using CPAN:

    perl -MCPAN -e shell
    cpan>install DBI

    The above succeeded, but
    cpan>install DBD::mysql

    gave me with a lot but same errors:
    ----------------------------------------------------------------------------
    --
    cpan> install DBD::mysql
    Running install for module DBD::mysql
    Running make for R/RU/RUDY/DBD-mysql-2.9003.tar.gz
    Fetching with LWP:
    ftp://ftp.perl.org/pub/CPAN/authors/...-2.9003.tar.gz
    Fetching with LWP:
    ftp://ftp.perl.org/pub/CPAN/authors/...RUDY/CHECKSUMS
    Checksum for
    /root/.cpan/sources/authors/id/R/RU/RUDY/DBD-mysql-2.9003.tar.gz ok
    DBD-mysql-2.9003/
    DBD-mysql-2.9003/t/
    DBD-mysql-2.9003/t/mysql2.t
    DBD-mysql-2.9003/t/akmisc.t
    DBD-mysql-2.9003/t/60leaks.t
    DBD-mysql-2.9003/t/10dsnlist.t
    DBD-mysql-2.9003/t/ak-dbd.t
    DBD-mysql-2.9003/t/50chopblanks.t
    DBD-mysql-2.9003/t/mysql.t
    DBD-mysql-2.9003/t/lib.pl
    DBD-mysql-2.9003/t/40blobs.t
    DBD-mysql-2.9003/t/40nulls.t
    DBD-mysql-2.9003/t/insertid.t
    DBD-mysql-2.9003/t/40listfields.t
    DBD-mysql-2.9003/t/40bindparam.t
    DBD-mysql-2.9003/t/mysql.dbtest
    DBD-mysql-2.9003/t/dbdadmin.t
    DBD-mysql-2.9003/t/20createdrop.t
    DBD-mysql-2.9003/t/00base.t
    DBD-mysql-2.9003/t/30insertfetch.t
    DBD-mysql-2.9003/t/40numrows.t
    DBD-mysql-2.9003/t/50commit.t
    DBD-mysql-2.9003/t/mysql.mtest
    DBD-mysql-2.9003/MANIFEST
    DBD-mysql-2.9003/myld
    DBD-mysql-2.9003/dbdimp.c
    DBD-mysql-2.9003/lib/
    DBD-mysql-2.9003/lib/DBD/
    DBD-mysql-2.9003/lib/DBD/mysql/
    DBD-mysql-2.9003/lib/DBD/mysql/GetInfo.pm
    DBD-mysql-2.9003/lib/DBD/mysql/INSTALL.pod
    DBD-mysql-2.9003/lib/DBD/mysql.pm
    DBD-mysql-2.9003/lib/Mysql/
    DBD-mysql-2.9003/lib/Mysql/Statement.pm
    DBD-mysql-2.9003/lib/Bundle/
    DBD-mysql-2.9003/lib/Bundle/DBD/
    DBD-mysql-2.9003/lib/Bundle/DBD/mysql.pm
    DBD-mysql-2.9003/lib/Mysql.pm
    DBD-mysql-2.9003/dbdimp.h
    DBD-mysql-2.9003/mysql.xs
    DBD-mysql-2.9003/MANIFEST.SKIP
    DBD-mysql-2.9003/README
    DBD-mysql-2.9003/INSTALL.html
    DBD-mysql-2.9003/Makefile.PL
    DBD-mysql-2.9003/ChangeLog
    DBD-mysql-2.9003/constants.h
    DBD-mysql-2.9003/TODO

    CPAN.pm: Going to build R/RU/RUDY/DBD-mysql-2.9003.tar.gz

    Can't exec "mysql_conf ig": No such file or directory at Makefile.PL line
    174.
    readline() on closed filehandle PIPE at Makefile.PL line 176.
    Can't exec "mysql_conf ig": No such file or directory at Makefile.PL line
    174.
    readline() on closed filehandle PIPE at Makefile.PL line 176.
    .....

    I will use the following settings for compiling and testing:

    cflags (guessed) = -I/usr/local/mysql/include
    libs (guessed) = -L/usr/local/mysql/lib -lmysqlclient -lz -lgz
    nocatchstderr (default) = 0
    nofoundrows (default) = 0
    ssl (guessed) = 0
    testdb (default) = test
    testhost (default) =
    testpassword (default) =
    testuser (default) =

    To change these settings, see 'perl Makefile.PL --help' and
    'perldoc INSTALL'.

    Checking if your kit is complete...
    Looks good
    Unsuccessful stat on filename containing newline at
    /usr/lib/perl5/5.8.0/ExtUtils/Liblis
    t/Kid.pm line 97.
    ....
    Note (probably harmless): No library found for -lgz
    Multiple copies of Driver.xst found in:
    /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread
    -multi/auto/DBI
    /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/auto/DBI at Mak
    efile.PL line 295
    Using DBI 1.38 installed in
    /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/auto/
    DBI
    Writing Makefile for DBD::mysql
    Makefile:89: *** missing separator. Stop.
    /usr/bin/make -- NOT OK
    Running make test
    Can't test without successful make
    Running make install
    make had returned bad status, install seems impossible

    cpan>

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

    I checked DBD-mysql-2.9003/Makefile.PL, the line 174 is:

    open(PIPE, "mysql_conf ig" --$param |");

    What is this mysql_config file and where I can find it?

    Thanks a lot for the help.

    --
    Allen Guan



Working...