You are not logged in.

#1 2023-08-19 16:44:28

andr3as
Member
Registered: 2008-10-06
Posts: 53

namcap shows library as uninstalled dependency (packaging GstShark)

Hi all,

I'm trying to package GstShark and submit it to the AUR. The following PKGBUILD seems to build and install fine (even when following the build process in a clean chroot):

pkgname=gst-shark
pkgver=0.8.1
pkgrel=1
pkgdesc="A collection of GStreamer debugging tools"
arch=(x86_64)
url="https://developer.ridgerun.com/wiki/index.php?title=GstShark"
url="https://github.com/RidgeRun/${pkgname}"
license=('LGPL')
groups=()
depends=('glib2' 'gstreamer' 'glibc' 'graphviz')
makedepends=('meson')
provides=('libgstshark.so=0-64')
conflicts=()
replaces=()
backup=()
options=()
install=
source=("https://github.com/RidgeRun/${pkgname}/archive/refs/tags/v${pkgver}.tar.gz")
noextract=()
sha256sums=('d6fdfca8523412a30ce1a942ddabcbaede440623b69c9bb480a1006f4a28a112')

build() {
	cd "$srcdir/${pkgname}-${pkgver}"
	meson builddir --prefix /usr/
	ninja -C builddir
}

package() {
	cd "$srcdir/${pkgname}-${pkgver}"
	DESTDIR="$pkgdir/" ninja install -C builddir
}

However, when I try to check the package with namcap, I keep getting this warning (the full output of namcap -i is at the end of the post):

$ namcap -i gst-shark-0.8.1-1-x86_64.pkg.tar.zst
gst-shark W: Referenced library 'libgstshark.so.0' is an uninstalled dependency (needed in files ['usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])

But I can see that library in /usr/lib/ when unpack the package so it is actually installed with the package, not a dependency. (As you can see, I already tried listing that library in the provides list - with an empty provides=(), I get the same namcap output.)
I can't figure out what is wrong with the PKGBUILD - has anybody got any idea what might be missing/wrong here? Or even encountered a similar problem?


P.S.: this is the namcap output with more info:

$ namcap -i gst-shark-0.8.1-1-x86_64.pkg.tar.zst
gst-shark W: Referenced library 'libgstshark.so.0' is an uninstalled dependency (needed in files ['usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Soname 'libc.so=6-64' is not specified as provides by glibc yet (needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Soname 'libcgraph.so=6-64' is not specified as provides by graphviz yet (needed in files ['usr/lib/libgstshark.so.0.8.1'])
gst-shark I: Soname 'libgvc.so=6-64' is not specified as provides by graphviz yet (needed in files ['usr/lib/libgstshark.so.0.8.1'])
gst-shark I: Soname 'libgstreamer-1.0.so=0-64' is not specified as provides by gstreamer yet (needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Link-level dependence (glib2) in file ['usr/lib/libglib-2.0.so.0', 'usr/lib/libgobject-2.0.so.0', 'usr/lib/libgio-2.0.so.0']
gst-shark I: Link-level dependence (glibc) in file ['usr/lib/libc.so.6']
gst-shark I: Link-level dependence (graphviz) in file ['usr/lib/libgvc.so.6', 'usr/lib/libcgraph.so.6']
gst-shark I: Link-level dependence (gstreamer) in file ['usr/lib/libgstreamer-1.0.so.0']
gst-shark I: Soname dependency 'libgio-2.0.so=0-64' provided by glib2 detected and not included (needed in files ['usr/lib/libgstshark.so.0.8.1'])
gst-shark I: Soname dependency 'libglib-2.0.so=0-64' provided by glib2 detected and not included (needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Soname dependency 'libgobject-2.0.so=0-64' provided by glib2 detected and not included (needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Soname depends as namcap sees them: depends=(glibc graphviz gstreamer libgio-2.0.so=0-64 libglib-2.0.so=0-64 libgobject-2.0.so=0-64)
gst-shark I: Provided library 'libgstshark.so=0-64' is specified (provided by file ['usr/lib/libgstshark.so.0.8.1'])
gst-shark I: Provides as namcap sees them: provides=(libgstshark.so=0-64)
gst-shark I: Symlink (usr/lib/gstreamer-1.0/libgstsharktracers.so) found that points to libgstsharktracers.so.0
gst-shark I: Symlink (usr/lib/gstreamer-1.0/libgstsharktracers.so.0) found that points to libgstsharktracers.so.0.8.1
gst-shark I: Symlink (usr/lib/libgstshark.so) found that points to libgstshark.so.0
gst-shark I: Symlink (usr/lib/libgstshark.so.0) found that points to libgstshark.so.0.8.1
gst-shark I: Dependency glibc detected and satisfied (libraries ['usr/lib/libc.so.6'] needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Dependency graphviz detected and satisfied (libraries ['usr/lib/libgvc.so.6', 'usr/lib/libcgraph.so.6'] needed in files ['usr/lib/libgstshark.so.0.8.1'])
gst-shark I: Dependency glib2 detected and satisfied (libraries ['usr/lib/libglib-2.0.so.0', 'usr/lib/libgobject-2.0.so.0', 'usr/lib/libgio-2.0.so.0'] needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Dependency gstreamer detected and satisfied (libraries ['usr/lib/libgstreamer-1.0.so.0'] needed in files ['usr/lib/libgstshark.so.0.8.1', 'usr/lib/gstreamer-1.0/libgstsharktracers.so.0.8.1'])
gst-shark I: Depends as namcap sees them: depends=(glibc graphviz glib2 gstreamer)

Offline

#2 2023-08-19 16:50:49

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,197

Re: namcap shows library as uninstalled dependency (packaging GstShark)

The package needs to be installed for namcap to figure out where the file comes from.

Online

#3 2023-08-19 17:07:35

andr3as
Member
Registered: 2008-10-06
Posts: 53

Re: namcap shows library as uninstalled dependency (packaging GstShark)

Ah, I previously read that advice somewhere but wondered whether it was actually good advice. I remember using namcap to actually check packages before installing them, so that sounded kind of strange to me - but if that warning can safely be ignored, I think I'll submit that package in the next hours/days :-)

Thank you very much!

Offline

#4 2023-08-19 17:25:01

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: namcap shows library as uninstalled dependency (packaging GstShark)

Namcap is useful, but far from perfect*.  Absolutely nothing it tells you should be blindly accepted.  Clearly the current warning is not a problem - so don't worry about it.

You can, however, get rid of all the empty variables in the PGKBUILD.

*EDIT: that's not a criticism: it's not intended to be perfect.  It's intended to scan for things that might be a problem that you as a competent person should double check.  And you've done just that: you double checked that warning and found the libary is included in the package.  All done.

Last edited by Trilby (2023-08-19 17:26:21)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

Board footer

Powered by FluxBB