Hi forum!
I tried to install Bugzilla on a SuSE 8.2 distribution. For that I installed MySQL 4.1, which works just fine. However, when I run the ./checksetup.pl out of Bugzilla directory it asks me to execute:
/usr/bin/perl -MCPAN -e 'install "DBD::mysql"'
to install the missing Perl module. That executed, the script fails and returns:
An error occurred while linking the DBD::mysql driver. The error
message seems to indicate that you don't have a libz.a,
or a libz.so. This is typically resolved by:
1.) You may try to remove the -lz or -lgz flag from the libs list
by using the --libs switch for "perl Makefile.PL".
2.) On Red Hat Linux install libz-devel
3.) On other systems, please contact the mailing list
Msql-Mysql-modules@lists.mysql.com
Any idea how to solve this?
Best,
Tobias
P.S.: output see below
------------------------------------------------------------------------------------------------------------------
CPAN.pm: Going to build R/RU/RUDY/DBD-mysql-2.9004.tar.gz
I will use the following settings for compiling and testing:
cflags (mysql_config) = -I/opt/mysql/include -mcpu=pentiumpro
libs (mysql_config) = -L/opt/mysql/lib -lmysqlclient -lz -lcrypt -lnsl -lm -lc -lnss_files -lnss_dns -lresolv -lc -lnss_files -lnss_dns -lresolv
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
Using DBI 1.48 (for perl 5.008 on i586-linux-thread-multi) installed in /usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/auto/DBI/
Writing Makefile for DBD::mysql
cp lib/DBD/mysql/GetInfo.pm blib/lib/DBD/mysql/GetInfo.pm
cp lib/DBD/mysql.pm blib/lib/DBD/mysql.pm
cp lib/DBD/mysql/INSTALL.pod blib/lib/DBD/mysql/INSTALL.pod
cp lib/Mysql.pm blib/lib/Mysql.pm
cp lib/Mysql/Statement.pm blib/lib/Mysql/Statement.pm
cp lib/Bundle/DBD/mysql.pm blib/lib/Bundle/DBD/mysql.pm
cc -c -I/usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/auto/DBI/ -I/opt/mysql/include -mcpu=pentiumpro -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O3 --pipe -DVERSION=\"2.9004\" -DXS_VERSION=\"2.9004\" -fPIC "-I/usr/lib/perl5/5.8.0/i586-linux-thread-multi/CORE" dbdimp.c
/usr/bin/perl -p -e "s/~DRIVER~/mysql/g" /usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/auto/DBI//Driver.xst > mysql.xsi
/usr/bin/perl /usr/lib/perl5/5.8.0/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.8.0/ExtUtils/typemap mysql.xs > mysql.xsc && mv mysql.xsc mysql.c
Warning: duplicate function definition 'do' detected in mysql.xs, line 196
Warning: duplicate function definition 'rows' detected in mysql.xs, line 294
cc -c -I/usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/auto/DBI/ -I/opt/mysql/include -mcpu=pentiumpro -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O3 --pipe -DVERSION=\"2.9004\" -DXS_VERSION=\"2.9004\" -fPIC "-I/usr/lib/perl5/5.8.0/i586-linux-thread-multi/CORE" mysql.c
Running Mkbootstrap for DBD::mysql ()
chmod 644 mysql.bs
rm -f blib/arch/auto/DBD/mysql/mysql.so
LD_RUN_PATH="/opt/mysql/lib:/lib" /usr/bin/perl myld cc -shared dbdimp.o mysql.o -o blib/arch/auto/DBD/mysql/mysql.so -L/opt/mysql/lib -lmysqlclient -lz -lcrypt -lnsl -lm -lc -lnss_files -lnss_dns -lresolv -lc -lnss_files -lnss_dns -lresolv
/usr/lib/gcc-lib/i486-suse-linux/3.3/../../../../i486-suse-linux/bin/ld: cannot find -lz
collect2: ld returned 1 exit status
An error occurred while linking the DBD::mysql driver. The error
message seems to indicate that you don't have a libz.a,
or a libz.so. This is typically resolved by:
1.) You may try to remove the -lz or -lgz flag from the libs list
by using the --libs switch for "perl Makefile.PL".
2.) On Red Hat Linux install libz-devel
3.) On other systems, please contact the mailing list
Msql-Mysql-modules@lists.mysql.com
For further hints, see INSTALL.html, section Linker flags.
make: *** [blib/arch/auto/DBD/mysql/mysql.so] Error 1
/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
------------------------------------------------------------------------------------------------------------------