diff options
author | Ionen Wolkens <sudinave@gmail.com> | 2021-04-06 22:00:19 +0200 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2021-04-06 22:00:19 +0200 |
commit | a552a2f91d8e69aead632fe512d520c25b987f4d (patch) | |
tree | 5896ab134dbaab4a30a7aa5da80331361d2c14f8 /x11-drivers/nvidia-drivers | |
parent | x11-drivers/nvidia-drivers: need PROC_FS, update AMD SME check (diff) | |
download | gentoo-a552a2f91d8e69aead632fe512d520c25b987f4d.tar.gz gentoo-a552a2f91d8e69aead632fe512d520c25b987f4d.tar.bz2 gentoo-a552a2f91d8e69aead632fe512d520c25b987f4d.zip |
x11-drivers/nvidia-drivers: add README.gentoo, minor message changes
Like nvidia-driver.eclass used to it's primarily to leave something
behind about the video group should users have missed the message
(but no revbumps over installing this).
Signed-off-by: Ionen Wolkens <sudinave@gmail.com>
Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'x11-drivers/nvidia-drivers')
4 files changed, 58 insertions, 64 deletions
diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-390.141-r1.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-390.141-r1.ebuild index ba2b3e553478..baff134c6954 100644 --- a/x11-drivers/nvidia-drivers/nvidia-drivers-390.141-r1.ebuild +++ b/x11-drivers/nvidia-drivers/nvidia-drivers-390.141-r1.ebuild @@ -4,8 +4,8 @@ EAPI=7 MODULES_OPTIONAL_USE="driver" -inherit desktop linux-info linux-mod multilib-build \ - optfeature systemd toolchain-funcs unpacker +inherit desktop linux-info linux-mod multilib-build optfeature \ + readme.gentoo-r1 systemd toolchain-funcs unpacker NV_KERNEL_MAX="5.10" NV_BIN_URI="https://download.nvidia.com/XFree86/Linux-" @@ -82,6 +82,13 @@ DOCS=( ) HTML_DOCS=( html/. ) +DISABLE_AUTOFORMATTING="yes" +DOC_CONTENTS="Users should be in the 'video' group to use NVIDIA devices. +You can add yourself by using: gpasswd -a my-user video + +For general information on using nvidia-drivers, please see: +https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" + pkg_setup() { use driver || return @@ -334,6 +341,7 @@ src_install() { multilib_foreach_abi nvidia-drivers_libs_install einstalldocs + readme.gentoo_create_doc } pkg_preinst() { @@ -350,30 +358,21 @@ pkg_preinst() { pkg_postinst() { use driver && linux-mod_pkg_postinst + readme.gentoo_print_elog + optfeature "wayland EGLStream with nvidia-drm.modeset=1" gui-libs/egl-wayland if [[ -r /proc/driver/nvidia/version && $(grep -o ' [0-9.]* ' /proc/driver/nvidia/version) != " ${PV} " ]]; then ewarn "Currently loaded NVIDIA modules do not match the newly installed" ewarn "libraries and will lead to GPU-using application issues." - use driver && ewarn "The easiest way to fix this is to reboot." + use driver && ewarn "The easiest way to fix this is usually to reboot." fi - if ! [[ ${REPLACING_VERSIONS} && $(getent group video | cut -d: -f4) ]]; then - elog "***** WARNING *****" - elog "Users should be in the 'video' group to use NVIDIA devices." - elog "You can add yourself by using: gpasswd -a myuser video" - fi - - if [[ ! ${REPLACING_VERSIONS} ]]; then - if use x86; then - elog "Note that NVIDIA is no longer offering support for the unified memory" - elog "module (nvidia-uvm) on x86 (32bit), as such the module was not built." - elog "This means OpenCL/CUDA (and related, like nvenc) cannot be used." - elog "Other functions, like OpenGL, will continue to work." - elog - fi - elog "For general information with using NVIDIA on Gentoo, please see:" - elog "https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" + if use x86 && [[ ! ${REPLACING_VERSIONS} ]]; then + elog "Note that NVIDIA is no longer offering support for the unified memory" + elog "module (nvidia-uvm) on x86 (32bit), as such the module was not built." + elog "This means OpenCL/CUDA (and related, like nvenc) cannot be used." + elog "Other functions, like OpenGL, will continue to work." fi } diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-450.102.04-r1.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-450.102.04-r1.ebuild index 652983159251..4b35ed9fa958 100644 --- a/x11-drivers/nvidia-drivers/nvidia-drivers-450.102.04-r1.ebuild +++ b/x11-drivers/nvidia-drivers/nvidia-drivers-450.102.04-r1.ebuild @@ -4,8 +4,8 @@ EAPI=7 MODULES_OPTIONAL_USE="driver" -inherit desktop linux-info linux-mod multilib-build \ - optfeature systemd toolchain-funcs unpacker +inherit desktop linux-info linux-mod multilib-build optfeature \ + readme.gentoo-r1 systemd toolchain-funcs unpacker NV_KERNEL_MAX="5.10" NV_BIN_URI="https://download.nvidia.com/XFree86/Linux-" @@ -81,6 +81,13 @@ DOCS=( ) HTML_DOCS=( html/. ) +DISABLE_AUTOFORMATTING="yes" +DOC_CONTENTS="Users should be in the 'video' group to use NVIDIA devices. +You can add yourself by using: gpasswd -a my-user video + +For general information on using nvidia-drivers, please see: +https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" + pkg_setup() { use driver || return @@ -341,6 +348,7 @@ src_install() { systemd_dounit nvidia-{hibernate,resume,suspend}.service einstalldocs + readme.gentoo_create_doc } pkg_preinst() { @@ -371,17 +379,18 @@ pkg_preinst() { pkg_postinst() { use driver && linux-mod_pkg_postinst + readme.gentoo_print_elog + optfeature "wayland EGLStream with nvidia-drm.modeset=1" gui-libs/egl-wayland if [[ -r /proc/driver/nvidia/version && $(grep -o ' [0-9.]* ' /proc/driver/nvidia/version) != " ${PV} " ]]; then ewarn "Currently loaded NVIDIA modules do not match the newly installed" ewarn "libraries and will lead to GPU-using application issues." - use driver && ewarn "The easiest way to fix this is to reboot." + use driver && ewarn "The easiest way to fix this is usually to reboot." fi if [[ ${NV_LEGACY_MASK} ]]; then - ewarn "***** WARNING *****" ewarn "You are installing a version of nvidia-drivers known not to work" ewarn "with a GPU of the current system. If unwanted, add the mask:" if [[ -d ${EROOT}/etc/portage/package.mask ]]; then @@ -392,15 +401,4 @@ pkg_postinst() { ewarn "...then downgrade to a legacy branch if possible. For details, see:" ewarn "https://www.nvidia.com/object/IO_32667.html" fi - - if ! [[ ${REPLACING_VERSIONS} && $(getent group video | cut -d: -f4) ]]; then - elog "***** WARNING *****" - elog "Users should be in the 'video' group to use NVIDIA devices." - elog "You can add yourself by using: gpasswd -a myuser video" - fi - - if [[ ! ${REPLACING_VERSIONS} ]]; then - elog "For general information with using NVIDIA on Gentoo, please see:" - elog "https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" - fi } diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-460.67.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-460.67.ebuild index d7602b8fcfaf..18cbd4cb2f0b 100644 --- a/x11-drivers/nvidia-drivers/nvidia-drivers-460.67.ebuild +++ b/x11-drivers/nvidia-drivers/nvidia-drivers-460.67.ebuild @@ -4,8 +4,8 @@ EAPI=7 MODULES_OPTIONAL_USE="driver" -inherit desktop linux-info linux-mod multilib-build \ - optfeature systemd toolchain-funcs unpacker +inherit desktop linux-info linux-mod multilib-build optfeature \ + readme.gentoo-r1 systemd toolchain-funcs unpacker NV_KERNEL_MAX="5.11" NV_BIN_URI="https://download.nvidia.com/XFree86/Linux-" @@ -81,6 +81,13 @@ DOCS=( ) HTML_DOCS=( html/. ) +DISABLE_AUTOFORMATTING="yes" +DOC_CONTENTS="Users should be in the 'video' group to use NVIDIA devices. +You can add yourself by using: gpasswd -a my-user video + +For general information on using nvidia-drivers, please see: +https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" + pkg_setup() { use driver || return @@ -345,6 +352,7 @@ src_install() { systemd_dounit nvidia-{hibernate,resume,suspend}.service einstalldocs + readme.gentoo_create_doc } pkg_preinst() { @@ -375,17 +383,18 @@ pkg_preinst() { pkg_postinst() { use driver && linux-mod_pkg_postinst + readme.gentoo_print_elog + optfeature "wayland EGLStream with nvidia-drm.modeset=1" gui-libs/egl-wayland if [[ -r /proc/driver/nvidia/version && $(grep -o ' [0-9.]* ' /proc/driver/nvidia/version) != " ${PV} " ]]; then ewarn "Currently loaded NVIDIA modules do not match the newly installed" ewarn "libraries and will lead to GPU-using application issues." - use driver && ewarn "The easiest way to fix this is to reboot." + use driver && ewarn "The easiest way to fix this is usually to reboot." fi if [[ ${NV_LEGACY_MASK} ]]; then - ewarn "***** WARNING *****" ewarn "You are installing a version of nvidia-drivers known not to work" ewarn "with a GPU of the current system. If unwanted, add the mask:" if [[ -d ${EROOT}/etc/portage/package.mask ]]; then @@ -396,15 +405,4 @@ pkg_postinst() { ewarn "...then downgrade to a legacy branch if possible. For details, see:" ewarn "https://www.nvidia.com/object/IO_32667.html" fi - - if ! [[ ${REPLACING_VERSIONS} && $(getent group video | cut -d: -f4) ]]; then - elog "***** WARNING *****" - elog "Users should be in the 'video' group to use NVIDIA devices." - elog "You can add yourself by using: gpasswd -a myuser video" - fi - - if [[ ! ${REPLACING_VERSIONS} ]]; then - elog "For general information with using NVIDIA on Gentoo, please see:" - elog "https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" - fi } diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-465.19.01.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-465.19.01.ebuild index dd0174cd0271..33c06261278f 100644 --- a/x11-drivers/nvidia-drivers/nvidia-drivers-465.19.01.ebuild +++ b/x11-drivers/nvidia-drivers/nvidia-drivers-465.19.01.ebuild @@ -4,8 +4,8 @@ EAPI=7 MODULES_OPTIONAL_USE="driver" -inherit desktop linux-info linux-mod multilib-build \ - optfeature systemd toolchain-funcs unpacker +inherit desktop linux-info linux-mod multilib-build optfeature \ + readme.gentoo-r1 systemd toolchain-funcs unpacker NV_KERNEL_MAX="5.11" NV_BIN_URI="https://download.nvidia.com/XFree86/Linux-" @@ -81,6 +81,13 @@ DOCS=( ) HTML_DOCS=( html/. ) +DISABLE_AUTOFORMATTING="yes" +DOC_CONTENTS="Users should be in the 'video' group to use NVIDIA devices. +You can add yourself by using: gpasswd -a my-user video + +For general information on using nvidia-drivers, please see: +https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" + pkg_setup() { use driver || return @@ -107,6 +114,7 @@ pkg_setup() { nvidia-drm(video:kernel) nvidia-modeset(video:kernel) nvidia-uvm(video:kernel)" + # nvidia-peermem(video:kernel) - skipping unless there is a demand for it linux-mod_pkg_setup @@ -345,6 +353,7 @@ src_install() { systemd_dounit systemd/system/nvidia-{hibernate,resume,suspend}.service einstalldocs + readme.gentoo_create_doc } pkg_preinst() { @@ -375,17 +384,18 @@ pkg_preinst() { pkg_postinst() { use driver && linux-mod_pkg_postinst + readme.gentoo_print_elog + optfeature "wayland EGLStream with nvidia-drm.modeset=1" gui-libs/egl-wayland if [[ -r /proc/driver/nvidia/version && $(grep -o ' [0-9.]* ' /proc/driver/nvidia/version) != " ${PV} " ]]; then ewarn "Currently loaded NVIDIA modules do not match the newly installed" ewarn "libraries and will lead to GPU-using application issues." - use driver && ewarn "The easiest way to fix this is to reboot." + use driver && ewarn "The easiest way to fix this is usually to reboot." fi if [[ ${NV_LEGACY_MASK} ]]; then - ewarn "***** WARNING *****" ewarn "You are installing a version of nvidia-drivers known not to work" ewarn "with a GPU of the current system. If unwanted, add the mask:" if [[ -d ${EROOT}/etc/portage/package.mask ]]; then @@ -396,15 +406,4 @@ pkg_postinst() { ewarn "...then downgrade to a legacy branch if possible. For details, see:" ewarn "https://www.nvidia.com/object/IO_32667.html" fi - - if ! [[ ${REPLACING_VERSIONS} && $(getent group video | cut -d: -f4) ]]; then - elog "***** WARNING *****" - elog "Users should be in the 'video' group to use NVIDIA devices." - elog "You can add yourself by using: gpasswd -a myuser video" - fi - - if [[ ! ${REPLACING_VERSIONS} ]]; then - elog "For general information with using NVIDIA on Gentoo, please see:" - elog "https://wiki.gentoo.org/wiki/NVIDIA/nvidia-drivers" - fi } |