Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 20 Dec 2015 00:07:54 +1100
From:      Dewayne Geraghty <dewaynegeraghty@gmail.com>
To:        ports-list freebsd <freebsd-ports@freebsd.org>
Subject:   pkg info -B not listing all shared libraries
Message-ID:  <CAGnMC6o_6__hLkiaCsE7ZP=g9YRN%2BBpPJ2EStvv09Q9qFn4r-g@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Does "pkg info -B $pkg_name" only list the shared packages from the first
level of supporting "ports", or is it supposed to be all shared (ports')
libraries that are used?

While reviewing the composition of packages, I noticed that not all shared
libraries which are used, appear in the output from "pkg info -B $pkg_name".

Lets use curl as an example.  The library /usr/local/lib/libintl.so.8 is
missing from
# pkg info -B curl-7.45.0
curl-7.45.0:
        libheimntlm.so.0
        libssh2.so.1
        libcrypto.so.8
        libheimbase.so.1
        libkrb5.so.26
        libhx509.so.5
        libasn1.so.8
        libgssapi.so.3
        libcom_err.so.1
        libroken.so.18
        libssl.so.8
        libwind.so.0

However
# ldd `which curl`
/usr/local/bin/curl:
        libcurl.so.4 => /usr/local/lib/libcurl.so.4 (0x800848000)
        libssl.so.8 => /usr/local/lib/libssl.so.8 (0x800ab9000)
        libcrypto.so.8 => /usr/local/lib/libcrypto.so.8 (0x800d25000)
        libz.so.6 => /lib/libz.so.6 (0x801139000)
        libkrb5.so.26 => /usr/local/lib/heimdal/libkrb5.so.26 (0x80134f000)
        libgssapi.so.3 => /usr/local/lib/heimdal/libgssapi.so.3
(0x8015ca000)
        libthr.so.3 => /lib/libthr.so.3 (0x801803000)
        libc.so.7 => /lib/libc.so.7 (0x801a28000)
        libssh2.so.1 => /usr/local/lib/libssh2.so.1 (0x801dcc000)
        libheimntlm.so.0 => /usr/local/lib/heimdal/libheimntlm.so.0
(0x801ff4000)
        libhx509.so.5 => /usr/local/lib/heimdal/libhx509.so.5 (0x8021fa000)
        libcom_err.so.1 => /usr/local/lib/heimdal/libcom_err.so.1
(0x802443000)
        libasn1.so.8 => /usr/local/lib/heimdal/libasn1.so.8 (0x802646000)
        libwind.so.0 => /usr/local/lib/heimdal/libwind.so.0 (0x8028e4000)
        libheimbase.so.1 => /usr/local/lib/heimdal/libheimbase.so.1
(0x802b0c000)
        libroken.so.18 => /usr/local/lib/heimdal/libroken.so.18
(0x802d10000)
        libcrypt.so.5 => /lib/libcrypt.so.5 (0x802f21000)
        libintl.so.8 => /usr/local/lib/libintl.so.8 (0x803141000)

I appreciate that libintl.so.8 is part of the gettext-runtime, a second
tier of inclusion (by heimdal); however both the output from "pkg info -B"
and the documentation either (respectively) imply or state that "-B Display
all shared libraries used by pkg-name".

Perhaps this can be addressed in the documentation by adding "only shared
libraries from the first level of dependencies upon other ports  are
included", which also accommodates the missing system libraries (libz,
libcrypt, ...)?

[I came across this while looking for efficient ways to prune unnecessary
libraries from the system.]
Regards, Dewayne.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAGnMC6o_6__hLkiaCsE7ZP=g9YRN%2BBpPJ2EStvv09Q9qFn4r-g>