Public bug reported: Having libFilter.so built with --filter=libFiltee.so. Running prog-bug, which contains dlopen("libFilter.so"), you'll get "Inconsistency detected by ld.so: dl-deps.c: 553: _dl_map_object_deps: Assertion `map->l_searchlist.r_list[0] == map' failed!"
The issue is reproducible on Ubuntu 16.04, 18.04, 20.04, although the dl-deps.c line number may be different. The attached file contains full C source code, the binaries, and the build script. To reproduce: 1) Unzip and cd to the folder. 2) Define LD_LIBRARY_PATH $ export LD_LIBRARY_PATH=. 3) Run correct executable prog-ok, not having dlopen call, behaves as expected. $ prog-ok 4) Run prog-bug, which demonstrates the issue, having dlopen, and produces the above error. $ prog-bug Optionally you may rebuild the binaries, using _build.sh script. The same error appears running: $ ldd libFilter.so I am using Ubuntu 18.04.6 LTS with libc6 v2.27-3ubuntu1.4. ProblemType: Bug DistroRelease: Ubuntu 18.04 Package: libc6 2.27-3ubuntu1.4 ProcVersionSignature: Ubuntu 4.15.0-162.170-generic 4.15.18 Uname: Linux 4.15.0-162-generic x86_64 NonfreeKernelModules: wl ApportVersion: 2.20.9-0ubuntu7.27 Architecture: amd64 CurrentDesktop: ubuntu:GNOME Date: Tue Nov 30 17:52:07 2021 Dependencies: gcc-11-base 11.1.0-1ubuntu1~18.04.1 [origin: LP-PPA-ubuntu-toolchain-r-test] libc6 2.27-3ubuntu1.4 libgcc-s1 11.1.0-1ubuntu1~18.04.1 [origin: LP-PPA-ubuntu-toolchain-r-test] libgcc1 1:11.1.0-1ubuntu1~18.04.1 [origin: LP-PPA-ubuntu-toolchain-r-test] InstallationDate: Installed on 2020-05-03 (576 days ago) InstallationMedia: Ubuntu 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725) SourcePackage: glibc UpgradeStatus: No upgrade log present (probably fresh install) ** Affects: glibc (Ubuntu) Importance: Undecided Status: New ** Tags: amd64 apport-bug bionic dlopen libc6 third-party-packages ** Attachment added: "C source, build script, executables" https://bugs.launchpad.net/bugs/1952814/+attachment/5544448/+files/ld_--filter_option.zip -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1952814 Title: Inconsistency detected by ld.so: dl-deps.c when dlopen .so, built with --filter option To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1952814/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs