Subject: pkg/15574: p5-DBD-mysql-1.2215 doesn't link correctly
To: None <>
From: None <>
List: netbsd-bugs
Date: 02/10/2002 20:01:41
>Number:         15574
>Category:       pkg
>Synopsis:       p5-DBD-mysql-1.2215 doesn't link correctly
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Feb 10 11:02:00 PST 2002
>Originator:     Bernd Ernesti
>Release:        NetBSD 1.5ZA
System: NetBSD 1.5ZA NetBSD 1.5ZA (ARRESUM) #644: Sat Feb 2 11:47:23 CET 2002 i386
Architecture: i386
Machine: i386
	The library run path for libmysqlclien isn't stored in the library.

# ldd /usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/DBD/mysql/
         -lperl => /usr/pkg/lib/perl5/5.6.1/i386-netbsd/CORE/
         -lmysqlclient.10 => not found
         -lm.0 => /usr/lib/
         -lm.0 => /usr/lib/
         -lz.0 => /usr/lib/

From the build output:

LD_RUN_PATH="/usr/pkg/lib/mysql:/usr/lib" cc  --whole-archive -shared  -Wl,-R/usr/pkg/lib -L/usr/pkg/lib dbdimp.o  mysql.o -L/usr/pkg/lib/mysql -o ../blib/arch/auto/DBD/mysql/   -L/usr/pkg/lib/perl5/5.6.1/i386-netbsd/CORE -Wl,-R/usr/pkg/lib/perl5/5.6.1/i386-netbsd/CORE -lperl -L/usr/pkg/lib/mysql -lmysqlclient -lm -lz  

There is no -Wl,-R/usr/pkg/lib/mysql option.

Adding it manualy to Msql-Mysql-modules-1.2215/mysql/Makefile fixed my problem.

But I think this is a generic perl module problem.

	Try to use mysql in an perl html script and notice the error messages in your
Can't load '/usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/auto/DBD/mysql/' for module DBD::mysql: Shared object "" not found at /usr/pkg/lib/perl5/5.6.1/i386-netbsd/ line 206.
 at /usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/ line 13
Compilation failed in require at /usr/pkg/lib/perl5/site_perl/5.6.1/i386-netbsd/ line 13.

	Fix the perl package to add this automatically.