pkgsrc-Bugs archive

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

pkg/37828: pkg shared libs do not depend on

>Number:         37828
>Category:       pkg
>Synopsis:       pkg shared libs do not depend on
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jan 21 05:55:00 +0000 2008
>Originator:     David A. Holland
>Release:        current pkgsrc of 20080117
System: NetBSD tanaqui 4.99.31 NetBSD 4.99.31 (TANAQUI) #19: Tue Sep 11 
19:46:35 EDT 2007  dholland@tanaqui:/usr/src/sys/arch/i386/compile/TANAQUI i386
Architecture: i386
Machine: i386

Most (nearly all) shared libraries built from pkgsrc do not have an
explicit dependency (a DT_NEEDED entry, if I remember my elf
correctly) on libc.

This severely restricts our future options for maintaining binary
compatibility (arguably, more so than the same issue in base) and
should be rectified as soon as possible.


% ldd /usr/pkg/lib/
        -lpthread.0 => /usr/lib/
        -lgunicode.3 => /usr/pkg/lib/
        -lICE.6 => /usr/X11R6/lib/
        -lSM.6 => /usr/X11R6/lib/
        -lX11.6 => /usr/X11R6/lib/
        -lXext.6 => /usr/X11R6/lib/
        -lXi.6 => /usr/X11R6/lib/
        -lm.0 => /usr/lib/
        -lm.0 => /usr/lib/
        -lxkbfile.1 => /usr/X11R6/lib/
        -lxkbui.1 => /usr/X11R6/lib/
        -lgdraw.2 => /usr/pkg/lib/

for example.


Add -lc to the link when building shared libs. Arranging for libtool
to do this would probably cover most of the widely used cases. I have
no idea how that might be done though.

Another possible alternative is to adjust our gcc specs so all shared
libs not using -nostdlib get -lc. Not sure this is really a good idea

See also lib/37827.

Home | Main Index | Thread Index | Old Index