Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 950053 - x11-drivers/nvidia-drivers: should install binaries to /usr/bin
Summary: x11-drivers/nvidia-drivers: should install binaries to /usr/bin
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Ionen Wolkens
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-02-22 00:25 UTC by Xi
Modified: 2025-02-22 03:07 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Xi 2025-02-22 00:25:37 UTC
Currently, nvidia-drivers package install the binaries to /usr/bin and /opt/bin

```
~ % qlist x11-drivers/nvidia-drivers | grep '/bin/'
/opt/bin/nvidia-ngx-updater
/opt/bin/nvidia-cuda-mps-server
/opt/bin/nvidia-cuda-mps-control
/opt/bin/nvidia-debugdump
/opt/bin/nvidia-smi
/usr/bin/nvidia-bug-report.sh
/usr/bin/nvidia-sleep.sh
/usr/bin/nvidia-xconfig
/usr/bin/nvidia-settings
/usr/bin/nvidia-modprobe
```

Some applications can fail to find the binary.
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-02-22 00:28:19 UTC
Please always include any additional context (e.g. the forums thread, which applications are failing for you).

Anyway, https://forums.gentoo.org/viewtopic-t-1172995.html.
Comment 2 Ionen Wolkens gentoo-dev 2025-02-22 00:43:26 UTC
Honestly said applications should just use PATH, it is silly to expect them always in /usr/bin. On e.g. prefix (where can still want nvidia-drivers[-modules] for the userspace) it'd install nothing in /usr/bin even.

While the split is mostly historical (predates me maintaining nvidia-drivers), the split does have a meaning too. Aka /usr/bin is used for source-built binaries (or scripts), while /opt/bin is for prebuilts.

...but given we install prebuilt nvidia libraries in /usr/lib anyway it never meant all that much, and then /opt/bin is not used often in the first place (it's more typical to have /opt/<package>/bin or so with a symlink or wrapper in /usr/bin).

So, while not for the reason you're giving, I'm still inclined to get rid of the split. Will check soon'ish when I'm done with other things.
Comment 3 Ionen Wolkens gentoo-dev 2025-02-22 01:21:37 UTC
(In reply to Ionen Wolkens from comment #2)
> While the split is mostly historical (predates me maintaining
> nvidia-drivers), the split does have a meaning too. Aka /usr/bin is used for
> source-built binaries (or scripts), while /opt/bin is for prebuilts.
On that note, guess it is a bit more annoying for handling QA_PREBUILT="/opt/bin/*"
Comment 4 Larry the Git Cow gentoo-dev 2025-02-22 03:07:17 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3b0251c97c29f779556cd29b49b6ec6af56304fe

commit 3b0251c97c29f779556cd29b49b6ec6af56304fe
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2025-02-22 01:29:52 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2025-02-22 02:34:54 +0000

    x11-drivers/nvidia-drivers: migrate /opt/bin to /usr/bin
    
    Was meant to separate prebuilt and source-built binaries, but tend to
    only cause confusion and hasn't meant much when prebuilt libraries are
    in /usr/lib anyway.
    
    May possibly affect some users that were using /opt/bin rather than
    PATH after being like that for so long, but believe there is likely
    too few to be worth a warning.
    
    Not worth a revbump, will take effect next rebuild which happen every
    kernel upgrades.
    
    wrt QA_PREBUILT, ideally would construct it from the .manifest inside
    src_install, but last time I tried portage didn't like it if it's set
    so late. And then, do not think want to check what every branches
    install and maintain lists.. so, not ideal, but giving /usr/bin the
    same treatment that /usr/lib had with a wildcard for now.
    
    Closes: https://bugs.gentoo.org/950053
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 x11-drivers/nvidia-drivers/nvidia-drivers-390.157.ebuild       | 5 +++--
 x11-drivers/nvidia-drivers/nvidia-drivers-470.256.02-r2.ebuild | 5 +++--
 x11-drivers/nvidia-drivers/nvidia-drivers-535.230.02.ebuild    | 7 ++++---
 x11-drivers/nvidia-drivers/nvidia-drivers-550.144.03.ebuild    | 7 ++++---
 x11-drivers/nvidia-drivers/nvidia-drivers-550.40.85.ebuild     | 7 ++++---
 x11-drivers/nvidia-drivers/nvidia-drivers-570.86.16-r1.ebuild  | 7 ++++---
 6 files changed, 22 insertions(+), 16 deletions(-)