summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Goldstein <cardoe@gentoo.org>2010-03-17 23:05:07 +0000
committerDoug Goldstein <cardoe@gentoo.org>2010-03-17 23:05:07 +0000
commit8e67d81ddc36147ceb20f19b58eb634168e685a1 (patch)
tree9ede8c7ea78c55d821fdf8fa44421a14e55b8b95 /x11-drivers
parentVersion bump: 7.2.402 is released (diff)
downloadhistorical-8e67d81ddc36147ceb20f19b58eb634168e685a1.tar.gz
historical-8e67d81ddc36147ceb20f19b58eb634168e685a1.tar.bz2
historical-8e67d81ddc36147ceb20f19b58eb634168e685a1.zip
add upstream's pre-release version of the 195.x.y series. Still needs to be tested on further kernels and x86 before unmasking
Package-Manager: portage-2.1.8.3/cvs/Linux x86_64
Diffstat (limited to 'x11-drivers')
-rw-r--r--x11-drivers/nvidia-drivers/ChangeLog9
-rw-r--r--x11-drivers/nvidia-drivers/Manifest12
-rw-r--r--x11-drivers/nvidia-drivers/nvidia-drivers-195.36.15.ebuild507
3 files changed, 523 insertions, 5 deletions
diff --git a/x11-drivers/nvidia-drivers/ChangeLog b/x11-drivers/nvidia-drivers/ChangeLog
index d6250a1831f5..e52b6fd1278f 100644
--- a/x11-drivers/nvidia-drivers/ChangeLog
+++ b/x11-drivers/nvidia-drivers/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for x11-drivers/nvidia-drivers
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/ChangeLog,v 1.223 2010/03/10 20:08:20 cardoe Exp $
+# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/ChangeLog,v 1.224 2010/03/17 23:05:06 cardoe Exp $
+
+*nvidia-drivers-195.36.15 (17 Mar 2010)
+
+ 17 Mar 2010; Doug Goldstein <cardoe@gentoo.org>
+ +nvidia-drivers-195.36.15.ebuild:
+ add upstream's pre-release version of the 195.x.y series. Still needs to
+ be tested on further kernels and x86 before unmasking
10 Mar 2010; Doug Goldstein <cardoe@gentoo.org>
-nvidia-drivers-71.86.09.ebuild, -nvidia-drivers-96.43.13.ebuild,
diff --git a/x11-drivers/nvidia-drivers/Manifest b/x11-drivers/nvidia-drivers/Manifest
index 4d94f540597f..7a93f740b950 100644
--- a/x11-drivers/nvidia-drivers/Manifest
+++ b/x11-drivers/nvidia-drivers/Manifest
@@ -20,6 +20,7 @@ DIST NVIDIA-FreeBSD-x86-185.18.36.tar.gz 19245550 RMD160 9fc751dca64c96fa3c3d54b
DIST NVIDIA-FreeBSD-x86-190.42.tar.gz 20092575 RMD160 862f6f4fa3ebd5f09b216f2e959e3c0866440963 SHA1 1f3dd0a618d9703d4b7ab87603b002880b561fc3 SHA256 7512f1ce6a0d7202422be25ca9cb11e63f70e9097b048f2bfc6cc5d83598e9df
DIST NVIDIA-FreeBSD-x86-190.53.tar.gz 20134738 RMD160 3ee6e5dafba9c8a12102c60af11b89311b0aa206 SHA1 73b2227f94be32257506b573213d39aaf80617da SHA256 583c5726ca6f35f34aa68a2c5a1ef609dc808057aa88c3c000702d82ca60ef29
DIST NVIDIA-FreeBSD-x86-195.30.tar.gz 14178989 RMD160 7057042c2e21108e7e7cb8ec825582e6a0f15a4f SHA1 32a79c7ccac5fa5311d839f20b73d202a022205f SHA256 0c8e7519b5cbafae4eef68f93e9a662678582b6dd0313f553ab960beacc7d64e
+DIST NVIDIA-FreeBSD-x86-195.36.15.tar.gz 14539561 RMD160 1b340f920d76ab9060ae910130991aac1ecb535b SHA1 a6d93093c18ef60f8ffcc784991da469df0d43e2 SHA256 c5a762fdd4914429c2205259072f2df53c1be6db44bea4dcc336200e4227e33a
DIST NVIDIA-FreeBSD-x86-96.43.14.tar.gz 11841802 RMD160 c7abb4a4a806288ffa0fc531fad5ba74129ae185 SHA1 d5072365ebd8cd1a9ce0eeac03f8a1213ca37d2f SHA256 5f68d2e4b7b11a6390cfd8f2f4ee0ae594d7a833f65c1bd66219e1440c5ec945
DIST NVIDIA-FreeBSD-x86-96.43.16.tar.gz 11842453 RMD160 c52b6c99b4745869d7f1de80009edbd57df52fc9 SHA1 fc74c5a65e69bcb50b1f9467f435f8001970b2a3 SHA256 38bf334284dc600d92d8436333c98d5577e34d69456ed71f1cccc75caa6dffcd
DIST NVIDIA-Linux-x86-173.14.22-pkg0.run 12262547 RMD160 8fd540c277994caa6c7f0851f603f55c37e05440 SHA1 eb12529b586edb2e596054bef0701ae55eda014f SHA256 7e357a475771f538c01bd14776e7c43848a5ae3e30198f2173b10fb0a5d8023d
@@ -29,6 +30,7 @@ DIST NVIDIA-Linux-x86-185.18.36-pkg0.run 14146513 RMD160 ec8f2a4f44bf89304f6ab53
DIST NVIDIA-Linux-x86-190.42-pkg0.run 14696051 RMD160 9876e63299fd1f87e6f23939d42985277c325bc8 SHA1 c2b20032160f4b5803a04a1bf7bb67a200516a51 SHA256 e851b5daac4fa1c2ab1bdb86c967eaae6b5cfebc10529d2041a4c087b91b9271
DIST NVIDIA-Linux-x86-190.53-pkg0.run 14720222 RMD160 431efebaaf4d7a677df9bb3618d81210cd9e54eb SHA1 d8865bcaeb7f4c8c470828a3ed7dffb1bbc7a4eb SHA256 e9a985d485bbba11bf130a393a426f0eacd939e94705660d2b39ee8f1a25f57a
DIST NVIDIA-Linux-x86-195.30-pkg0.run 24215361 RMD160 2bd3435a1529a820d207651519323fcbe10555da SHA1 ffccb94f8ba136269b4ba87e3463fd86fbe83869 SHA256 67d4681c80e7586cf515b96fde25f5a837dfa6e685ea2e3ac5607f3a582ef69d
+DIST NVIDIA-Linux-x86-195.36.15-pkg0.run 24602393 RMD160 675f3c44854a41c46ece170dbc301c655d9b5bcb SHA1 347462fb17b63cdbb2d0a80f20e5051c89675c7a SHA256 ad2047cba2a2c446671223bf56897be537d4c106f58becc4e1f1ce39ab8c4c72
DIST NVIDIA-Linux-x86-71.86.11-pkg0.run 5275754 RMD160 efe88c673bc3ba665419fd63404aba7858a54993 SHA1 a7d67c9f054fe3fb5072d49ca799e21b030ebe85 SHA256 75a1471eee07c5ec5cec894bf5d331b4d578adb52b6ba7bbec5fe141f061134b
DIST NVIDIA-Linux-x86-96.43.14-pkg0.run 8440560 RMD160 7c8769bbaddbab31d24c852a8ee832639fc6545a SHA1 5764bb2d88a529f4478f867e4c5a67ab4c2bf5c6 SHA256 7906f34371f06ca8deb977e1e9c321b1687e0db3fecf98e1ba7bc0779b8c236d
DIST NVIDIA-Linux-x86-96.43.16-pkg0.run 8441195 RMD160 3d1b09b87013d765e0fc602b9fe77aa96e650e70 SHA1 f17ff6c4862ba06b2208eb18e46c323927db65eb SHA256 243e458ccaf898c49794030cbbc59a0d740a4cefb2891ecc5721f6db79088ced
@@ -39,6 +41,7 @@ DIST NVIDIA-Linux-x86_64-185.18.36-pkg2.run 22245788 RMD160 0ffbc35dd13d2ccff87f
DIST NVIDIA-Linux-x86_64-190.42-pkg2.run 23045797 RMD160 8858aaf1c089a6ad514d68c70db9dac312a3b17c SHA1 cf0a7a8a79cd77ad1363f0568e46866fa528e06f SHA256 3e95f80cbf388a03f0052efdb02cff87e201470c890edead8755fbe7b3368060
DIST NVIDIA-Linux-x86_64-190.53-pkg2.run 23111088 RMD160 7753b1a624a78e8c96ed7442157b8bfbdf1066bd SHA1 a80402aaaccae2d9ea5a974d837885e0d717ef11 SHA256 9e3d74e349767bbd1a87c19e082efe3a378e1bc2273b333ee8b1cc00254557fa
DIST NVIDIA-Linux-x86_64-195.30-pkg2.run 41604498 RMD160 48b80c01c4472346b9dd4468ad25df0396a66a01 SHA1 f396da8264f17b363f3fed87881fde51c61dc6fc SHA256 5ef42e90ca2c24a2386705e6db5922579ac8f969b433bc280edf6cfd63ac4735
+DIST NVIDIA-Linux-x86_64-195.36.15-pkg2.run 42058835 RMD160 f38daaeca7d734cdc8b7077e7b940061aec8751c SHA1 ba7d3da7e18a1f82131b67d0419c8809af8dd55f SHA256 01e3f50f422a91432085560088b1958596e7df28c486d3b74a3782c013e11be8
DIST NVIDIA-Linux-x86_64-71.86.11-pkg2.run 8390675 RMD160 5ce5f01f70901e9fa711d1ef5d0e20bd471d9af5 SHA1 92364b06bf9aad89b6be351ed23ed316a6cd2515 SHA256 fccfd8f017820599e7a29443d65d990a2d083479c7ed980249cc0d37ca5cfba7
DIST NVIDIA-Linux-x86_64-96.43.14-pkg2.run 12335444 RMD160 acb51a655176459067d0e21abe56817bc312a593 SHA1 48e63fa012e9e6240319bc2713af3b1e900375dc SHA256 39095e16edc8db19b2c5c38a97f383445a0930e76b74185bc9e3527dbb2cccfd
DIST NVIDIA-Linux-x86_64-96.43.16-pkg2.run 12337604 RMD160 fd7c586b53ff0b19034f8ef24dd24bec41940136 SHA1 b06a13d23565966821061c8d7cd1a636079ed1d8 SHA256 476538ffc3f7a5e964c7449d5242b0a684c95013d6fb1f5baa2324ef34aa5a73
@@ -50,15 +53,16 @@ EBUILD nvidia-drivers-190.42-r3.ebuild 15282 RMD160 ff418b19939fa0713d7936fdb59c
EBUILD nvidia-drivers-190.53-r1.ebuild 15479 RMD160 7f761296c196d4e4775dc67662d1845c81439e1a SHA1 73bfc73a92a7b053917359507276128bfc8efceb SHA256 2ac46e8e0ed83858b17ca93a2e9bae382b5c219e7c0179359e7077c90287841e
EBUILD nvidia-drivers-190.53.ebuild 15433 RMD160 9c022ae67a85daa45f44f276c94c75a5119261a4 SHA1 10d2d4f25b5ebd6271541e0d0d7872c7df6c346a SHA256 0e73c7d4ee5863977abb00f5b4354ee56e15dea0e9289d2eacdefc0413243634
EBUILD nvidia-drivers-195.30.ebuild 15598 RMD160 fedc138e6c200cfe810cec81fd346168d2f09da8 SHA1 252a43050c78afe4d77281eea38f2ad7715151c7 SHA256 2fb38cb81fe6e43eb42e231c8eaf9354fe402ef94e098d9c864b838ac16a6706
+EBUILD nvidia-drivers-195.36.15.ebuild 15687 RMD160 6434069c97b748eb44f908ad8213bfb84adbf727 SHA1 f1bf4a2fa81b79954b4145034e4227c2df775dc1 SHA256 6323bfa9698071a1e0c460b2c9acfc2cf513da78a65cbe6ce047176c16680a6f
EBUILD nvidia-drivers-71.86.11.ebuild 14141 RMD160 e1ca921a6dc2381be5acf05afa3933129feaaad1 SHA1 f71d5bf4a065ae475d0f4ae48d1b1cac802a1502 SHA256 7eab9ddf9cd45b876d4fd57cd204edbb6080261306a1804220b5ef808b64cd64
EBUILD nvidia-drivers-96.43.14.ebuild 15370 RMD160 b14c286fc0eba4066ac78f3603223f404d3c293f SHA1 9526821a410c553c26e41f610502297b12bcd330 SHA256 05f4a3bab44153cef7c0eb09e8dbdcaca73c3391eb7c18a2a47ccd798cbd8255
EBUILD nvidia-drivers-96.43.16.ebuild 15370 RMD160 3cca3242c024470a3b4ea80c74a676a477a96fde SHA1 8d1cd290a0ac263e311fd2b8755cff834e16c62a SHA256 8fd4fa32f1067998b1a711f00c3e3c2bf4752e5c91575e1cd04e7fc1f5d7d1f3
-MISC ChangeLog 49582 RMD160 4562284daa72f5008fea97cc729ae3c3f73432b7 SHA1 4f8fe8cf3d1409c44e4615b8b9356a235ed9bf76 SHA256 813611285147012298de85fdbb5650048ce98aab5efeb80bf0115f54edcf785c
+MISC ChangeLog 49841 RMD160 b758bc7292106d4a7ba5d6ad51837ef3c52a2cd9 SHA1 0c32586ea8d9ccde5fa29a785c66aeb95405a8de SHA256 1be16044d555fe4af96dedc28c1f982f229cc4495ac45068ffa8c4b4cb761dab
MISC metadata.xml 608 RMD160 69923c951a3b11d3632338cd673430c1335f78cd SHA1 febe635634c122bf9fb5fd83fd486ab5a25282b3 SHA256 6b13dc244ff827b23a6f1de01eef3a7f607917573fb36b7316a1a629c78cc6bd
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)
-iEYEARECAAYFAkuX/DoACgkQoeSe8B0zEfx0aACdGTt2bsCVyxRdImom//3Ox3LQ
-mnMAn0aYGvgN5tQqNijRSO/wfXjTWxvq
-=eelI
+iEYEARECAAYFAkuhYCwACgkQoeSe8B0zEfxFLwCeMiI9pGxVc7DEMuwmAxShkVQu
+DyAAnR9C1yeX1HmqeyTMWn/6dCVLUJCt
+=4gFQ
-----END PGP SIGNATURE-----
diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-195.36.15.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-195.36.15.ebuild
new file mode 100644
index 000000000000..b95eb738c3eb
--- /dev/null
+++ b/x11-drivers/nvidia-drivers/nvidia-drivers-195.36.15.ebuild
@@ -0,0 +1,507 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/nvidia-drivers-195.36.15.ebuild,v 1.1 2010/03/17 23:05:07 cardoe Exp $
+
+EAPI="2"
+
+inherit eutils multilib versionator linux-mod flag-o-matic nvidia-driver
+
+X86_NV_PACKAGE="NVIDIA-Linux-x86-${PV}"
+AMD64_NV_PACKAGE="NVIDIA-Linux-x86_64-${PV}"
+X86_FBSD_NV_PACKAGE="NVIDIA-FreeBSD-x86-${PV}"
+
+DESCRIPTION="NVIDIA X11 driver and GLX libraries"
+HOMEPAGE="http://www.nvidia.com/"
+SRC_URI="x86? ( ftp://download.nvidia.com/XFree86/Linux-x86/${PV}/${X86_NV_PACKAGE}-pkg0.run )
+ amd64? ( ftp://download.nvidia.com/XFree86/Linux-x86_64/${PV}/${AMD64_NV_PACKAGE}-pkg2.run )
+ x86-fbsd? ( ftp://download.nvidia.com/freebsd/${PV}/${X86_FBSD_NV_PACKAGE}.tar.gz )"
+
+LICENSE="NVIDIA"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
+IUSE="acpi custom-cflags gtk multilib kernel_linux"
+RESTRICT="strip"
+EMULTILIB_PKG="true"
+
+COMMON="<x11-base/xorg-server-1.7.99
+ kernel_linux? ( >=sys-libs/glibc-2.6.1 )
+ multilib? ( app-emulation/emul-linux-x86-xlibs )
+ >=app-admin/eselect-opengl-1.0.9"
+DEPEND="${COMMON}
+ kernel_linux? ( virtual/linux-sources )"
+RDEPEND="${COMMON}
+ kernel_linux? ( virtual/modutils )
+ acpi? ( sys-power/acpid )"
+PDEPEND=">=x11-libs/libvdpau-0.3-r1
+ gtk? ( media-video/nvidia-settings )"
+
+QA_TEXTRELS_x86="usr/lib/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/lib/xorg/modules/drivers/nvidia_drv.so
+ usr/lib/libcuda.so.${PV}
+ usr/lib/libnvidia-cfg.so.${PV}
+ usr/lib/libvdpau_nvidia.so.${PV}
+ usr/lib/libOpenCL.so.1.0.0
+ usr/lib/libnvidia-compiler.so.${PV}"
+
+QA_TEXTRELS_x86_fbsd="boot/modules/nvidia.ko
+ usr/lib/opengl/nvidia/lib/libGL.so.1
+ usr/lib/opengl/nvidia/lib/libGLcore.so.1
+ usr/lib/libnvidia-cfg.so.1
+ usr/lib/opengl/nvidia/extensions/libglx.so.1
+ usr/lib/xorg/modules/drivers/nvidia_drv.so"
+
+QA_TEXTRELS_amd64="usr/lib32/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib32/libcuda.so.${PV}
+ usr/lib32/libvdpau_nvidia.so.${PV}
+ usr/lib32/libOpenCL.so.1.0.0
+ usr/lib32/libnvidia-compiler.so.${PV}"
+
+QA_EXECSTACK_x86="usr/lib/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/lib/libXvMCNVIDIA.a:NVXVMC.o
+ usr/lib/libnvidia-compiler.so.${PV}"
+
+QA_EXECSTACK_amd64="usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib32/libnvidia-compiler.so.${PV}
+ usr/lib64/libnvidia-compiler.so.${PV}
+ usr/lib64/libXvMCNVIDIA.a:NVXVMC.o
+ usr/lib64/libnvidia-cfg.so.${PV}
+ usr/lib64/libvdpau_nvidia.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib64/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/bin/nvidia-smi
+ usr/bin/nvidia-xconfig"
+
+QA_WX_LOAD_x86="usr/lib/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/lib/libXvMCNVIDIA.a"
+
+QA_WX_LOAD_amd64="usr/lib32/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib64/opengl/nvidia/extensions/libglx.so.${PV}"
+
+QA_SONAME_x86="usr/lib/libnvidia-compiler.so.${PV}"
+
+QA_SONAME_amd64="usr/lib64/libnvidia-compiler.so.${PV}
+ usr/lib32/libnvidia-compiler.so.${PV}"
+
+QA_DT_HASH_amd64="usr/lib32/libcuda.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib32/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib32/libvdpau_nvidia.so.${PV}
+ usr/lib64/libXvMCNVIDIA.so.${PV}
+ usr/lib64/libcuda.so.${PV}
+ usr/lib64/libnvidia-cfg.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib64/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib64/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/lib64/xorg/modules/drivers/nvidia_drv.so
+ usr/lib64/libvdpau_nvidia.so.${PV}
+ usr/bin/nvidia-smi
+ usr/bin/nvidia-xconfig"
+
+QA_DT_HASH_x86="usr/lib/libcuda.so.${PV}
+ usr/lib/libnvidia-cfg.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGLcore.so.${PV}
+ usr/lib/opengl/nvidia/lib/libGL.so.${PV}
+ usr/lib/opengl/nvidia/lib/libnvidia-tls.so.${PV}
+ usr/lib/opengl/nvidia/extensions/libglx.so.${PV}
+ usr/lib/xorg/modules/drivers/nvidia_drv.so
+ usr/lib/libXvMCNVIDIA.so.${PV}
+ usr/lib/libvdpau_nvidia.so.${PV}
+ usr/bin/nvidia-smi
+ usr/bin/nvidia-xconfig"
+
+if use x86; then
+ PKG_V="-pkg0"
+ NV_PACKAGE="${X86_NV_PACKAGE}"
+elif use amd64; then
+ PKG_V="-pkg2"
+ NV_PACKAGE="${AMD64_NV_PACKAGE}"
+elif use x86-fbsd; then
+ PKG_V=""
+ NV_PACKAGE="${X86_FBSD_NV_PACKAGE}"
+fi
+
+S="${WORKDIR}/${NV_PACKAGE}${PKG_V}"
+
+mtrr_check() {
+ ebegin "Checking for MTRR support"
+ linux_chkconfig_present MTRR
+ eend $?
+
+ if [[ $? -ne 0 ]] ; then
+ eerror "Please enable MTRR support in your kernel config, found at:"
+ eerror
+ eerror " Processor type and features"
+ eerror " [*] MTRR (Memory Type Range Register) support"
+ eerror
+ eerror "and recompile your kernel ..."
+ die "MTRR support not detected!"
+ fi
+}
+
+lockdep_check() {
+ if linux_chkconfig_present LOCKDEP; then
+ eerror "You've enabled LOCKDEP -- lock tracking -- in the kernel."
+ eerror "Unfortunately, this option exports the symbol 'lockdep_init_map' as GPL-only"
+ eerror "which will prevent ${P} from compiling."
+ eerror "Please make sure the following options have been unset:"
+ eerror " Kernel hacking --->"
+ eerror " [ ] Lock debugging: detect incorrect freeing of live locks"
+ eerror " [ ] Lock debugging: prove locking correctness"
+ eerror " [ ] Lock usage statistics"
+ eerror "in 'menuconfig'"
+ die "LOCKDEP enabled"
+ fi
+}
+
+pkg_setup() {
+ # try to turn off distcc and ccache for people that have a problem with it
+ export DISTCC_DISABLE=1
+ export CCACHE_DISABLE=1
+
+ if use amd64 && has_multilib_profile && [ "${DEFAULT_ABI}" != "amd64" ]; then
+ eerror "This ebuild doesn't currently support changing your default abi."
+ die "Unexpected \${DEFAULT_ABI} = ${DEFAULT_ABI}"
+ fi
+
+ if use kernel_linux; then
+ linux-mod_pkg_setup
+ MODULE_NAMES="nvidia(video:${S}/usr/src/nv)"
+ BUILD_PARAMS="IGNORE_CC_MISMATCH=yes V=1 SYSSRC=${KV_DIR} \
+ SYSOUT=${KV_OUT_DIR} HOST_CC=$(tc-getBUILD_CC)"
+ mtrr_check
+ lockdep_check
+ fi
+
+ # On BSD userland it wants real make command
+ use userland_BSD && MAKE="$(get_bmake)"
+
+ export _POSIX2_VERSION="199209"
+
+ # Since Nvidia ships 3 different series of drivers, we need to give the user
+ # some kind of guidance as to what version they should install. This tries
+ # to point the user in the right direction but can't be perfect. check
+ # nvidia-driver.eclass
+ nvidia-driver-check-warning
+
+ # set variables to where files are in the package structure
+ if use kernel_FreeBSD; then
+ NV_DOC="${S}/doc"
+ NV_EXEC="${S}/obj"
+ NV_LIB="${S}/obj"
+ NV_SRC="${S}/src"
+ NV_MAN="${S}/x11/man"
+ NV_X11="${S}/obj"
+ NV_X11_DRV="${NV_X11}"
+ NV_X11_EXT="${NV_X11}"
+ NV_SOVER=1
+ elif use kernel_linux; then
+ NV_DOC="${S}/usr/share/doc"
+ NV_EXEC="${S}/usr/bin"
+ NV_LIB="${S}/usr/lib"
+ NV_SRC="${S}/usr/src/nv"
+ NV_MAN="${S}/usr/share/man/man1"
+ NV_X11="${S}/usr/X11R6/lib"
+ NV_X11_DRV="${NV_X11}/modules/drivers"
+ NV_X11_EXT="${NV_X11}/modules/extensions"
+ NV_SOVER=${PV}
+ else
+ die "Could not determine proper NVIDIA package"
+ fi
+}
+
+src_unpack() {
+ if use kernel_linux && kernel_is lt 2 6 7; then
+ echo
+ ewarn "Your kernel version is ${KV_MAJOR}.${KV_MINOR}.${KV_PATCH}"
+ ewarn "This is not officially supported for ${P}. It is likely you"
+ ewarn "will not be able to compile or use the kernel module."
+ ewarn "It is recommended that you upgrade your kernel to a version >= 2.6.7"
+ echo
+ ewarn "DO NOT file bug reports for kernel versions less than 2.6.7 as they will be ignored."
+ fi
+
+ if ! use x86-fbsd; then
+ mkdir "${S}"
+ cd "${S}"
+ unpack_makeself
+ else
+ unpack ${A}
+ fi
+}
+
+src_prepare() {
+ # Please add a brief description for every added patch
+ use x86-fbsd && cd doc
+
+ # Use the correct defines to make gtkglext build work
+ epatch "${FILESDIR}"/NVIDIA_glx-defines.patch
+ # Use some more sensible gl headers and make way for new glext.h
+ epatch "${FILESDIR}"/NVIDIA_glx-glheader.patch
+
+ # Add support for the 'x86' unified kernel arch in conftest.sh
+ epatch "${FILESDIR}"/195.30-unified-arch.patch
+
+ if use kernel_linux; then
+ # Quiet down warnings the user does not need to see
+ sed -i \
+ -e 's:-Wpointer-arith::g' \
+ -e 's:-Wsign-compare::g' \
+ "${NV_SRC}"/Makefile.kbuild
+
+ # If you set this then it's your own fault when stuff breaks :)
+ use custom-cflags && sed -i "s:-O:${CFLAGS}:" "${NV_SRC}"/Makefile.*
+
+ # If greater than 2.6.5 use M= instead of SUBDIR=
+ convert_to_m "${NV_SRC}"/Makefile.kbuild
+ fi
+}
+
+src_compile() {
+ # This is already the default on Linux, as there's no toplevel Makefile, but
+ # on FreeBSD there's one and triggers the kernel module build, as we install
+ # it by itself, pass this.
+
+ cd "${NV_SRC}"
+ if use x86-fbsd; then
+ MAKE="$(get_bmake)" CFLAGS="-Wno-sign-compare" emake CC="$(tc-getCC)" \
+ LD="$(tc-getLD)" LDFLAGS="$(raw-ldflags)" || die
+ elif use kernel_linux; then
+ linux-mod_src_compile
+ fi
+}
+
+src_install() {
+ if use kernel_linux; then
+ linux-mod_src_install
+
+ VIDEOGROUP="$(egetent group video | cut -d ':' -f 3)"
+ if [ -z "$VIDEOGROUP" ]; then
+ eerror "Failed to determine the video group gid."
+ die "Failed to determine the video group gid."
+ fi
+
+ # Add the aliases
+ [ -f "${FILESDIR}/nvidia-169.07" ] || die "nvidia missing in FILESDIR"
+ sed -e 's:PACKAGE:'${PF}':g' \
+ -e 's:VIDEOGID:'${VIDEOGROUP}':' "${FILESDIR}"/nvidia-169.07 > \
+ "${WORKDIR}"/nvidia
+ insinto /etc/modprobe.d
+ newins "${WORKDIR}"/nvidia nvidia.conf || die
+ elif use x86-fbsd; then
+ insinto /boot/modules
+ doins "${WORKDIR}/${NV_PACKAGE}/src/nvidia.kld" || die
+
+ exeinto /boot/modules
+ doexe "${WORKDIR}/${NV_PACKAGE}/src/nvidia.ko" || die
+ fi
+
+ # NVIDIA kernel <-> userspace driver config lib
+ dolib.so ${NV_LIB}/libnvidia-cfg.so.${NV_SOVER} || \
+ die "failed to install libnvidia-cfg"
+
+ # Xorg DDX driver
+ insinto /usr/$(get_libdir)/xorg/modules/drivers
+ doins ${NV_X11_DRV}/nvidia_drv.so || die "failed to install nvidia_drv.so"
+
+ # Xorg GLX driver
+ insinto /usr/$(get_libdir)/opengl/nvidia/extensions
+ doins ${NV_X11_EXT}/libglx.so.${NV_SOVER} || \
+ die "failed to install libglx.so"
+ dosym /usr/$(get_libdir)/opengl/nvidia/extensions/libglx.so.${NV_SOVER} \
+ /usr/$(get_libdir)/opengl/nvidia/extensions/libglx.so || \
+ die "failed to create libglx.so symlink"
+
+ # XvMC driver
+ dolib.a ${NV_X11}/libXvMCNVIDIA.a || \
+ die "failed to install libXvMCNVIDIA.so"
+ dolib.so ${NV_X11}/libXvMCNVIDIA.so.${NV_SOVER} || \
+ die "failed to install libXvMCNVIDIA.so"
+ dosym libXvMCNVIDIA.so.${NV_SOVER} /usr/$(get_libdir)/libXvMCNVIDIA.so || \
+ die "failed to create libXvMCNVIDIA.so symlink"
+
+ # CUDA headers (driver to come)
+ if use kernel_linux; then
+ dodir /usr/include/cuda
+ insinto /usr/include/cuda
+ doins usr/include/cuda/*.h || die "failed to install cuda headers"
+ fi
+
+ # OpenCL headers (driver to come)
+ if [[ -d ${S}/usr/include/CL ]]; then
+ dodir /usr/include/CL
+ insinto /usr/include/CL
+ doins usr/include/CL/*.h || die "failed to install OpenCL headers"
+ fi
+
+ # Documentation
+ dodoc ${NV_DOC}/XF86Config.sample
+ dohtml ${NV_DOC}/html/*
+ if use x86-fbsd; then
+ dodoc "${NV_DOC}/README"
+ doman "${NV_MAN}/nvidia-xconfig.1"
+ else
+ # Docs
+ newdoc "${NV_DOC}/README.txt" README
+ dodoc "${NV_DOC}/NVIDIA_Changelog"
+ doman "${NV_MAN}/nvidia-smi.1.gz"
+ doman "${NV_MAN}/nvidia-xconfig.1.gz"
+ fi
+
+ # Helper Apps
+ dobin ${NV_EXEC}/nvidia-xconfig || die
+ dobin ${NV_EXEC}/nvidia-bug-report.sh || die
+ if use kernel_linux; then
+ dobin ${NV_EXEC}/nvidia-smi || die
+ fi
+
+ if has_multilib_profile ; then
+ local OABI=${ABI}
+ for ABI in $(get_install_abis) ; do
+ src_install-libs
+ done
+ ABI=${OABI}
+ unset OABI
+ else
+ src_install-libs
+ fi
+
+ is_final_abi || die "failed to iterate through all ABIs"
+}
+
+# Install nvidia library:
+# the first parameter is the place where to install it
+# the second parameter is the base name of the library
+# the third parameter is the provided soversion
+donvidia() {
+ dodir $1
+ exeinto $1
+
+ libname=$(basename $2)
+
+ doexe $2.$3 || die "failed to install $2"
+ dosym ${libname}.$3 $1/${libname} || die "failed to symlink $2"
+ [[ $3 != "1" ]] && dosym ${libname}.$3 $1/${libname}.1
+}
+
+src_install-libs() {
+ local inslibdir=$(get_libdir)
+ local NV_ROOT="/usr/${inslibdir}/opengl/nvidia"
+ local libdir= sover=
+
+ if use kernel_linux; then
+ if has_multilib_profile && [[ ${ABI} == "x86" ]] ; then
+ libdir=usr/lib32
+ else
+ libdir=usr/lib
+ fi
+ sover=${PV}
+ else
+ libdir=obj
+ # on FreeBSD it has just .1 suffix
+ sover=1
+ fi
+
+ # The GLX libraries
+ donvidia ${NV_ROOT}/lib ${libdir}/libGL.so ${sover}
+ donvidia ${NV_ROOT}/lib ${libdir}/libGLcore.so ${sover}
+ if use x86-fbsd; then
+ donvidia ${NV_ROOT}/lib ${libdir}/libnvidia-tls.so ${sover}
+ else
+ donvidia ${NV_ROOT}/lib ${libdir}/tls/libnvidia-tls.so ${sover}
+ fi
+
+ #cuda
+ if [[ -f ${libdir}/libcuda.so.${sover} ]]; then
+ dolib.so ${libdir}/libcuda.so.${sover}
+ [[ "${sover}" != "1" ]] && dosym libcuda.so.${sover} /usr/${inslibdir}/libcuda.so.1
+ dosym libcuda.so.1 /usr/${inslibdir}/libcuda.so
+ fi
+
+ #vdpau
+ if [[ -f ${libdir}/vdpau/libvdpau_nvidia.so.${sover} ]]; then
+ insinto /usr/${inslibdir}/vdpau
+ dolib.so ${libdir}/vdpau/libvdpau_nvidia.so.${sover}
+ dosym libvdpau_nvidia.so.${sover} /usr/${inslibdir}/libvdpau_nvidia.so.1
+ fi
+
+ # OpenCL
+ if [[ -f ${libdir}/libOpenCL.so.1.0.0 ]]; then
+ dolib.so ${libdir}/libnvidia-compiler.so.${sover}
+ [[ "${sover}" != "1" ]] && dosym libnvidia-compiler.so.${sover} /usr/${inslibdir}/libnvidia-compiler.so.1
+ dosym libnvidia-compiler.so.1 /usr/${inslibdir}/libnvidia-compiler.so
+
+ dolib.so ${libdir}/libOpenCL.so.1.0.0
+ dosym libOpenCL.so.1.0.0 /usr/${inslibdir}/libOpenCL.so.1
+ dosym libOpenCL.so.1 /usr/${inslibdir}/libOpenCL.so
+ fi
+}
+
+pkg_preinst() {
+ if use kernel_linux; then
+ linux-mod_pkg_postinst
+ fi
+
+ # Clean the dynamic libGL stuff's home to ensure
+ # we dont have stale libs floating around
+ if [ -d "${ROOT}"/usr/lib/opengl/nvidia ] ; then
+ rm -rf "${ROOT}"/usr/lib/opengl/nvidia/*
+ fi
+ # Make sure we nuke the old nvidia-glx's env.d file
+ if [ -e "${ROOT}"/etc/env.d/09nvidia ] ; then
+ rm -f "${ROOT}"/etc/env.d/09nvidia
+ fi
+}
+
+pkg_postinst() {
+ if use kernel_linux; then
+ linux-mod_pkg_postinst
+ fi
+
+ # Switch to the nvidia implementation
+ eselect opengl set --use-old nvidia
+
+ echo
+ elog "You must be in the video group to use the NVIDIA device"
+ elog "For more info, read the docs at"
+ elog "http://www.gentoo.org/doc/en/nvidia-guide.xml#doc_chap3_sect6"
+ elog
+
+ elog "This ebuild installs a kernel module and X driver. Both must"
+ elog "match explicitly in their version. This means, if you restart"
+ elog "X, you must modprobe -r nvidia before starting it back up"
+ elog
+
+ elog "To use the NVIDIA GLX, run \"eselect opengl set nvidia\""
+ elog
+ elog "NVIDIA has requested that any bug reports submitted have the"
+ elog "output of /usr/bin/nvidia-bug-report.sh included."
+ elog
+ elog "To work with compiz, you must enable the AddARGBGLXVisuals option."
+ elog
+ elog "If you are having resolution problems, try disabling DynamicTwinView."
+ echo
+}
+
+pkg_postrm() {
+ if use kernel_linux; then
+ linux-mod_pkg_postrm
+ fi
+ eselect opengl set --use-old xorg-x11
+}