summaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
authorEdward W. Koenig <kingbeowulf@glinuxgalaxy.org>2020-03-24 18:33:53 -0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2020-03-28 13:20:37 +0700
commite08c9b0fcb8ea5d076ce3b5389d4747dcada9a3f (patch)
tree231aeaca696e0fc33ad403dd61586fede0f05f37 /system
parentf4c55a23c1df3a734f4d7588b2e8776cbbb96c74 (diff)
downloadslackbuilds-e08c9b0fcb8ea5d076ce3b5389d4747dcada9a3f.tar.gz
system/nvidia-driver: fix scripts; updated for version 440.64
Signed-off-by: Edward W. Koenig <kingbeowulf@glinuxgalaxy.org> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'system')
-rw-r--r--system/nvidia-driver/changelog.txt1
-rw-r--r--system/nvidia-driver/doinst.sh2
-rwxr-xr-x[-rw-r--r--]system/nvidia-driver/nvidia-driver.SlackBuild41
-rw-r--r--system/nvidia-driver/nvidia-driver.info12
-rw-r--r--system/nvidia-driver/nvidia-switch9
-rw-r--r--system/nvidia-driver/skip_conflict-GPU_detect.patch52
6 files changed, 79 insertions, 38 deletions
diff --git a/system/nvidia-driver/changelog.txt b/system/nvidia-driver/changelog.txt
index 993dec5133..a0c7bd16d3 100644
--- a/system/nvidia-driver/changelog.txt
+++ b/system/nvidia-driver/changelog.txt
@@ -48,3 +48,4 @@
7.0 28-Sep-2019 version update LLB, add temp glvnd switch for 15.0, remove nvidia-switch
7.1 15-Dec-2019 version update LLB, fix libs
7.2 12-Feb-2020 version update LLB
+7.3 24-Mar-2020 version update LLB, fixes nvidia-switch; doinst; update patch (thanks Daniel B.)
diff --git a/system/nvidia-driver/doinst.sh b/system/nvidia-driver/doinst.sh
index 392c12adb9..8ee62f049e 100644
--- a/system/nvidia-driver/doinst.sh
+++ b/system/nvidia-driver/doinst.sh
@@ -2,3 +2,5 @@ if [ -x /usr/bin/update-desktop-database ]; then
/usr/bin/update-desktop-database -q usr/share/applications
fi
+./usr/sbin/nvidia-switch --install
+
diff --git a/system/nvidia-driver/nvidia-driver.SlackBuild b/system/nvidia-driver/nvidia-driver.SlackBuild
index 124b0f4697..951f4a069c 100644..100755
--- a/system/nvidia-driver/nvidia-driver.SlackBuild
+++ b/system/nvidia-driver/nvidia-driver.SlackBuild
@@ -25,7 +25,7 @@
# see changelog.txt
PRGNAM=nvidia-driver
-VERSION=${VERSION:-440.59}
+VERSION=${VERSION:-440.64}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -154,7 +154,7 @@ cd $TMP/$SRCNAM
$COMP32
# Clean-up: we really do not need this:
-rm -rf /var/log/nvidia
+rm -rf $PKG/var/log/nvidia
# If running current (15.0) remove duplicate libglvnd files and symlinks
if [ "$CURRENT" = "yes" ]; then
rm -f $PKG/usr/lib$LIBDIRSUFFIX/libEGL.so{,.1,.1.1.0}
@@ -173,6 +173,37 @@ if [ "$CURRENT" = "yes" ]; then
rm -f $PKG/usr/lib/libGLdispatch.so.0
rm -f $PKG/usr/lib/libOpenGL.so{,.0}
fi
+# Don't ship .la files:
+ rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.la
+ if [ "$ARCH" = "x86_64" -a "${COMPAT32}" = "yes" ]; then
+ rm -f $PKG/usr/lib/*.la
+ fi
+else
+# save libGL.la for 14.2
+ cd $PKG/usr/lib$LIBDIRSUFFIX
+ mv libGL.la libGL.la-nvidia
+ cd -
+ if [ "$ARCH" = "x86_64" -a "${COMPAT32}" = "yes" ]; then
+ cd $PKG/usr/lib
+ mv libGL.la libGL.la-nvidia
+ cd -
+ fi
+# Bash script to cleanly install (in doinst.sh) and uninstall the nvidia files
+# so we don't stomp on the overlapping xorg files.
+# Note: switching can be problematic ;-)
+ install -m 0755 $CWD/nvidia-switch $PKG/usr/sbin/
+ sed -i s/PKGVERSION/$VERSION/g $PKG/usr/sbin/nvidia-switch
+ sed -i s/LIBDIRSUFFIX/$LIBDIRSUFFIX/g $PKG/usr/sbin/nvidia-switch
+ if [ "$GLVND" = "yes" ]; then
+ sed -i s/GLVNDFLAG/yes/g $PKG/usr/sbin/nvidia-switch
+ else
+ sed -i s/GLVNDFLAG/no/g $PKG/usr/sbin/nvidia-switch
+ fi
+ if [ ${COMPAT32} = "yes" ]; then
+ sed -i s/LIB32FLAG/yes/g $PKG/usr/sbin/nvidia-switch
+ else
+ sed -i s/LIB32FLAG/no/g $PKG/usr/sbin/nvidia-switch
+ fi
fi
# add tls
@@ -262,12 +293,6 @@ cd -
install -m 644 _out/Linux_$TARGET/nvidia-persistenced.1.gz $PKG/usr/man/man1/
cd -
-# Don't ship .la files:
-rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.la
-if [ "$ARCH" = "x86_64" -a "${COMPAT32}" = "yes" ]; then
- rm -f $PKG/usr/lib/*.la
-fi
-
# These update or correct wrong paths
sed -i "s|__UTILS_PATH__|/usr/bin|" $PKG/usr/share/applications/nvidia-settings.desktop
sed -i "s|__PIXMAP_PATH__|/usr/share/pixmaps|" $PKG/usr/share/applications/nvidia-settings.desktop
diff --git a/system/nvidia-driver/nvidia-driver.info b/system/nvidia-driver/nvidia-driver.info
index f629ff3e21..cde0ddf80a 100644
--- a/system/nvidia-driver/nvidia-driver.info
+++ b/system/nvidia-driver/nvidia-driver.info
@@ -9,12 +9,12 @@ DOWNLOAD_x86_64="https://download.nvidia.com/XFree86/Linux-x86_64/440.59/NVIDIA-
https://download.nvidia.com/XFree86/nvidia-persistenced/nvidia-persistenced-440.59.tar.bz2 \
https://download.nvidia.com/XFree86/nvidia-settings/nvidia-settings-440.59.tar.bz2 \
https://download.nvidia.com/XFree86/nvidia-xconfig/nvidia-xconfig-440.59.tar.bz2"
-MD5SUM_x86_64="596a63329c35d24cd787dc4e7e72d2d1 \
- 18b0d54da4df390176dc3654a1a5f1f6 \
- 7b2dbf349b01bd0c3d40793271f015c5 \
- 1b17220f26eb4ba620e665c3d7f5fbbd \
- 755393454e1c6de7ebbdb8626ce0e45f \
- 9b319801537a1bc68f0291bf1b8682f7"
+MD5SUM_x86_64="ba746d5b5f50369139bbed47da04aa74 \
+ fbe92127e8d41c54059742f12eb0e347 \
+ 2fffb0aca454437534029b935bf65a79 \
+ 24c79658da81294c39c1fe22d0fc704e \
+ 94b081b77eba7cfd2aa82ffda54cca90 \
+ 80a50eb9892588d57cca02b1822cddbd"
REQUIRES="nvidia-kernel"
MAINTAINER="Edward W. Koenig"
EMAIL="kingbeowulf@gmail.com"
diff --git a/system/nvidia-driver/nvidia-switch b/system/nvidia-driver/nvidia-switch
index a1ac84734d..30f9a66cb0 100644
--- a/system/nvidia-driver/nvidia-switch
+++ b/system/nvidia-driver/nvidia-switch
@@ -20,7 +20,7 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
-# nvidia-switch utility 4.5
+# nvidia-switch utility 4.6
#
# A tool to install and cleanly remove the nvidia driver without stomping on the xorg files.
# Note: this tool "should" allow switching on the fly, but why? Pick a driver! You will still
@@ -41,9 +41,8 @@ NV_VERSION="PKGVERSION" # This will be replaced in the build script
GL_VERSION="1.2.0"
GLVND="yes" # This will be replaced in the build script (yes | no)
-
save_GL(){
-# backup original mesa and xorg conflicts to /var/log/nvidia
+# backup original mesa and xorg conflicts
cd $2
case "$1" in
"nvidia")
@@ -65,10 +64,6 @@ save_GL(){
}
nvidia_install(){
- if [ ! -d $SAVELIBS ]; then
- echo "Creating missing $SAVELIB ..."
- mkdir -p $SAVELIBS
- fi
echo $'Installing to nvidia-driver files!\n'
echo "Make sure the nvidia driver is ENABLED in /etc/X11/xorg.conf"
echo "and in /etc/X11/xorg.conf.d."
diff --git a/system/nvidia-driver/skip_conflict-GPU_detect.patch b/system/nvidia-driver/skip_conflict-GPU_detect.patch
index 2b979cbf46..a64b671d60 100644
--- a/system/nvidia-driver/skip_conflict-GPU_detect.patch
+++ b/system/nvidia-driver/skip_conflict-GPU_detect.patch
@@ -1,29 +1,47 @@
-diff -uaN command-list.c command-list.c.new
---- command-list.c 2018-01-24 20:59:24.000000000 -0800
-+++ command-list.c.new 2018-02-18 00:51:13.218202297 -0800
-@@ -903,6 +903,8 @@
+diff -uaN command-list.c command-list.c.new
+--- command-list.c 2020-01-29 17:56:11.000000000 -0800
++++ command-list.c.new 2020-03-08 11:24:03.000000000 -0700
+@@ -890,6 +890,8 @@
// Allocate enough space for the whole file list, plus two extra files and
// a NULL at the end.
cfList = nvalloc((p->num_entries + 3) * sizeof(ConflictingFileInfo));
-+/* let's just return an empty list! */
++ /* let's just return an empty list! */
+ return cfList;
-
+
for (i = 0; i < p->num_entries; i++) {
PackageEntry *entry = &p->entries[i];
-
-diff -uaN misc.c misc.c.new
---- misc.c 2018-02-18 00:52:42.822203145 -0800
-+++ misc.c.new 2018-02-18 00:53:28.926203581 -0800
-@@ -2289,7 +2289,10 @@
+
+diff -uaN misc.c misc.c.new
+--- misc.c 2020-01-29 17:56:11.000000000 -0800
++++ misc.c.new 2020-03-08 11:42:12.000000000 -0700
+@@ -1153,13 +1153,12 @@
+ }
+
+ if (!install) {
+- ui_warn(op, "The %s module will not be installed. As a result, %s "
+- "will not function with this installation of the NVIDIA "
+- "driver.", optional_modules[i].module_name,
++ ui_warn(op, "The %s module will be installed with no gpu detect. As a result, %s "
++ "will function with this installation of the NVIDIA "
++ "driver, but only if the card is installed", optional_modules[i].module_name,
+ optional_modules[i].optional_module_dependee);
+-
+- remove_kernel_module_from_package(p,
+- optional_modules[i].module_name);
++// remove_kernel_module_from_package(p,
++// optional_modules[i].module_name);
+ }
+ }
+ }
+@@ -2036,7 +2035,10 @@
"For further details, please see the appendix SUPPORTED "
"NVIDIA GRAPHICS CHIPS in the README available on the Linux "
"driver download page at www.nvidia.com.", p->version);
- return FALSE;
-+/* return FALSE;
-+ * We're just going to keep the message but skip the result
-+ * so we can run this in a VM.
-+ */
++ /* return FALSE;
++ * We're just going to keep the message but skip the result
++ * so we can run this in a VM.
++ */
}
-
- if (!found_vga_device)
+ if (!found_vga_device)