[pkg-nvidia-devel] r818 - in /packages/nvidia-graphics-drivers/trunk/debian: changelog nvidia-glx.README.Debian nvidia-glx.init.in nvidia-glx.postinst rules
rra at users.alioth.debian.org
rra at users.alioth.debian.org
Sun Apr 25 04:03:45 UTC 2010
Author: rra
Date: Sun Apr 25 04:03:42 2010
New Revision: 818
URL: http://svn.debian.org/wsvn/pkg-nvidia/?sc=1&rev=818
Log:
Remove obsolete handling of TLS links
* TLS cleanup: Debian only ships TLS enabled 2.6 kernels, so remove all
dynamic TLS checking and symlink updating code
- nvidia-glx.README.Debian: don't talk about TLS any longer
- debian/nvidia-glx.init: remove (inactive) tls symlink adjusting code
- debian/nvidia-glx.default: remove, no longer needed
- nvidia-glx.postinst: remove /etc/default/nvidia-glx on upgrades
- stop shipping /usr/lib/nvidia/tls_test*
Modified:
packages/nvidia-graphics-drivers/trunk/debian/changelog
packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.README.Debian
packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.init.in
packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.postinst
packages/nvidia-graphics-drivers/trunk/debian/rules
Modified: packages/nvidia-graphics-drivers/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers/trunk/debian/changelog?rev=818&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers/trunk/debian/changelog (original)
+++ packages/nvidia-graphics-drivers/trunk/debian/changelog Sun Apr 25 04:03:42 2010
@@ -22,6 +22,13 @@
* debian/control:
- drop versioned Depends/Build-Depends satisfied in lenny
- drop Conflicts/Replaces for packages existing before lenny only
+ * TLS cleanup: Debian only ships TLS enabled 2.6 kernels, so remove all
+ dynamic TLS checking and symlink updating code
+ - nvidia-glx.README.Debian: don't talk about TLS any longer
+ - debian/nvidia-glx.init: remove (inactive) tls symlink adjusting code
+ - debian/nvidia-glx.default: remove, no longer needed
+ - nvidia-glx.postinst: remove /etc/default/nvidia-glx on upgrades
+ - stop shipping /usr/lib/nvidia/tls_test*
-- Russ Allbery <rra at debian.org> Sat, 24 Apr 2010 20:35:20 -0700
Modified: packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.README.Debian
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.README.Debian?rev=818&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.README.Debian (original)
+++ packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.README.Debian Sun Apr 25 04:03:42 2010
@@ -7,34 +7,6 @@
Welcome to the Debian NVIDIA packages. This document has notes on the
X Server and GL libraries of the NVIDIA driver offering.
-
-
-A Note about Thread Local Storage (TLS):
-----------------------------------------
-Under 2.6.x kernels a new TLS method is used and different libraries are
-required. NVIDIA provides these libraries and at boot time (via
-/etc/init.d/nvidia-glx) a test is performed on your system to see if
-your require these extra libraries. Having the TLS libraries installed
-(in /usr/lib/tls and libglx.so) running under a 2.4.x kernel will cause
-problems when running GL applications. Likewise, not having these libraries
-installed under 2.6.x might prevent X from starting at all.
-
-Simple Explanation:
-To switch back and forth between the two systems simply run:
-
- /etc/init.d/nvidia-glx start
-
- This is run automatically at boot time.
-
-To force a certain setting (e.g. you may have a 2.4 kernel patched for
-NPTL) place USE_TLS=1 in /etc/defaults/nvidia-glx for using the nvidia tls
-libraries. USE_TLS=0 for not using tls libraries. This isn't normally
-necessary for most users.
-
-
-What Happens:
-Symlinks are created in /usr/lib/tls from libraries installed in
-/usr/lib/nvidia.
For any news on this package check http://people.debian.org/~rdonald and
Modified: packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.init.in
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.init.in?rev=818&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.init.in (original)
+++ packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.init.in Sun Apr 25 04:03:42 2010
@@ -6,8 +6,8 @@
# Required-Stop: $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop:
-# Short-Description: adjust nVidia TLS libraries
-# Description: adjust nVidia TLS libraries
+# Short-Description: messing around with the libGL.so symlink
+# Description: messing around with the libGL.so symlink
### END INIT INFO
@@ -20,79 +20,12 @@
. /lib/lsb/init-functions
-
-
-
-# to force usage or non-usage of TLS libs edit /etc/defaults/nvidia-glx
-[ -e /etc/default/nvidia-glx ] && . /etc/default/nvidia-glx
-
-
-
-
-
# test if /usr/lib is writable.
if [ ! -w /usr/lib ]; then
#we can't change anything so just exit.
exit 0
fi
-
-# if nothing has been specified do some guesswork
-if [ -z "$USE_TLS" ]
-then
- if [ `uname -r | cut -f 1,2 -d.` = "2.6" ] && \
- [ -x /usr/lib/nvidia/tls_test ] && \
- /usr/lib/nvidia/tls_test /usr/lib/nvidia/tls_test_dso.so
- then
- USE_TLS=1
- else
- USE_TLS=0
- fi
-fi
-
-setup_links () {
- # check if all the symlinks are in place
- if [ "$(readlink -f /usr/lib/tls/libnvidia-tls.so.1)" != /usr/lib/nvidia/libnvidia-tls.so.#VERSION# ]
- then
- echo -n "Creating NVIDIA TLS links..."
- # remove the symlinks
- rm -f /usr/lib/tls/libGL.so
- rm -f /usr/lib/tls/libGL.so.*
- rm -f /usr/lib/tls/libnvidia-tls.so
-
- rm -f /usr/lib/tls/libnvidia-tls.so.*
- rm -f /usr/lib/tls/libGL.la
-
- #remove old ones
- rm -f /usr/lib/tls/libGLcore.so.1
- rm -f /usr/lib/tls/libGLcore.so.*
- # create the symlinks
- ln -s /usr/lib/nvidia/libnvidia-tls.so.#VERSION# /usr/lib/tls/libnvidia-tls.so.#VERSION#
- # reconfigure dynamic linker run-time bindings
- ldconfig
- echo " done."
- fi
-}
-
-remove_links () {
- # check if all the symlinks are gone or correct
- if [ -e /usr/lib/tls/libnvidia-tls.so.#VERSION# \
- -o -e /usr/lib/tls/libnvidia-tls.so \
- -o -e /usr/lib/tls/libnvidia-tls.so.1 ]
- then
- echo -n "Removing NVIDIA TLS links..."
- # remove the symlinks
- rm -f /usr/lib/tls/libGL.so
- rm -f /usr/lib/tls/libGL.so.*
- rm -f /usr/lib/tls/libGL.la
- rm -f /usr/lib/tls/libGLcore.so.*
- rm -f /usr/lib/tls/libnvidia-tls.so
- rm -f /usr/lib/tls/libnvidia-tls.so.*
- # reconfigure dynamic linker run-time bindings
- ldconfig
- echo " done."
- fi
-}
case "$1" in
start|restart|reload|force-reload)
Modified: packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.postinst
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.postinst?rev=818&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.postinst (original)
+++ packages/nvidia-graphics-drivers/trunk/debian/nvidia-glx.postinst Sun Apr 25 04:03:42 2010
@@ -1,6 +1,47 @@
#!/bin/sh
set -e
+
+rm_conffile() {
+ mv_conffile "$1" "$1.dpkg-bak"
+}
+
+mv_conffile() {
+ local package='nvidia-glx'
+ local name="$1"
+ local newname="$2"
+
+ [ -e "$name" ] || return 0
+
+ local md5="$(md5sum $name | sed -e 's/ .*//')"
+ oldmd5="$(dpkg-query -W -f='${Conffiles}' $package | \
+ sed -n -e "\' $name ' { s/ obsolete$//; s/.* //; p }")"
+
+ if [ "$md5" = "$oldmd5" ]; then
+ rm -f "$name"
+ else
+ mv "$name" "$newname"
+ fi
+}
+
+case "$1" in
+ configure)
+
+ if dpkg --compare-versions "$2" lt-nl 190.53-5 ; then
+ rm_conffile /etc/default/nvidia-glx
+ fi
+
+ ;;
+
+ abort-upgrade|abort-remove|abort-deconfigure)
+ ;;
+
+ *)
+ echo "$0 called with unknown argument '$1'" >&2
+ exit 1
+ ;;
+esac
+
#make sure wfb diversion is removed
dpkg-divert --rename --remove --package nvidia-glx --divert /usr/lib/nvidia/libwfb.so.xserver-xorg-core /usr/lib/xorg/modules/libwfb.so >/dev/null || true
Modified: packages/nvidia-graphics-drivers/trunk/debian/rules
URL: http://svn.debian.org/wsvn/pkg-nvidia/packages/nvidia-graphics-drivers/trunk/debian/rules?rev=818&op=diff
==============================================================================
--- packages/nvidia-graphics-drivers/trunk/debian/rules (original)
+++ packages/nvidia-graphics-drivers/trunk/debian/rules Sun Apr 25 04:03:42 2010
@@ -225,9 +225,6 @@
install $(dirname)/usr/X11R6/lib/modules/extensions/libglx.so.${version} $(CURDIR)/debian/nvidia-glx/usr/lib/xorg/modules/extensions/
# install $(dirname)/usr/X11R6/lib/modules/libnvidia-wfb.so.${version} $(CURDIR)/debian/nvidia-glx/usr/lib/xorg/modules/
-
- install $(dirname)/usr/bin/tls_test $(CURDIR)/debian/nvidia-glx/usr/lib/nvidia
- install $(dirname)/usr/bin/tls_test_dso.so $(CURDIR)/debian/nvidia-glx/usr/lib/nvidia
if [ "$(DEB_BUILD_ARCH)" = "amd64" ] ; then \
install -D $(dirname)/usr/lib32/libGLcore.so.${version} \
More information about the Pkg-nvidia-devel
mailing list