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

Re: Bug#615507: elfutils: FTBFS on kfreebsd-*: FAIL: run-native-test.sh + dwfl-bug-fd-leak



tags 615507 + patch
thanks

Hi,

Unless I am mistaken, the test suite does not add
«PKGBUILDDIR»/backends/ to LD_LIBRARY_PATH.  So when tests/allregs tries
to dlopen the appropriate backend, it will fail:

> #0  __dlopen (file=file@entry=0x7fffffffe780 "$ORIGIN/../$LIB/elfutils/libebl_x86_64.so", mode=mode@entry=1) at dlopen.c:75
> #1  0x0000000800853cb2 in openbackend (elf=elf@entry=0x603410, emulation=emulation@entry=0x0, machine=<optimized out>)
> #2  0x0000000800853f05 in ebl_openbackend (elf=0x603410) at eblopenbackend.c:411

>  40271 allregs  NAMI  "/usr/lib/libebl_x86_64.so"
>  40271 allregs  RET   open -1 errno 2 No such file or directory

leading to:

> allregs: dwfl_module_register_names: no backend registers known

Whereas if «PKGBUILDDIR»/backends/ is added to LD_LIBRARY_PATH, I now get:

> allregs: cannot attach to process: Function not implemented

which seems expected - this is the original bug #570805, which is a
known difference with kFreeBSD's linprocfs in vs. Linux, when in a chroot.

Patch attached!

Thanks,
Regards,
-- 
Steven Chamberlain
steven@pyro.eu.org
--- tests/test-wrapper.sh.orig
+++ tests/test-wrapper.sh
@@ -52,7 +52,7 @@
     echo >&2 installcheck not possible with --enable-tests-rpath
     exit 77
   elif [ "x$libdir" != x/usr/lib ] && [ "x$libdir" != x/usr/lib64 ]; then
-    LD_LIBRARY_PATH="${libdir}:${libdir}/elfutils$old_path"
+    LD_LIBRARY_PATH="${libdir}:${libdir}/elfutils:${libdir}/backends$old_path"
   fi
   export LD_LIBRARY_PATH
   ;;

Reply to: