Problem installing PERL DBD::mysql

Problem installing PERL DBD::mysql

am 15.08.2006 00:13:25 von cal

Machine info:

[iepm@snv1 utils]$ uname -a
Linux snv1 2.6.9-34.0.2.ELsmp #1 SMP Fri Jun 30 10:32:04 EDT 2006 x86_64 =
x86_64 x86_64 GNU/Linux
[iepm@snv1 utils]$ perl -v
This is perl, v5.8.8 built for x86_64-linux
[iepm@snv1 utils]$ more /etc/redhat-release
Red Hat Enterprise Linux WS release 4 (Nahant Update 4)


--------------------------------------------------
I am having a hard time installing DBD:mysql on 64 bit machine =
snv1.ultralight.org=20

/usr/bin/perl MCPAN -e shell
CPAN> install DBD::mysql

Dies with errors...so I decided to do it from the source, and it also =
complains....here is the output from the source install:

[root@snv1 DBD-mysql-3.0006]# /usr/bin/perl Makefile.PL I will use the =
following settings for compiling and testing:

cflags (mysql_config) =3D -I/usr/local/include/mysql
embedded (mysql_config) =3D
libs (mysql_config) =3D -L/usr/local/lib/mysql -lmysqlclient =
-lz -lcrypt -lnsl -lm
mysql_config (guessed ) =3D mysql_config
nocatchstderr (default ) =3D 0
nofoundrows (default ) =3D 0
ssl (guessed ) =3D 0
testdb (default ) =3D test
testhost (default ) =3D
testpassword (default ) =3D
testsocket (default ) =3D
testuser (default ) =3D

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

Using DBI 1.52 (for perl 5.008008 on x86_64-linux) installed in =
/usr/lib/perl5/site_perl/5.8.8/x86_64-linux/auto/DBI/
Writing Makefile for DBD::mysql
[root@snv1 DBD-mysql-3.0006]#
[root@snv1 DBD-mysql-3.0006]# make
cc -c -I/usr/lib/perl5/site_perl/5.8.8/x86_64-linux/auto/DBI =
-I/usr/local/include/mysql -DDBD_MYSQL_INSERT_ID_IS_GOO D -g =
-fno-strict-aliasing -pipe -Wdeclaration-after-statement =
-I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSE
T_BITS=3D64 -I/usr/include/gdbm -O2 -DVERSION=3D\"3.0006\" =
-DXS_VERSION=3D\"3.0006\" -fpic "-I/usr/lib/perl5/5.8.8/x86_64
-linux/CORE" dbdimp.c
cc -c -I/usr/lib/perl5/site_perl/5.8.8/x86_64-linux/auto/DBI =
-I/usr/local/include/mysql -DDBD_MYSQL_INSERT_ID_IS_GOO D -g =
-fno-strict-aliasing -pipe -Wdeclaration-after-statement =
-I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSE
T_BITS=3D64 -I/usr/include/gdbm -O2 -DVERSION=3D\"3.0006\" =
-DXS_VERSION=3D\"3.0006\" -fpic "-I/usr/lib/perl5/5.8.8/x86_64
-linux/CORE" mysql.c
mysql.xs: In function `XS_DBD__mysql__GetInfo_dbd_mysql_get_info':
mysql.xs:647: warning: ignoring return value of `Perl_newSViv', declared =
with attribute warn_unused_result
mysql.xs:650: warning: ignoring return value of `Perl_newSViv', declared =
with attribute warn_unused_result
mysql.xs:653: warning: ignoring return value of `Perl_newSVpv', declared =
with attribute warn_unused_result Running Mkbootstrap for DBD::mysql () =
chmod 644 mysql.bs rm -f blib/arch/auto/DBD/mysql/mysql.so =
LD_RUN_PATH=3D"/usr/local/lib/mysql" /usr/bin/perl myld cc -shared =
-L/usr/local/lib dbdimp.o mysql.o -o blib/arch/aut
o/DBD/mysql/mysql.so \
-L/usr/local/lib/mysql -lmysqlclient -lz -lcrypt -lnsl -lm \

/usr/bin/ld: /usr/local/lib/libz.a(compress.o): relocation R_X86_64_32 =
against `a local symbol' can not be used when making a shared object; =
recompile with -fPIC
/usr/local/lib/libz.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [blib/arch/auto/DBD/mysql/mysql.so] Error 1

I have tried using -fPIC, but I think I do not know how to tell it to =
use that correctly. I assume it is passed with --cflags on the 'perl =
Makefile.PL' line, but I can't get that to work.

Can someone tell me the syntax on the 'perl Makefile.PL' line, or, what =
the problem is and how can I get DBD::mysql to load?

By the way, perl Makefile.PL --help gives me..
[root@snv1 DBD-mysql-3.0006]# perl -Makefile.PL --help

Usage: perl [switches] [--] [programfile] [arguments]
-0[octal] specify record separator (\0, if no argument)
-a autosplit mode with -n or -p (splits $_ into @F)
-C[number/list] enables the listed Unicode features
-c check syntax only (runs BEGIN and CHECK blocks)
-d[:debugger] run program under debugger
-D[number/list] set debugging flags (argument is a bit mask or =
alphabets)
-e program one line of program (several -e's allowed, omit =
programfile)
-f don't do $sitelib/sitecustomize.pl at startup
-F/pattern/ split() pattern for -a switch (//'s are optional)
-i[extension] edit <> files in place (makes backup if extension =
supplied)
-Idirectory specify @INC/#include directory (several -I's allowed)
-l[octal] enable line ending processing, specifies line =
terminator
-[mM][-]module execute "use/no module..." before executing program
-n assume "while (<>) { ... }" loop around program
-p assume loop like -n but print line also, like sed
-P run program through C preprocessor before compilation
-s enable rudimentary parsing for switches after =
programfile
-S look for programfile using PATH environment variable
-t enable tainting warnings
-T enable tainting checks
-u dump core after parsing program
-U allow unsafe operations
-v print version, subversion (includes VERY IMPORTANT =
perl info)
-V[:variable] print configuration summary (or a single Config.pm =
variable)
-w enable many useful warnings (RECOMMENDED)
-W enable all warnings
-x[directory] strip off text before #!perl line and perhaps cd to =
directory
-X disable all warnings


Thanks, Connie
Connie Logg, Network Analyst
Stanford Linear Accelerator Center
ph: 650-926-2879=20
"Happiness is found along the way, not at the end of the road, and 'IF' =
is the middle word in life."

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=3Dgcdmg-mysql@m.gmane.org