[rhn-users] How to install perl-DBD-MySQL RPM package

SSI - Benjamin Morel bmorel at ssi.fr
Thu May 5 15:59:52 UTC 2005


Thanks Dan, the idea is great !

Unfortunately, while rebuilding rpm from srpm, here is the error I get :

[root at xxx root]# cd /var/spool/up2date/
[root at xxx up2date]# rpmbuild --rebuild perl-DBD-MySQL-2.1021-3.src.rpm
Installation de perl-DBD-MySQL-2.1021-3.src.rpm
Exécution_de(%prep): /bin/sh -e /var/tmp/rpm-tmp.4446
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf DBD-mysql-2.1021
+ /usr/bin/gzip -dc /usr/src/redhat/SOURCES/DBD-mysql-2.1021.tar.gz
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd DBD-mysql-2.1021
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,g-w,o-w .
+ exit 0
Exécution_de(%build): /bin/sh -e /var/tmp/rpm-tmp.4446
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd DBD-mysql-2.1021
+ LANG=C
+ export LANG
+ unset DISPLAY
+ CFLAGS=-O2 -g -pipe -march=i386 -mcpu=i686
+ perl Makefile.PL PREFIX=/var/tmp/perl-DBD-MySQL-2.1021-root/usr 
INSTALLDIRS=vendor --ssl
I will use the following settings for compiling and testing:

  cflags        (mysql_config) 
= -I/usr/include/mysql -mcpu=i486 -fno-strength-reduce
  libs          (mysql_config) 
= -L/usr/lib/mysql -lmysqlclient -lz -lcrypt -lnsl -lm -lc -lnss_files -lnss_dns 
 -lresolv -lc -lnss_files -lnss_dns -lresolv
  nocatchstderr (default     ) = 0
  ssl           (Users choice) = 1
  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.32 installed in 
/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/auto/DBI
Writing Makefile for DBD::mysql
+ make
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/DBD/mysql.pod blib/lib/DBD/mysql.pod
cp lib/Bundle/DBD/mysql.pm blib/lib/Bundle/DBD/mysql.pm
gcc -c  -I/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/auto/DBI  
-I/usr/include/mysql -mcpu=i486 -fno-strength-reduce -DDBD_MYSQL_WITH_SSL -D_REENTRANT 
 -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -fno-strict-aliasing -I/usr/local/include 
 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe 
 -march=i386 -mcpu=i686   -DVERSION=\"2.1021\" -DXS_VERSION=\"2.1021\" -fPIC 
"-I/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE"   dbdimp.c
dbdimp.c: In function `mysql_db_login':
dbdimp.c:847: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
dbdimp.c: In function `mysql_db_commit':
dbdimp.c:892: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
dbdimp.c: In function `mysql_db_rollback':
dbdimp.c:913: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
dbdimp.c: In function `mysql_db_FETCH_attrib':
dbdimp.c:1160: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1164: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1170: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1177: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1192: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1200: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c:1205: warning: initialization discards qualifiers from pointer 
target type
dbdimp.c: In function `mysql_st_internal_execute':
dbdimp.c:1350: warning: passing arg 3 of `mysql_dr_error' discards 
qualifiers from pointer target type
dbdimp.c:1362: warning: passing arg 3 of `mysql_dr_error' discards 
qualifiers from pointer target type
dbdimp.c:1371: warning: passing arg 3 of `mysql_dr_error' discards 
qualifiers from pointer target type
dbdimp.c: In function `mysql_st_fetch':
dbdimp.c:1516: warning: passing arg 3 of `mysql_dr_error' discards 
qualifiers from pointer target type
dbdimp.c: In function `mysql_db_reconnect':
dbdimp.c:2033: warning: passing arg 3 of `mysql_dr_error' discards 
qualifiers from pointer target type
/usr/bin/perl -p -e "s/~DRIVER~/mysql/g" < 
/usr/lib/perl5/vendor_perl/5.8.0/i386-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 'rows' detected in mysql.xs, line 289
gcc -c  -I/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/auto/DBI  
-I/usr/include/mysql -mcpu=i486 -fno-strength-reduce -DDBD_MYSQL_WITH_SSL -D_REENTRANT 
 -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBUGGING -fno-strict-aliasing -I/usr/local/include 
 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe 
 -march=i386 -mcpu=i686   -DVERSION=\"2.1021\" -DXS_VERSION=\"2.1021\" -fPIC 
