ftbfs in artful due to DT_RPATH/DT_RUNPATH fun and games

Bug #1700696 reported by Michael Hudson-Doyle
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
elektra (Ubuntu)
New
Undecided
Unassigned

Bug Description

elektra fails to build in artful with tests failing like this:

Traceback (most recent call last):
  File "/<<PKGBUILDDIR>>/src/bindings/swig/python/tests/test_kdb.py", line 61, in tearDownClass
    with kdb.KDB() as db:
  File "/<<PKGBUILDDIR>>/obj-x86_64-linux-gnu/src/bindings/swig/python/kdb.py", line 1571, in __init__
    _kdb.KDB_swiginit(self, _kdb.new_KDB(*args))
kdb.KDBException: 1 Warning was issued:
 Warning number: 1
 Description: could not load module, dlopen failed
 Ingroup: modules
 Module: dl
 At: /<<PKGBUILDDIR>>/src/libloader/dl.c:80
 Reason: of module: libelektra-resolver.so, because: libelektra-resolver.so: cannot open shared object file: No such file or directory
 Mountpoint:
 Configfile:
Error (#40) occurred!
Description: Failed to open default backend (see warnings for more information)
Ingroup: kdb
Module:
At: /<<PKGBUILDDIR>>/src/libelektra/kdb.c:204
Reason: could not open default backend
Mountpoint:
Configfile:

After some digging, it turns out that this is because the _kdb.so python extension module has a DT_RUNPATH pointing at the directory containing libelektra-resolver.so, not DT_RPATH (which would work, see http://blog.qt.io/blog/2011/10/28/rpath-and-runpath/).

Nothing in the packaging afaict has an opinion on rpath vs runpath so this is probably down to some change in some other package.

That said, using -rpath to make tests pass when linking files that get installed to locations on the default so search path smells a bit. Maybe it would be better to set LD_LIBRARY_PATH when running the tests?

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Oh sigh debian has already been through this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=846200

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.