Bug 283925 - emulators/linux_base-rl9: missing libraries for many executables
Summary: emulators/linux_base-rl9: missing libraries for many executables
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Dima Panov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-01-08 13:14 UTC by Michael Osipov
Modified: 2025-05-11 17:03 UTC (History)
5 users (show)

See Also:
bugzilla: maintainer-feedback? (emulation)


Attachments
Add libnsl to linux_base-rl9 (2.94 KB, patch)
2025-05-04 01:18 UTC, Sean Farley
no flags Details | Diff
Add libnsl to linux_base-rl9 (4.72 KB, patch)
2025-05-04 18:04 UTC, Sean Farley
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Osipov freebsd_committer freebsd_triage 2025-01-08 13:14:24 UTC
I am trying to migrate off linux_base-c7 and my closed source commercial application gives me after migration that libsigsegv.so.2 cannot be found.

I did a bit of digging and several other libs cannot be found. The following libs are required by Linux executables:
> root@deblndw011x:/compat/linux
> # ldd bin/* sbin/* 2> /dev/null | cut -d = -f 1 | grep \\.so | sort -u | cut -w -f 2
> ld-linux-x86-64.so.2
> libacl.so.1
> libattr.so.1
> libblkid.so.1
> libbz2.so.1
> libc.so.6
> libc.so.7
> libcap.so.2
> libcom_err.so.2
> libcrypt.so.2
> libcrypto.so.3
> libe2p.so.2
> libext2fs.so.2
> libfdisk.so.1
> libffi.so.8
> libfuse.so.2
> libgio-2.0.so.0
> libglib-2.0.so.0
> libgmodule-2.0.so.0
> libgmp.so.10
> libgobject-2.0.so.0
> libiconv.so.2
> libintl.so.8
> libkeyutils.so.1
> libm.so.6
> libmount.so.1
> libmpfr.so.6
> libncursesw.so.6
> libncursesw.so.9
> libpcre.so.1
> libpcre2-8.so.0
> libreadline.so.8
> libresolv.so.2
> libselinux.so.1
> libsigsegv.so.2
> libsmartcols.so.1
> libthr.so.3
> libtic.so.6
> libtinfo.so.6
> libutil.so.9
> libuuid.so.1
> libz.so.1
> libz.so.6

but only these are available:
> root@deblndw011x:/compat/linux
> # ldd bin/* sbin/* 2> /dev/null | cut -d = -f 1 | grep \\.so | sort -u | cut -w -f 2 | xargs -I% find usr/lib64  -name %  | sort
> usr/lib64/ld-linux-x86-64.so.2
> usr/lib64/libacl.so.1
> usr/lib64/libattr.so.1
> usr/lib64/libblkid.so.1
> usr/lib64/libbz2.so.1
> usr/lib64/libc.so.6
> usr/lib64/libcap.so.2
> usr/lib64/libcom_err.so.2
> usr/lib64/libcrypto.so.3
> usr/lib64/libe2p.so.2
> usr/lib64/libext2fs.so.2
> usr/lib64/libffi.so.8
> usr/lib64/libgio-2.0.so.0
> usr/lib64/libglib-2.0.so.0
> usr/lib64/libgmodule-2.0.so.0
> usr/lib64/libgmp.so.10
> usr/lib64/libgobject-2.0.so.0
> usr/lib64/libkeyutils.so.1
> usr/lib64/libm.so.6
> usr/lib64/libmount.so.1
> usr/lib64/libncursesw.so.6
> usr/lib64/libpcre.so.1
> usr/lib64/libpcre2-8.so.0
> usr/lib64/libreadline.so.8
> usr/lib64/libresolv.so.2
> usr/lib64/libselinux.so.1
> usr/lib64/libtic.so.6
> usr/lib64/libtinfo.so.6
> usr/lib64/libuuid.so.1
> usr/lib64/libz.so.1

