diff options
author | Edward Koenig <kingbeowulf@gmail.com> | 2015-02-11 22:24:54 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2015-02-11 22:24:54 +0700 |
commit | 2b3956c934226e1160346ee65da26bffd05fbb46 (patch) | |
tree | ad3759504093a11cea533b882b84023e1c697cfe | |
parent | a7b8233afc1929e310f19b4ae1ad4f589f10e35a (diff) | |
download | slackbuilds-2b3956c934226e1160346ee65da26bffd05fbb46.tar.gz |
system/nvidia-legacy304-driver: Updated for version 304.125.
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r-- | system/nvidia-legacy304-driver/changelog.txt | 14 | ||||
-rw-r--r-- | system/nvidia-legacy304-driver/nvidia-legacy304-driver.SlackBuild | 111 | ||||
-rw-r--r-- | system/nvidia-legacy304-driver/nvidia-legacy304-driver.info | 30 | ||||
-rw-r--r-- | system/nvidia-legacy304-driver/nvidia-switch | 106 |
4 files changed, 158 insertions, 103 deletions
diff --git a/system/nvidia-legacy304-driver/changelog.txt b/system/nvidia-legacy304-driver/changelog.txt new file mode 100644 index 0000000000..7712a25dd2 --- /dev/null +++ b/system/nvidia-legacy304-driver/changelog.txt @@ -0,0 +1,14 @@ +1.0 20-MAR-2011 New Maintainer: Edward W. Koenig <kingbeowulf@gmail.com> +1.1 10-APR-2011 updated to new version, testing 13.37rc4.6692 +1.2 27-MAY-2011 new version, allow multilib option, minor edits +1.2.1 20-JUN-2011 minor edits, thanks to Robby and Roberto +1.5 01-JUL-2011 new version, single driver download, add switch to select pure x86_64 or x86_64 with 32-bit compatibility. +1.6 27-AUG-2011 version bump, minor edits +1.7 21-OCT-2011 version bump +1.8 24-MAR-2012 version bump, fix to nvidia-switch thanks to Phill W. +1.9 02-AUG-2012 version bmp, fixes, updates, nvidia-switch for install/uninstall only +3.0 06-JUL-2013 Legacy 304 branch, removed 32-bit compatibility +3.1 22-SEP-2013 version update +3.1a 04-NOV-2013 minor fixes for 14.1 release +3.2 08-FEB-2015 version update, restored 32-bit compatibility + diff --git a/system/nvidia-legacy304-driver/nvidia-legacy304-driver.SlackBuild b/system/nvidia-legacy304-driver/nvidia-legacy304-driver.SlackBuild index b452b33164..523d3b3a88 100644 --- a/system/nvidia-legacy304-driver/nvidia-legacy304-driver.SlackBuild +++ b/system/nvidia-legacy304-driver/nvidia-legacy304-driver.SlackBuild @@ -25,27 +25,14 @@ # Thanks to Robby Workman for suggestions to improve this script. # -# ChangeLog -# ------------------------------------------------------------------------------ -# 1.0 20-MAR-2011 New Maintainer: Edward W. Koenig <kingbeowulf@gmail.com> -# 1.1 10-APR-2011 updated to new version, testing 13.37rc4.6692 -# 1.2 27-MAY-2011 new version, allow multilib option, minor edits -# 1.2.1 20-JUNE-2011 minor edits, thanks to Robby and Roberto -# 1.5 01-JULY-2011 new version, single driver download, add switch to select -# pure x86_64 or x86_64 with 32-bit compatibility. -# 1.6 27-AUG-2011 version bump, minor edits -# 1.7 21-OCT-2011 version bump -# 1.8 24-MAR-2012 version bump, fix to nvidia-switch thanks to Phill W. -# 1.9 02-AUG-2012 version bmp, fixes, updates, nvidia-switch for install/uninstall only -# 3.0 06-JUL-2013 Legacy 304 branch, removed 32-bit compatibility -# 3.1 22-SEP-2013 version update -# 3.1a 04-NOV-2013 minor fixes for 14.1 release +# See changelog.txt PRGNAM=nvidia-legacy304-driver -VERSION=304.108 +VERSION=${VERSION:-304.125} MVERS=304 BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +CPROXY=${CPROXY:-no} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -64,24 +51,22 @@ if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mtune=i686" TARGET="x86" LIBDIRSUFFIX="" - COMPAT32="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" TARGET="x86" LIBDIRSUFFIX="" - COMPAT32="" elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2 -fPIC" TARGET="x86_64" LIBDIRSUFFIX="64" - COMPAT32="-no-compat32" +# Set 32-bit compatibility flag default + COMPAT32=${COMPAT32:-no} else SLKCFLAGS="-O2" LIBDIRSUFFIX="" - COMPAT32="" fi -SRCNAM=NVIDIA-Linux-$TARGET-${VERSION}$COMPAT32 +SRCNAM=NVIDIA-Linux-$TARGET-${VERSION} set -e @@ -102,52 +87,78 @@ find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ -o -perm 511 \) -exec chmod 755 {} \; -o \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ - -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; mkdir -p $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules/{drivers,extensions} \ $PKG/etc/OpenCL/vendors/ $PKG/usr/lib$LIBDIRSUFFIX/tls \ $PKG/usr/{bin,man/man1,sbin} $PKG/usr/share/{applications,pixmaps} \ $PKG/usr/include/GL +# Get all the libs to the right place install -m 755 nvidia_drv.so $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules/drivers/ +install -m 755 libcuda.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ install -m 755 libglx.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules/extensions/libglx.so.$VERSION-nvidia install -m 755 libGL.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/libGL.so.$VERSION-nvidia -install -m 755 libGL.la $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libOpenCL.so.1.0.0 $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 444 libXvMCNVIDIA.a $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libXvMCNVIDIA.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libcuda.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libnvidia-opencl.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libnvidia-glcore.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libnvidia-wfb.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules/ -install -m 755 libnvidia-cfg.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ +install -m 755 libGL.la $PKG/usr/lib$LIBDIRSUFFIX/libGL.la-nvidia install -m 755 libnvcuvid.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ +install -m 755 libnvidia-cfg.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ install -m 755 libnvidia-compiler.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 644 nvidia.icd $PKG/etc/OpenCL/vendors/ +install -m 755 libnvidia-glcore.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ +install -m 755 libnvidia-ml.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ +install -m 755 libnvidia-opencl.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ install -m 755 tls/libnvidia-tls.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/tls/ +install -m 755 libOpenCL.so.1.0.0 $PKG/usr/lib$LIBDIRSUFFIX/ # For 8-series GPU if libwfb.so is missing (ie older X servers). install -m 755 libnvidia-wfb.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules/libnvidia-wfb.so.$VERSION-nvidia # Don't forget separate libvdpau package on SBo. install -m 755 libvdpau_nvidia.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ -install -m 755 libvdpau_trace.so.$VERSION $PKG/usr/lib$LIBDIRSUFFIX/ + +install -m 644 nvidia.icd $PKG/etc/OpenCL/vendors/ + +# Add optional 32-bit support +if [ "$ARCH" = "x86_64" -a "${COMPAT32}" = "yes" ]; then + mkdir -p $PKG/usr/lib/tls + + install -m 755 32/libcuda.so.$VERSION $PKG/usr/lib/ + install -m 755 32/libGL.so.$VERSION $PKG/usr/lib/libGL.so.$VERSION-nvidia + install -m 755 32/libGL.la $PKG/usr/lib/libGL.la-nvidia + install -m 755 32/libnvidia-compiler.so.$VERSION $PKG/usr/lib/ + install -m 755 32/libnvidia-glcore.so.$VERSION $PKG/usr/lib/ + install -m 755 32/libnvidia-opencl.so.$VERSION $PKG/usr/lib/ + install -m 755 32/tls/libnvidia-tls.so.$VERSION $PKG/usr/lib/tls/ + install -m 755 32/libnvidia-opencl.so.$VERSION $PKG/usr/lib/ + install -m 755 32/libnvidia-ml.so.$VERSION $PKG/usr/lib/ + install -m 755 32/libOpenCL.so.1.0.0 $PKG/usr/lib/ + install -m 755 32/libvdpau_nvidia.so.$VERSION $PKG/usr/lib/ +fi # symlinks cd $PKG/usr/lib$LIBDIRSUFFIX - for i in libcuda libnvidia-cfg libnvcuvid libXvMCNVIDIA; do + for i in libcuda libnvidia-cfg; do ln -s $i.so.$VERSION $i.so.1 ln -s $i.so.1 $i.so done ln -sf libOpenCL.so.1.0.0 libOpenCL.so.1.0 ln -sf libOpenCL.so.1.0 libOpenCL.so.1 ln -sf libOpenCL.so.1 libOpenCL.so + ln -sf libvdpau_nvidia.so.$VERSION libvdpau_nvidia.so ln -sf tls/libnvidia-tls.so.$VERSION libnvidia-tls.so.$VERSION cd - -cd $PKG/usr/lib$LIBDIRSUFFIX/xorg/modules - ln -sf libnvidia-wfb.so.$VERSION libnvidia-wfb.so -cd - +# symlinks for optional 32-bit support +if [ "$ARCH" = "x86_64" -a "${COMPAT32}" = "yes" ]; then + cd $PKG/usr/lib + ln -sf libcuda.so.$VERSION libcuda.so.$MVERS + ln -sf libcuda.so.$MVERS libcuda.so + ln -sf libOpenCL.so.1.0.0 libOpenCL.so.1.0 + ln -sf libOpenCL.so.1.0 libOpenCL.so.1 + ln -sf libOpenCL.so.1 libOpenCL.so + ln -sf libvdpau_nvidia.so.$VERSION libvdpau_nvidia.so + ln -sf tls/libnvidia-tls.so.$VERSION libnvidia-tls.so.$VERSION + cd - +fi # Next come the apps for i in nvidia-smi nvidia-bug-report.sh nvidia-debugdump; do @@ -156,7 +167,16 @@ done install -m 644 nvidia-smi.1.gz $PKG/usr/man/man1/ +# New CUDA proxy server for 64-bit Linux only, and requires a device that supports +# Unified Virtual Address (UVA) and CUDA 4.0+. +if [ "$ARCH" = "x86_64" -a "${CPROXY}" = "yes" ]; then + install -m 755 nvidia-cuda-mps-control $PKG/usr/bin/ + install -m 755 nvidia-cuda-mps-server $PKG/usr/bin/ + install -m 644 nvidia-cuda-mps-control.1.gz $PKG/usr/man/man1/ +fi + # Compiling nvidia-installer from source +# Not really needed for this SBo package cd $TMP/nvidia-installer-$VERSION chown -R root:root . find -L . \ @@ -165,9 +185,7 @@ cd $TMP/nvidia-installer-$VERSION \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; - CFLAGS="$SLKCFLAGS" \ - LDFLAGS="-lz" \ - make + CFLAGS="$SLKCFLAGS" LDFLAGS="-lz" make install -m 755 _out/Linux_$TARGET/nvidia-installer $PKG/usr/bin/ install -m 644 _out/Linux_$TARGET/nvidia-installer.1.gz $PKG/usr/man/man1/ @@ -215,14 +233,19 @@ cd - # 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 "on the fly" no longer supported. +# Note: switching "on the fly" is no longer supported. 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 [ ${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 -# These correct wrong paths -sed -i "s|__LIBGL_PATH__|/usr/lib$LIBDIRSUFFIX/|" $PKG/usr/lib$LIBDIRSUFFIX/libGL.la -sed -i "s|/usr/X11R6/lib|/usr/lib$LIBDIRSUFFIX/|" $PKG/usr/lib$LIBDIRSUFFIX/libGL.la +# These update placeholders and correct wrong paths +sed -i "s|__LIBGL_PATH__|/usr/lib$LIBDIRSUFFIX/|" $PKG/usr/lib$LIBDIRSUFFIX/libGL.la-nvidia +sed -i "s|/usr/X11R6/lib|/usr/lib$LIBDIRSUFFIX/|" $PKG/usr/lib$LIBDIRSUFFIX/libGL.la-nvidia sed -i "s|__UTILS_PATH__|/usr/bin|" \ $PKG/usr/share/applications/nvidia-settings.desktop sed -i "s|__PIXMAP_PATH__|/usr/share/pixmaps|" \ diff --git a/system/nvidia-legacy304-driver/nvidia-legacy304-driver.info b/system/nvidia-legacy304-driver/nvidia-legacy304-driver.info index 0a781909d3..e7f03dd8fd 100644 --- a/system/nvidia-legacy304-driver/nvidia-legacy304-driver.info +++ b/system/nvidia-legacy304-driver/nvidia-legacy304-driver.info @@ -1,16 +1,22 @@ PRGNAM="nvidia-legacy304-driver" -VERSION="304.108" +VERSION="304.125" HOMEPAGE="http://www.nvidia.com" -DOWNLOAD="ftp://download.nvidia.com/XFree86/Linux-x86/304.108/NVIDIA-Linux-x86-304.108.run \ - ftp://download.nvidia.com/XFree86/nvidia-installer/nvidia-installer-304.108.tar.bz2 \ - ftp://download.nvidia.com/XFree86/nvidia-settings/nvidia-settings-304.108.tar.bz2 \ - ftp://download.nvidia.com/XFree86/nvidia-xconfig/nvidia-xconfig-304.108.tar.bz2" -MD5SUM="ef453e32515c2176c67ebd95c770dc0e \ - 32383742e807f3b142eb1c75c0155fe3 \ - 479225668f016e0b03be3c085ebbe89b \ - 18846fbff53aef67beb875e41aa0b979" -DOWNLOAD_x86_64="ftp://download.nvidia.com/XFree86/Linux-x86_64/304.108/NVIDIA-Linux-x86_64-304.108-no-compat32.run" -MD5SUM_x86_64="4e0e54de6735023f44c858a3006b3e18" +DOWNLOAD="ftp://download.nvidia.com/XFree86/Linux-x86/304.125/NVIDIA-Linux-x86-304.125.run \ + ftp://download.nvidia.com/XFree86/nvidia-installer/nvidia-installer-304.125.tar.bz2 \ + ftp://download.nvidia.com/XFree86/nvidia-settings/nvidia-settings-304.125.tar.bz2 \ + ftp://download.nvidia.com/XFree86/nvidia-xconfig/nvidia-xconfig-304.125.tar.bz2" +MD5SUM="bc3b0ac291fa998d5109a6f7e94fb2d4 \ + d4c4c811ab1e4123d54dcf6e1996caf2 \ + b1502ede3c91ddad563c55cb3b0a20d8 \ + 0a46296ed71981b69317122420c00935" +DOWNLOAD_x86_64="ftp://download.nvidia.com/XFree86/Linux-x86_64/304.125/NVIDIA-Linux-x86_64-304.125.run \ + ftp://download.nvidia.com/XFree86/nvidia-installer/nvidia-installer-304.125.tar.bz2 \ + ftp://download.nvidia.com/XFree86/nvidia-settings/nvidia-settings-304.125.tar.bz2 \ + ftp://download.nvidia.com/XFree86/nvidia-xconfig/nvidia-xconfig-304.125.tar.bz2" +MD5SUM_x86_64="3b91df19fa917a414dacd8e87f993557 \ + d4c4c811ab1e4123d54dcf6e1996caf2 \ + b1502ede3c91ddad563c55cb3b0a20d8 \ + 0a46296ed71981b69317122420c00935" REQUIRES="libvdpau nvidia-legacy304-kernel" -MAINTAINER="Edward W. Koenig" +MAINTAINER="Edward Koenig" EMAIL="kingbeowulf@gmail.com" diff --git a/system/nvidia-legacy304-driver/nvidia-switch b/system/nvidia-legacy304-driver/nvidia-switch index 66a9901163..242464cdd0 100644 --- a/system/nvidia-legacy304-driver/nvidia-switch +++ b/system/nvidia-legacy304-driver/nvidia-switch @@ -1,6 +1,6 @@ #!/bin/sh -# Copyright 2012 Edward W. Koenig, Vancouver, WA, USA +# Copyright 2012-2015 Edward W. Koenig, Vancouver, WA, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -20,18 +20,23 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # -# nvidia-switch utility 2.0.0 +# nvidia-switch utility 2.3 # # A tool to install and cleanly remove the nvidia driver without stomping on the xorg files. -# Note: this tool no longer supports switching drivers "on the fly" only installing and uninstalling -# the nvidia driver and restoring the original xorg files. +# Note: this tool "should" allow switching on the fly, but why? Pick a driver! You will still +# need to edit a bunch of other config files. + +# TO-DO: needs cleanup; too "wordy" and brittle. set -e ROOT="/" CWD=$(pwd) LIBSUFFIX="LIBDIRSUFFIX" # This will be replaced in the build script +COMPAT32="LIB32FLAG" # This will be replaced in the build script (yes | no) +INC="${ROOT}usr/include/GL" LIB="${ROOT}usr/lib${LIBSUFFIX}" +LIB32="${ROOT}usr/lib" XMOD="${LIB}/xorg/modules" XLIB="$XMOD/extensions" NV_VERSION='PKGVERSION' # This will be replaced in the build script @@ -39,37 +44,57 @@ GL_VERSION="1.2.0" NV_CONF="/usr/share/X11/xorg.conf.d/10-nvidia.conf" save_GL(){ - cd "$LIB" + cd $2 if [ "$1" = "nvidia" ]; then - mv libGL.so.$GL_VERSION libGL.so.$GL_VERSION-xorg - ln -sf libGL.so.$NV_VERSION-nvidia libGL.so.$NV_VERSION - ln -sf libGL.so.$NV_VERSION libGL.so.1 - ln -sf libGL.so.1 libGL.so - elif [ "$1" = "xorg" ]; then - mv libGL.so.$GL_VERSION-xorg libGL.so.$GL_VERSION - rm -f libGL.so.$NV_VERSION - ln -sf libGL.so.$GL_VERSION libGL.so.1 - ln -sf libGL.so.$GL_VERSION libGL.so - fi -cd "$CWD" + if [ ! -e libGL.so.$GL_VERSION-xorg ]; then + mv libGL.so.$GL_VERSION libGL.so.$GL_VERSION-xorg + mv libGL.la libGL.la-xorg + fi + mv libGL.so.$NV_VERSION-nvidia libGL.so.$NV_VERSION + ln -sf libGL.so.$NV_VERSION libGL.so.1 + ln -sf libGL.so.$NV_VERSION libGL.so + if [ ! -e libEGL.so.1.0.0-xorg ]; then + mv libEGL.so.1.0.0 libEGL.so.1.0.0-xorg + fi + mv libGL.la-nvidia libGL.la + fi + + if [ "$1" = "xorg" ]; then + mv libGL.so.$NV_VERSION libGL.so.$NV_VERSION-nvidia + mv libGL.la libGL.la-nvidia + if [ -e libGL.so.$GL_VERSION-xorg ]; then + mv libGL.so.$GL_VERSION-xorg libGL.so.$GL_VERSION + ln -sf libGL.so.$GL_VERSION libGL.so.1 + ln -sf libGL.so.$GL_VERSION libGL.so + mv libGL.la-xorg libGL.la + else + echo WARNING: libGL.so is missing. + fi + + fi + cd "$CWD" } save_wfb(){ cd "$XMOD" if [ "$1" = "nvidia" ]; then - ln -sf libnvidia-wfb.so.$NV_VERSION-nvidia libnvidia-wfb.so.$NV_VERSION + mv libnvidia-wfb.so.$NV_VERSION-nvidia libnvidia-wfb.so.$NV_VERSION ln -sf libnvidia-wfb.so.$NV_VERSION libnvidia-wfb.so.1 if [ ! -e libwfb.so ]; then + mv libwfb.so libwfb.so-xorg ln -sf libnvidia-wfb.so.$NV_VERSION libwfb.so fi elif [ "$1" = "xorg" ]; then - rm -f libnvidia-wfb.so.$NV_VERSION + mv libnvidia-wfb.so.$NV_VERSION libnvidia-wfb.so.$NV_VERSION-nvidia rm -f libnvidia-wfb.so.1 if [ -L libwfb.so ]; then rm -f libwfb.so + if [ -e libwfb.so-xorg ]; then + mv libwfb.so-xorg libwfb.so + fi fi - fi -cd "$CWD" + fi + cd "$CWD" } save_glx(){ @@ -86,27 +111,23 @@ save_glx(){ rm -f libglx.so mv libglx.so-xorg libglx.so mv libglx.la-xorg libglx.la - fi + fi cd "$CWD" } -nvidia_ldconfig(){ - /sbin/ldconfig - #Generate correct symink for that lib - /sbin/ldconfig -l $1 -} - nvidia_install(){ echo $'Installing to nvidia-driver files!\n' - echo "Make sure the nvidia driver is ENABLED in /etc/X11/xorg.conf." + echo "Make sure the nvidia driver is ENABLED in /etc/X11/xorg.conf" + echo "and in /etc/X11/xorg.conf.d." echo "Otherwise, this may lead to improperly working drivers." - save_GL "nvidia" + save_GL "nvidia" $LIB save_wfb "nvidia" save_glx "nvidia" - - LD_NVIDIA="${LIB}/libGL.so.$NV_VERSION-nvidia" - nvidia_ldconfig $LD_NVIDIA +# Check for multilib configuration + if [ "$COMPAT32" = "yes" ]; then + save_GL "nvidia" $LIB32 + fi } nvidia_remove(){ @@ -115,36 +136,27 @@ nvidia_remove(){ echo "and in /etc/X11/xorg.conf.d." echo "Otherwise, this may lead to improperly working drivers." - save_GL "xorg" + save_GL "xorg" $LIB save_wfb "xorg" save_glx "xorg" +# Check for multilib configuration + if [ "$COMPAT32" = "yes" ]; then + save_GL "xorg" $LIB32 + fi if [ -e $NV_CONF ]; then rm -f $NV_CONF fi - - LD_NVIDIA="${LIB}/libGL.so.$GL_VERSION" - nvidia_ldconfig $LD_NVIDIA } usage(){ echo "Usage:" - echo " --install Set up nvidia driver files" + echo " --install Set up nvidia driver files (only during pkg install)" echo " --remove Return to stock xorg files and remove all symlinks" echo " --help Show this help message" } if [ "$1" = '--install' ]; then - ROOT="/" - CWD=$(pwd) - if [ -e "${ROOT}usr/lib64" ]; then - LIBSUFFIX="64" - else - LIBSUFFIX="" - fi - LIB="${ROOT}usr/lib${LIBSUFFIX}" - XMOD="${LIB}/xorg/modules" - XLIB="$XMOD/extensions" nvidia_install elif [ "$1" = '--remove' ]; then nvidia_remove |