"-I/usr/lib/perl5/5.8.0/i386-linux-thread-multi/CORE"   mysql.c
mysql.xs: In function `XS_DBD__mysql__dr__ListDBs':
mysql.xs:54: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
mysql.xs: In function `XS_DBD__mysql__dr__admin_internal':
mysql.xs:93: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
mysql.xs:99: too few arguments to function `mysql_shutdown'
mysql.xs:137: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
mysql.xs: In function `XS_DBD__mysql__db__ListDBs':
mysql.xs:180: warning: passing arg 3 of `mysql_dr_error' discards qualifiers 
from pointer target type
make: *** [mysql.o] Error 1
erreur: Mauvais status de sortie pour /var/tmp/rpm-tmp.4446 (%build)


Erreur de construction de RPM:
    Mauvais status de sortie pour /var/tmp/rpm-tmp.4446 (%build)
[root at rocco up2date]#



(this means "bad exit status")

Any idea?

Thanks
Ben


----- Original Message ----- 
From: "Daniel Wittenberg" <daniel-wittenberg at starken.com>
To: "Red Hat Network Users List" <rhn-users at redhat.com>
Sent: Thursday, May 05, 2005 5:12 PM
Subject: Re: [rhn-users] How to install perl-DBD-MySQL RPM package


> up2date --get-source perl-DBD-MySQL
> rpmbuild --rebuild /var/spool/up2date/mysql-3.23.58-15.RHEL3.1*.src.rpm
>
> Basically, just download and reubild the src.rpm and then you should be
> able to install.  It just needs to be rebuilt against your current
> version mysql libraries.  You can force this version to be installed,
> but I can pretty much guarantee it won't work right.
>
> Dan
>
> On Thu, 2005-05-05 at 17:07 +0200, SSI - Benjamin Morel wrote:
>> Hello all,
>> I've got a problem while trying to install package perl-DBD-MySQL.
>> I've installed MySQL 4.1 from mysql.com's rpms, and they do not
>> provide rpm for perl-DBD-MySQL
>> So I decided to try to install the package from rhn, with up2date,
>> here are the results :
>>
>> ---------------------------------------------------------------------------------------------
>>
>> [root at xxx i386]# up2date --install perl-DBD-MySQL
>>
>> Fetching Obsoletes list for channel: rhel-i386-es-3...
>>
>> Fetching rpm headers...
>> ########################################
>>
>> Name                                    Version        Rel
>> ----------------------------------------------------------
>> perl-DBD-MySQL                          2.1021         3
>> i386
>>
>>
>> Testing package set / solving RPM inter-dependencies...
>> ########################################
>> RPM package conflict error.  The message was:
>> Test install failed because of package conflicts:
>> The following packages were added to your selection to satisfy
>> dependencies:
>> Name                                    Version        Release
>> --------------------------------------------------------------
>> mysql                                   3.23.58        15.RHEL3.1
>>
>> file /usr/bin/comp_err from install of mysql-3.23.58-15.RHEL3.1
>> conflicts with file from package MySQL-devel-4.1.11-0
>> file /usr/bin/mysql_config from install of mysql-3.23.58-15.RHEL3.1
>> conflicts with file from package MySQL-devel-4.1.11-0
>>
>> ---------------------------------------------------------------------------------------------
>>
>> As you can see, it can not understand that mysql is already installed
>> (but not under the package name "mysql", but "MySQL-client")
>> It tries to install mysql, but as we can expect the packages conflict.
>>
>> So, what is the solution ? How can I find a perl-DBD-MySQL rpm package
>> compatible with my version of MySQL (4.1) ?
>> I also tried to install the module from CPAN, without success : perl -
>> MCPAN -e 'install DBD::mysql', without success (still have errors),
>> and I really want to install it from RPM since I need it as a
>> dependency for another package...
>>
>> Any help greatly appreciated !
>>
>> Regards,
>> Ben
>> _______________________________________________
>> rhn-users mailing list
>> rhn-users at redhat.com
>> https://www.redhat.com/mailman/listinfo/rhn-users
> -- 
> =======================
> Daniel Wittenberg
> RHCE
> President/CTO
> The Starken Group Ltd.
> http://www.starken.com
>
> _______________________________________________
> rhn-users mailing list
> rhn-users at redhat.com
> https://www.redhat.com/mailman/listinfo/rhn-users 





More information about the rhn-users mailing list