These are missing:
> ld-linux-x86-64.so.2
> libc.so.7
> libcrypt.so.2
> libfdisk.so.1
> libfuse.so.2
> libiconv.so.2
> libintl.so.8
> libmpfr.so.6
> libncursesw.so.9
> libsigsegv.so.2
> libsmartcols.so.1
> libthr.so.3
> libutil.so.9
> libz.so.6

Sample failure:
> root@deblndw011x:/compat/linux
> # bin/awk
> bin/awk: error while loading shared libraries: libsigsegv.so.2: cannot open shared object file: No such file or directory

On a RHEL8 system:
> root@deblndw012x:~
> # rpm -qf /lib64/libsigsegv.so.2
> libsigsegv-2.11-5.el8.x86_64

I believe that all of these needs to added to the base system as well.
Comment 1 Michael Osipov freebsd_committer freebsd_triage 2025-01-08 13:14:46 UTC
I will revert to linux_base-c7 for now.
Comment 2 Michael Osipov freebsd_committer freebsd_triage 2025-01-08 13:17:32 UTC
Dima, can you have a look when you have some spare cycles?
Comment 3 Tomasz "CeDeROM" CEDRO 2025-01-08 13:26:22 UTC
Also the SDL* on RL9 please, it is available for C7 :-)
Comment 4 Michael Osipov freebsd_committer freebsd_triage 2025-01-08 13:27:26 UTC
(In reply to Tomasz "CeDeROM" CEDRO from comment #3)

This should a separate bug report, no?
Comment 5 Tomasz "CeDeROM" CEDRO 2025-01-08 13:31:39 UTC
(In reply to Michael Osipov from comment #4)

Done :-) Thanks :-) https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=283926
Comment 6 Dima Panov freebsd_committer freebsd_triage 2025-01-11 17:03:05 UTC
(In reply to Michael Osipov from comment #2)
Yep. I'll dig into asap
Comment 7 Dima Panov freebsd_committer freebsd_triage 2025-01-11 20:05:46 UTC
BTM, Michael, u've missed some separated packages (and please omit so.X version in comparison, it is sometimes distro-depended)


libfuse.so and half other listed libs are installed by linux_base-rl9 and I wonder why you not have it (may be very outdated ports tree?)

libmpfr.so.6 was installed by package linux-rl9-devtools-9.5
libfuse.so.2.9.9 was installed by package linux_base-rl9-9.5
libfdisk.so.1.1.0 was installed by package linux_base-rl9-9.5
libsmartcols.so.1 was installed by package linux_base-rl9-9.5
libutil.so.1 was installed by package linux_base-rl9-9.5
libz.so.1 was installed by package linux_base-rl9-9.5
libcrypt.so.2 was installed by package linux-rl9-libxcrypt-4.4.18_1


Please install linux-rl9 metapackage to get a full set of libraries
Comment 8 Michael Osipov freebsd_committer freebsd_triage 2025-01-12 21:34:05 UTC
(In reply to Dima Panov from comment #7)

Let me investigate the incomplete state first.
Comment 9 Michael Osipov freebsd_committer freebsd_triage 2025-01-12 22:07:59 UTC
(In reply to Dima Panov from comment #7)

Right, I had an issue in my tree and update my poudriere repo, have the latest and greatest now, but of course some are missing.
I am a bit hesitant to install the meta package because it contains much more than I need to the commercial crap. Moreover, I'd expect linux_base to be selfcontained, e.g. libsigsegv
Comment 10 Michael Osipov freebsd_committer freebsd_triage 2025-02-10 10:08:44 UTC
(In reply to Dima Panov from comment #6)

Where you able to find some time for this?
Comment 11 Gleb Popov freebsd_committer freebsd_triage 2025-04-09 11:18:23 UTC
(In reply to Michael Osipov from comment #10)
Since you figured that you had a mistake on your side, let's first start with getting a 100% correct list of libraries you require. We can then proceed with adding them into Ports.

Also note that if you're using some Linux applications it might have sense to add them to our Ports tree too, so that other committers would be aware of them and take them into account when updating Linuxulator base.
Comment 12 Michael Osipov freebsd_committer freebsd_triage 2025-04-09 11:20:57 UTC
(In reply to Gleb Popov from comment #11)

Yes, let's double check the list.

I can't repackage a commercial application: OpenText Data Protector client https://docs.microfocus.com/doc/200/23.4/installdpclients
Comment 13 Michael Osipov freebsd_committer freebsd_triage 2025-04-17 18:10:43 UTC
Ran the analysis again, we are now down to:
libcrypt.so.2 => libxcrypt-devel-4.1.1-6.el8.x86_64
libmpfr.so.6 => mpfr-3.1.6-1.el8.x86_64

At least security/linux-rl9-libxcrypt needs to be folded into the base package just like in 6f110064b71c.
Comment 14 Gleb Popov freebsd_committer freebsd_triage 2025-04-21 08:54:38 UTC
mpfr is now a part of base.
Comment 15 Michael Osipov freebsd_committer freebsd_triage 2025-04-22 06:37:15 UTC
(In reply to Gleb Popov from comment #14)

Just tried, looks better. Only security/linux-rl9-libxcrypt needs to be folded into and I am fine with this issue.
Comment 16 Sean Farley freebsd_committer freebsd_triage 2025-05-04 01:18:43 UTC
Created attachment 260135 [details]
Add libnsl to linux_base-rl9

I would like libnsl to be added to linux_base-rl9, as it was in linux_base-c7, to support games/linux-ut although it needs more work on my part.
Comment 17 Gleb Popov freebsd_committer freebsd_triage 2025-05-04 12:09:32 UTC
(In reply to Sean Farley from comment #16)
Plist changes are lacking some files:

Error: Orphaned: usr/lib/.build-id/83/13151839f218d1aaaf5914591a7229202c1970
Error: Orphaned: usr/lib/.build-id/c4/f9a96f410f85fdc7c10775afc2e35d2c0a9808
===> Checking for items in pkg-plist which are not in STAGEDIR
===> Error: Plist issues found.

The aarch64 plist is probably wrong too.
Comment 18 Sean Farley freebsd_committer freebsd_triage 2025-05-04 18:04:20 UTC
Created attachment 260154 [details]
Add libnsl to linux_base-rl9

(In reply to Gleb Popov from comment #17)
Thank you for catching that.  Fixed in newer attachment.  I also removed an extra empty line in Makefile to appease portlint.
Comment 19 commit-hook freebsd_committer freebsd_triage 2025-05-05 08:04:27 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8a0f47a8ffbb5cd1567b36b3d651a92a5df3318b

commit 8a0f47a8ffbb5cd1567b36b3d651a92a5df3318b
Author:     Sean Farley <scf@FreeBSD.org>
AuthorDate: 2025-05-05 07:55:02 +0000
Commit:     Gleb Popov <arrowd@FreeBSD.org>
CommitDate: 2025-05-05 08:03:15 +0000

    emulators/linux_base-rl9: Add libnsl

    PR:             283925

 emulators/linux_base-rl9/Makefile          | 4 ++--
 emulators/linux_base-rl9/distinfo          | 6 ++++++
 emulators/linux_base-rl9/pkg-plist.aarch64 | 2 ++
 emulators/linux_base-rl9/pkg-plist.amd64   | 4 ++++
 4 files changed, 14 insertions(+), 2 deletions(-)
Comment 20 Michael Osipov freebsd_committer freebsd_triage 2025-05-05 10:15:13 UTC
Gleb, what about security/linux-rl9-libxcrypt?
Comment 21 Gleb Popov freebsd_committer freebsd_triage 2025-05-05 10:22:02 UTC
(In reply to Michael Osipov from comment #20)
Yes, I'm still planning to do it, I'm just too swamped with other stuff.

I guess I can increase this task's priority, if you need the fix ASAP.
Comment 22 Michael Osipov freebsd_committer freebsd_triage 2025-05-05 10:23:05 UTC
(In reply to Gleb Popov from comment #21)

ASAP isn't required, but it shouldn't be forgotten and should land before next quarterly. Thanks!
Comment 23 commit-hook freebsd_committer freebsd_triage 2025-05-06 07:34:01 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=59076660e36fe4acbf9b3e207da61ebdfd426b32

commit 59076660e36fe4acbf9b3e207da61ebdfd426b32
Author:     Dima Panov <fluffy@FreeBSD.org>
AuthorDate: 2025-05-06 07:32:14 +0000
Commit:     Dima Panov <fluffy@FreeBSD.org>
CommitDate: 2025-05-06 07:33:14 +0000

    security/linux-rl9-libxcrypt: integrate into linux_base-rl9

    PR:     283925

 MOVED                                              |  1 +
 Mk/Uses/linux.mk                                   |  1 -
 security/Makefile                                  |  1 -
 security/linux-rl9-libxcrypt/Makefile (gone)       | 24 ----------------------
 security/linux-rl9-libxcrypt/distinfo (gone)       |  9 --------
 .../linux-rl9-libxcrypt/pkg-plist.aarch64 (gone)   | 13 ------------
 .../linux-rl9-libxcrypt/pkg-plist.amd64 (gone)     | 18 ----------------
 7 files changed, 1 insertion(+), 66 deletions(-)
Comment 24 commit-hook freebsd_committer freebsd_triage 2025-05-06 07:34:02 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=82a46c96580e8c58289ae6862acedaa3f5e58340

commit 82a46c96580e8c58289ae6862acedaa3f5e58340
Author:     Dima Panov <fluffy@FreeBSD.org>
AuthorDate: 2025-05-06 07:22:58 +0000
Commit:     Dima Panov <fluffy@FreeBSD.org>
CommitDate: 2025-05-06 07:33:14 +0000

    emulators/linux_base-rl9: integrate security/linux-rl9/libxcrypt (+)

    While here, track upstream reroll for glibc/libnsl (2.34-125.el9_5.3 => 2.34-125.el9_5.8)

    PR:     283925

 emulators/linux_base-rl9/Makefile          |    4 +-
 emulators/linux_base-rl9/Makefile.version  |    3 +-
 emulators/linux_base-rl9/distinfo          |   66 +-
 emulators/linux_base-rl9/pkg-plist.aarch64 |  589 +++++++-------
 emulators/linux_base-rl9/pkg-plist.amd64   | 1158 ++++++++++++++--------------
 5 files changed, 931 insertions(+), 889 deletions(-)
Comment 25 Michael Osipov freebsd_committer freebsd_triage 2025-05-06 09:41:25 UTC
From my PoV the request has been satisfied. No linker errors. I will test in our setup next week.
Comment 26 Michael Osipov freebsd_committer freebsd_triage 2025-05-07 07:26:49 UTC
I am about to puke, it turns out that:
perl:
...
        libcrypt.so.1 => not found (0)
...
This perl is bundled with Data Protector and according to docs it does NOT support RL9 what a joke, only RL9. I need to inquire with the vendor when they plan that. I could install https://rockylinux.pkgs.org/9/rockylinux-appstream-x86_64/libxcrypt-compat-4.4.18-3.el9.x86_64.rpm.html, but hell knows whether it will work or not. Commercial crap. From my PoV you can close this ticket.
Comment 27 Mark Linimon freebsd_committer freebsd_triage 2025-05-11 10:52:12 UTC
(In reply to Michael Osipov from comment #26)
fwiw, one of those "RL9" strings is probably wrong :-)
Comment 28 Michael Osipov freebsd_committer freebsd_triage 2025-05-11 17:03:26 UTC
(In reply to Mark Linimon from comment #27)

Which?

I first need dive into 
+linux: jid 0 pid 22188 (ld-linux.so.2): syscall arch_prctl not implemented
+pid 22189 (ld-linux-x86-64.so.), jid 0, uid 0: exited on signal 10 (core dumped)