Bug 271686 - x11-servers/xorg-server: replace post-install symlink with libmap.d
Summary: x11-servers/xorg-server: replace post-install symlink with libmap.d
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Jan Beich
URL:
Keywords:
Depends on: 271629
Blocks:
  Show dependency treegraph
 
Reported: 2023-05-27 20:57 UTC by Jan Beich
Modified: 2023-08-12 23:03 UTC (History)
2 users (show)

See Also:


Attachments
v0 (apply via "git am") (7.56 KB, patch)
2023-05-27 20:57 UTC, Jan Beich
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Beich freebsd_committer freebsd_triage 2023-05-27 20:57:42 UTC
Created attachment 242453 [details]
v0 (apply via "git am")

libglx.so symlink (ports 04a589dee461) predates both libmap.d (base 4b00159792e4) and libglvnd (ports b44acc9409bd) support. When nvidia-driver switched to libmap.d (ports 50a34a07740e) it didn't convert libglx.so under invalid assumption libmap.conf(5) doesn't support dlopen(3) likely due to relative vs. absolute paths. Let's try again.

Disclaimer: I don't use xorg-server or nvidia-driver*, so runtime is untested.
Comment 1 Emmanuel Vadot freebsd_committer freebsd_triage 2023-05-28 07:04:26 UTC
@gallatin could you test this please ?
Comment 2 Andrew Gallatin freebsd_committer freebsd_triage 2023-05-31 17:53:07 UTC
(In reply to Emmanuel Vadot from comment #1)
Thank you for the fix.

I'm sorry, but I don't have a chance to test the fix in a timely manner.  Your approach of using libmap looks good.  Please commit it.
Comment 3 commit-hook freebsd_committer freebsd_triage 2023-08-12 22:59:55 UTC
A commit in branch main references this bug:

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

commit d1b7aad5f3cc475b86222599d0e9eb8d73b3c841
Author:     Jan Beich <jbeich@FreeBSD.org>
AuthorDate: 2023-05-27 20:44:33 +0000
Commit:     Jan Beich <jbeich@FreeBSD.org>
CommitDate: 2023-08-12 22:58:06 +0000

    x11-servers/xorg-server: complete libmap.d switch after 50a34a07740e

    libmap.conf(5) supports dlopen(3) but xorg-server uses absolute paths.

    PR:             271686
    Reviewed by:    gallatin

 x11-servers/xorg-server/Makefile                           |  9 +--------
 x11-servers/xorg-server/files/pkg-post-deinstall.in (gone) |  1 -
 x11-servers/xorg-server/files/pkg-post-install.in (gone)   | 11 -----------
 x11-servers/xorg-server/pkg-plist                          |  2 +-
 x11/nvidia-driver-304/Makefile                             |  2 +-
 x11/nvidia-driver-340/Makefile                             |  2 +-
 x11/nvidia-driver-390/Makefile                             |  2 +-
 x11/nvidia-driver/Makefile                                 |  3 ---
 x11/nvidia-driver/files/nvidia.conf.in                     |  2 ++
 x11/nvidia-driver/files/pkg-deinstall.in (gone)            | 12 ------------
 x11/nvidia-driver/files/pkg-install.in (gone)              | 10 ----------
 11 files changed, 7 insertions(+), 49 deletions(-)
Comment 4 Jan Beich freebsd_committer freebsd_triage 2023-08-12 23:03:41 UTC
Landed despite lack of testing as nvidia-driver < 410 was already broken (bug 271629). libmap.conf(5) is unused thus cannot regress nvidia-driver >= 410, nvidia-secondary-driver, mesa-dri.