Subject: Re: Omitting static libraries from installed packages
To: None <tech-pkg@netbsd.org>
From: Roland Illig <roland.illig@gmx.de>
List: tech-pkg
Date: 02/26/2005 01:54:51
Todd Vierling wrote:
> 
> The libtool configure bits are, more or less, garbage, as pkgsrc overrides
> the final libtool script.  Put the following in mk.conf, and you'll only get
> shared libs from libtool-aware packages.
> 
> PKG_LIBTOOL=	${PKG_SHLIBTOOL}

Thanks for the tip. It almost works.

With current pkgsrc/archivers/bzip2 on Solaris, I get this:

shlibtool  --mode=compile cc -O   -D_FILE_OFFSET_BITS=64 -c bzip2.c
  cc -O -D_FILE_OFFSET_BITS=64 -c bzip2.c  -KPIC -DPIC -o .libs/bzip2.o
shlibtool  --mode=link cc -O   -D_FILE_OFFSET_BITS=64 
-R/home/j2001/1illig/pkg/lib -static -o bzip2 bzip2.o libbz2.la
cc -O -D_FILE_OFFSET_BITS=64 -o bzip2 bzip2.o  ./.libs/libbz2.so 
-L/tmp/1illig/pkgsrc/archivers/bzip2/work.rzdspc8/.buildlink/lib 
-R/tmp/1illig/pkgsrc/archivers/bzip2/work.rzdspc8/bzip2-1.0.2/.libs 
-R/home/j2001/1illig/pkg/lib
ld: fatal: file bzip2.o: open failed: No such file or directory
ld: fatal: File processing errors. No output written to bzip2

When compiling, bzip2.o is stored in .libs/.
When linking, it is expected in the current directory.

Someone wants to fix that?

I also tried to install devel/pcre with shlibtool, and it worked fine. 
So maybe there's some Makefile issue here.

Roland