Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: gcc-4.5.3 has broken most of pkgsrc for me



On Fri, Aug 19, 2011 at 04:55:42PM +0100, Patrick Welche wrote:
> On Fri, Aug 19, 2011 at 04:53:44PM +0100, Patrick Welche wrote:
> > I just saw the perl error - it is odd:
> > 
> > gcc -c  -I/usr/local/BerkeleyDB/include  -O2 -pthread -I/usr/include 
> > -fno-strict-aliasing -pipe -fstack-protector -I/usr/pkg/include 
> > -I/usr/local/include -O2 -pthread -I/usr/include    -DVERSION=\"1.821\"  
> > -DXS_VERSION=\"1.821\" -DPIC -fPIC "-I../.."  -D_NOT_CORE  
> > -DmDB_Prefix_t=size_t -DmDB_Hash_t=u_int32_t DB_File.c
> > Running Mkbootstrap for DB_File ()
> > chmod 644 DB_File.bs
> > rm -f ../../lib/auto/DB_File/DB_File.so
> > LD_RUN_PATH="/usr/local/lib" gcc  -Wl,-R/usr/pkg/lib --whole-archive 
> > -shared  -L/usr/local/lib -L/usr/pkg/lib -fstack-protector version.o 
> > DB_File.o  -o ../../lib/auto/DB_File/DB_File.so         -ldb -L../.. 
> > -Wl,-R/usr/pkg/lib/perl5/5.14.0/i386-netbsd-thread-multi/CORE 
> > -Wl,-R../../lib/CORE -lperl         
> > ld: cannot find -ldb
> > 
> > I made sure to remove /usr/local/bin from my PATH. I wonder where the
> > LD_RUN_PATH comes from and if it is related...
> 
> Or if some test thinks that libdb is needed when libc would suffice...

Solution:

On a working pkgsrc-only box, building perl gives

Running Makefile.PL in cpan/DB_File
../../miniperl -I../../lib Makefile.PL INSTALLDIRS=perl INSTALLMAN1DIR=none INST
ALLMAN3DIR=none PERL_CORE=1 LIBPERL_A=libperl.so LINKTYPE=dynamic
Parsing config.in...
Looks Good.
Note (probably harmless): No library found for -ldb

On the above problem box, /usr/local/lib/libdb.so is found, so the
"probably harmless" message doesn't appear. Moving /usr/local/lib/libdb*
away allowed perl5 to build.

Odd that the -L/usr/local/lib above didn't find it. Not sure how to tell
pkgsrc perl to only in look in /usr/pkg...


Cheers,

Patrick


Home | Main Index | Thread Index | Old Index