diff options
author | Piotr Jaroszyński <peper@gentoo.org> | 2009-09-02 21:49:40 +0000 |
---|---|---|
committer | Piotr Jaroszyński <peper@gentoo.org> | 2009-09-02 21:49:40 +0000 |
commit | 30679c70d4a4566f705378a04c4ad12f46f08a9a (patch) | |
tree | 39f1e3744b835e79c6f8c98fb28ccb0b82a0a350 /x11-drivers | |
parent | Fix the ${PV} onto 4.2.1. Force - unsynced tree (diff) | |
download | gentoo-2-30679c70d4a4566f705378a04c4ad12f46f08a9a.tar.gz gentoo-2-30679c70d4a4566f705378a04c4ad12f46f08a9a.tar.bz2 gentoo-2-30679c70d4a4566f705378a04c4ad12f46f08a9a.zip |
Add 190.25.
Diffstat (limited to 'x11-drivers')
-rw-r--r-- | x11-drivers/nvidia-drivers/ChangeLog | 8 | ||||
-rw-r--r-- | x11-drivers/nvidia-drivers/Manifest | 6 | ||||
-rw-r--r-- | x11-drivers/nvidia-drivers/nvidia-drivers-190.25.ebuild | 542 |
3 files changed, 554 insertions, 2 deletions
diff --git a/x11-drivers/nvidia-drivers/ChangeLog b/x11-drivers/nvidia-drivers/ChangeLog index 2e3e0f7d1725..d0164d21ce22 100644 --- a/x11-drivers/nvidia-drivers/ChangeLog +++ b/x11-drivers/nvidia-drivers/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for x11-drivers/nvidia-drivers # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/ChangeLog,v 1.168 2009/08/29 04:21:27 jer Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/ChangeLog,v 1.169 2009/09/02 21:49:40 peper Exp $ + +*nvidia-drivers-190.25 (02 Sep 2009) + + 02 Sep 2009; Piotr Jaroszyński <peper@gentoo.org> + +nvidia-drivers-190.25.ebuild: + Add 190.25. 29 Aug 2009; Jeroen Roovers <jer@gentoo.org> nvidia-drivers-96.43.13.ebuild: diff --git a/x11-drivers/nvidia-drivers/Manifest b/x11-drivers/nvidia-drivers/Manifest index eeddb781bf47..b39d83857805 100644 --- a/x11-drivers/nvidia-drivers/Manifest +++ b/x11-drivers/nvidia-drivers/Manifest @@ -17,6 +17,7 @@ DIST NVIDIA-FreeBSD-x86-185.18.14.tar.gz 19221783 RMD160 6865a8a4c7e24f671cac52d DIST NVIDIA-FreeBSD-x86-185.18.29.tar.gz 19243110 RMD160 654fbc1eb68a8eca355d6d2e65b9bb4f5bd50834 SHA1 eeb22810298161eebf62357d12cbf77f9fc86012 SHA256 843fbb119f9cf0d624dbd1efae25caad20e26a5894c245f9b014da09a0e53bca DIST NVIDIA-FreeBSD-x86-185.18.31.tar.gz 19243864 RMD160 3e728a080fd48b3fe4d073bb02c85daf60d63dcc SHA1 3af426044022a06f66d1bfd406c9b8ed5b7c9a75 SHA256 b8e2f36d9182ce63518a9b63b9305842069a19972077099cda796774083d6e09 DIST NVIDIA-FreeBSD-x86-190.18.tar.gz 19867259 RMD160 759bf0171ea42f257367774720c678afb8e0e409 SHA1 5aded5b7f0b99afc59f3b6feb3a11c9dca22114f SHA256 1c88435ed81257e82b153b67accbe0907cd1d737a76110cf635bfd39b2c80fd3 +DIST NVIDIA-FreeBSD-x86-190.25.tar.gz 19842181 RMD160 618be25995fa809377316a17bf20e3c7668d66c7 SHA1 bece04998f4a3fa5820c8097b5620d54c8f5129c SHA256 254c9f3e8bd3d0c6397886771305726b425b8c53810bfd024a0aaedcc76b6ee1 DIST NVIDIA-FreeBSD-x86-96.43.09.tar.gz 10400444 RMD160 9569c9b51d902c214b0225b0aad615627ec944b9 SHA1 21680258aa94a1bff4a59d13de850c31743fac2a SHA256 58c041ce5be40b7837d8126ff1ea6e2932be0d189a046622faef698f1a83b50f DIST NVIDIA-FreeBSD-x86-96.43.11.tar.gz 11051460 RMD160 b3e50cb5118ea53edc9923d609f7f22478802b54 SHA1 64ff4132d325744a26f82ea85c4266799774b709 SHA256 5e17d537ae8ef4c56cb1b95c17672865a49f3aa504775e96d61a6795f6d9c26f DIST NVIDIA-FreeBSD-x86-96.43.13.tar.gz 11057193 RMD160 64c2182d2fb7b2fcb9552e7f6d23a2dfb325dc7e SHA1 c5104e3cbbd36b170c7057d1a7819e3d8cd85b69 SHA256 614396a11ab8b304c51721cd4b47fb82a5f75884ff77d3d414e0e5739835c738 @@ -29,6 +30,7 @@ DIST NVIDIA-Linux-x86-185.18.14-pkg0.run 14125083 RMD160 27b07a055ed85d6da001072 DIST NVIDIA-Linux-x86-185.18.29-pkg0.run 14141753 RMD160 7ab3c2fe47cfe8c94e98306cfbdd074313858204 SHA1 5438b0ada004dcdf67dc3c51849a98942271f713 SHA256 7a4e85160f0779e390b159685a27ed8afbbfaf44c42964e6e87d4291caedf55d DIST NVIDIA-Linux-x86-185.18.31-pkg0.run 14142691 RMD160 161f6051c63e7b3c076ad3af7dbd0d5b2f140672 SHA1 2766cfc7a656211c43e7c80a3c3dc44ae463ff3b SHA256 be9514c674a8014c06def0e619d70f7d6ae67097f39f61c6b610a9f89dff08e9 DIST NVIDIA-Linux-x86-190.18-pkg0.run 14552428 RMD160 cf9a4b89e07bf8fb1e90efbfa958b622fb0a3267 SHA1 321b3ac18eb3470c4f56afa00cdd098daae2e16d SHA256 ebaca648f912e4d0b5e8a06001f4294de0dd32be06724ad2dd2c0be75d77fe27 +DIST NVIDIA-Linux-x86-190.25-pkg0.run 14496044 RMD160 5b591bb5083f16225480406f172a8281e1ee493b SHA1 64ecec661c25a44b2a3bc6a5e3ed2e4cd217a49c SHA256 9323085d989b21665de097e36ddaf344d2e640b8a2631b1cfccb985d62356687 DIST NVIDIA-Linux-x86-71.86.07-pkg0.run 5264394 RMD160 764111fb8413452ba23ff9c6488de6974257dd84 SHA1 1c71f68b7460f0ac0a8abe07f56ea7876b0496e3 SHA256 06019159b99fd4b7f983eaf8d4f9b5b15b389d328d8606eee2bb62f1b9b9341b DIST NVIDIA-Linux-x86-71.86.09-pkg0.run 5274589 RMD160 ca2cb1d370a15328925b0e2fb8c211b57b29cf78 SHA1 c66c0859a3ff142bc2435ed00a23b7dea45c1305 SHA256 464681742bf702f1359d7477c4023a6264f68cddce6c15ce2a5657c7da9dfb1c DIST NVIDIA-Linux-x86-71.86.11-pkg0.run 5275754 RMD160 efe88c673bc3ba665419fd63404aba7858a54993 SHA1 a7d67c9f054fe3fb5072d49ca799e21b030ebe85 SHA256 75a1471eee07c5ec5cec894bf5d331b4d578adb52b6ba7bbec5fe141f061134b @@ -44,6 +46,7 @@ DIST NVIDIA-Linux-x86_64-185.18.14-pkg2.run 22211696 RMD160 c304d60350f6961a883b DIST NVIDIA-Linux-x86_64-185.18.29-pkg2.run 22239305 RMD160 c0ce236ebedc5eb49fd4886bd816ec4232cae5a3 SHA1 4471ef08a4d9277c17ee06aae0acba8c92769b57 SHA256 006545ef7581183a4c1e3d6994c2f9591652d2c20211754263792a8ae372dad0 DIST NVIDIA-Linux-x86_64-185.18.31-pkg2.run 22238341 RMD160 c5d09f96c299c411f8ac9b70f8ca15f0e934a376 SHA1 57edcde23f801ab559e9ea1d79416105800c4f5c SHA256 bf3697d2f046bcf8422be26c7bb1d33f2a2071a21149ed5514f525dc1dd763be DIST NVIDIA-Linux-x86_64-190.18-pkg2.run 22906989 RMD160 0f040375d25db3ed2ecfb1bbbbb6fa75d6b0e465 SHA1 9df427304b0e9446d46f81af3bac1073a124ae81 SHA256 673ced10402a4b193c5213e9ef6acd9ed0501a89ce34fff5f6f84cb1afd5d6b7 +DIST NVIDIA-Linux-x86_64-190.25-pkg2.run 22796183 RMD160 354df53287c651973bfc7357a4ba15cb2ad26905 SHA1 33621a13cd88582696ccc146e8cac279dfdab70e SHA256 8e2a7f5e197af3936a8193739aac292793cec050487915c0068844f68744e023 DIST NVIDIA-Linux-x86_64-71.86.07-pkg2.run 8380439 RMD160 5ba261e0f5f25868236ca47768167dd913786a23 SHA1 de7c6951bfc524d2decbe729346e3af351f1d8cb SHA256 e42e004647225086cd2bceb207d3575974188133cb4d5e497188df967362cf39 DIST NVIDIA-Linux-x86_64-71.86.09-pkg2.run 8388126 RMD160 c8f5252db6f22149164156e62e4a151334adc869 SHA1 8df93e50e5fc182290838db5f762763c0582bc9c SHA256 f6d2d949baac3ea00132bb76df2a982f4fefdf2b9acfc7968668d317ed1010df DIST NVIDIA-Linux-x86_64-71.86.11-pkg2.run 8390675 RMD160 5ce5f01f70901e9fa711d1ef5d0e20bd471d9af5 SHA1 92364b06bf9aad89b6be351ed23ed316a6cd2515 SHA256 fccfd8f017820599e7a29443d65d990a2d083479c7ed980249cc0d37ca5cfba7 @@ -59,11 +62,12 @@ EBUILD nvidia-drivers-185.18.14.ebuild 16326 RMD160 5a648836d149339036a30ead564a EBUILD nvidia-drivers-185.18.29.ebuild 16848 RMD160 663b782ed23d9bcf25d444c743023350081f7e57 SHA1 d8d7978ced932d06058425a87bc190a626f90d63 SHA256 306a83c27c2ecadbdf187bea5813feab62567eff61d66034eb0dbde7320bac0e EBUILD nvidia-drivers-185.18.31.ebuild 16848 RMD160 3cd0779f2a0905c328d34a9b2997bd1b34bd0a59 SHA1 b4e51979d885d130e09f27c51a5e6eee9a31e9b9 SHA256 76d8128bd6ee4b4f6c949cb6f0722736c4e586f331ca6aa8962c6d0cb2c21b82 EBUILD nvidia-drivers-190.18.ebuild 16323 RMD160 04c3652de439f9d30554a4e402422d0c4c3b33ee SHA1 863411ca27a0700cdeb9ac7aebbba7c647d5d1d6 SHA256 244872967960e1a71a43073357362e7697d16225f18d5d422d03a6e75f41c32c +EBUILD nvidia-drivers-190.25.ebuild 16323 RMD160 04c3652de439f9d30554a4e402422d0c4c3b33ee SHA1 863411ca27a0700cdeb9ac7aebbba7c647d5d1d6 SHA256 244872967960e1a71a43073357362e7697d16225f18d5d422d03a6e75f41c32c EBUILD nvidia-drivers-71.86.07.ebuild 14198 RMD160 e3ba3bdd490291cacff3d2a1fcb9e62c6a572db2 SHA1 f026562b2b333a93e7e9ba8f7b1332e4c4a13481 SHA256 2da638549a5c754f135fc1860c370f77001716b5c12ee8dc23fb16c239d16202 EBUILD nvidia-drivers-71.86.09.ebuild 14200 RMD160 1208de3e64a596b6a464e4e979f28a6f5d6490ea SHA1 6f842c11dbc3162bcbe677b31fb79c768d6bb037 SHA256 a0942d2961d8bcc28c42adbbac7bc270fe5c3e6d03adba0ba42e44fe377b5c5c EBUILD nvidia-drivers-71.86.11.ebuild 14197 RMD160 e63d489ae1524810f2556c6f515856f7e5ce3813 SHA1 489180c36806b4238dc39cf84566c9351938c060 SHA256 6a4f31d5e46e023830e8908b456d3cb99fb8aa4ba2a8f84daa91497c63c5a708 EBUILD nvidia-drivers-96.43.09.ebuild 14525 RMD160 4b99d2295e5f00081c8298a1dbf2838167d23510 SHA1 f50696adc9dd29bd9ea5baa3c4aa6f3252e1c43d SHA256 a16ddbacb31c494ab08ca5f98504c8e1aec7c513da0c0d4e3d0308a2c56237ca EBUILD nvidia-drivers-96.43.11.ebuild 14527 RMD160 8f6adaf8922b2b89c47f5d5a24cda85d35cf927b SHA1 c4896e8b739e1ebe43a6ade3c50a154eb1b292be SHA256 77645f44da6bb71791ec39976bd0d3967c58c811fb8a1b0f7975fa553d95b5d9 EBUILD nvidia-drivers-96.43.13.ebuild 14523 RMD160 05c1abee2a37582d4c6a15a384ada627c872fffd SHA1 ccec82fdd34de6e6f1562a120257e9d68a6b6686 SHA256 2289a2cae34300952692fb7f9145bdd7f67f3bfe472fc569121436beacc0b3be -MISC ChangeLog 38133 RMD160 740272dc43159f33a71233485bd8afb84ce42f4e SHA1 c78b5801a3cfd31ae5e05d1c6f89b61ba9ec6be9 SHA256 9b261b573cab8375d1f7d5b72a595b1fe0091b631282f6b9efa8c6deb585616a +MISC ChangeLog 38272 RMD160 2cdbf117fae7878426792bbe5257e967bda5fa33 SHA1 5deea6c4739a4015a8a6b87023a4e750dc12f144 SHA256 7ec8516edf7c87c4c9bba65fac49e61801e9873c89ce866d724d69714602c320 MISC metadata.xml 608 RMD160 69923c951a3b11d3632338cd673430c1335f78cd SHA1 febe635634c122bf9fb5fd83fd486ab5a25282b3 SHA256 6b13dc244ff827b23a6f1de01eef3a7f607917573fb36b7316a1a629c78cc6bd diff --git a/x11-drivers/nvidia-drivers/nvidia-drivers-190.25.ebuild b/x11-drivers/nvidia-drivers/nvidia-drivers-190.25.ebuild new file mode 100644 index 000000000000..7207d624bb4d --- /dev/null +++ b/x11-drivers/nvidia-drivers/nvidia-drivers-190.25.ebuild @@ -0,0 +1,542 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-drivers/nvidia-drivers/nvidia-drivers-190.25.ebuild,v 1.1 2009/09/02 21:49:40 peper Exp $ + +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.6.99 + multilib? ( app-emulation/emul-linux-x86-xlibs ) + kernel_FreeBSD? ( !media-video/nvidia-freebsd ) + !app-emulation/emul-linux-x86-nvidia + !x11-drivers/nvidia-legacy-drivers" +DEPEND="${COMMON} + kernel_linux? ( virtual/linux-sources ) + app-admin/eselect-opengl" +RDEPEND="${COMMON} + kernel_linux? ( virtual/modutils ) + media-libs/mesa + acpi? ( sys-power/acpid )" +PDEPEND="gtk? ( media-video/nvidia-settings )" + +QA_TEXTRELS_x86="usr/lib/libXvMCNVIDIA.so.${PV} + usr/lib/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib/opengl/nvidia/tls/libnvidia-tls.so.${PV} + usr/lib/opengl/nvidia/lib/libGL.so.${PV} + usr/lib/opengl/nvidia/lib/libnvidia-cfg.so.${PV} + usr/lib/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib/opengl/nvidia/extensions/libglx.so + usr/lib/xorg/modules/drivers/nvidia_drv.so + usr/lib/libcuda.so.${PV} + usr/lib/libvdpau_nvidia.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/opengl/nvidia/lib/libnvidia-cfg.so.1 + usr/lib/opengl/nvidia/no-tls/libnvidia-tls.so.1 + usr/lib/opengl/nvidia/extensions/libglx.so + usr/lib/xorg/modules/drivers/nvidia_drv.so" + +QA_TEXTRELS_amd64="usr/lib32/opengl/nvidia/tls/libnvidia-tls.so.${PV} + usr/lib32/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib32/opengl/nvidia/lib/libGL.so.${PV} + usr/lib32/opengl/nvidia/lib/libnvidia-cfg.so.${PV} + usr/lib32/libcuda.so.${PV} + usr/lib32/libvdpau_nvidia.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" + +QA_EXECSTACK_amd64="usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib32/opengl/nvidia/lib/libGL.so.${PV} + usr/lib64/xorg/modules/drivers/nvidia_drv.so + usr/lib64/libXvMCNVIDIA.so.${PV} + usr/lib64/opengl/nvidia/tls/libnvidia-tls.so.${PV} + usr/lib64/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib64/opengl/nvidia/lib/libGL.so.${PV} + usr/lib64/opengl/nvidia/lib/libnvidia-cfg.so.${PV} + usr/lib64/opengl/nvidia/extensions/libglx.so + usr/bin/nvidia-xconfig + usr/lib64/libXvMCNVIDIA.a:NVXVMC.o" + +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 + usr/lib/libXvMCNVIDIA.a" + +QA_WX_LOAD_amd64="usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib32/opengl/nvidia/lib/libGL.so.${PV} + usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib64/opengl/nvidia/lib/libGL.so.${PV} + usr/lib64/opengl/nvidia/extensions/libglx.so" + +# we really should have QA_DT_HASH_x86 and QA_DT_HASH_amd64 but Portage +# does not support it. bug #271416 + +QA_DT_HASH="usr/lib32/libvdpau_trace.so.${PV} + usr/lib32/libvdpau.so.${PV} + usr/lib32/libcuda.so.${PV} + usr/lib32/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib32/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib32/opengl/nvidia/lib/libGL.so.${PV} + usr/lib32/opengl/nvidia/tls/libnvidia-tls.so.${PV} + usr/lib32/libvdpau_nvidia.so.${PV} + usr/bin/nvidia-xconfig + usr/lib64/libvdpau_trace.so.${PV} + usr/lib64/libvdpau.so.${PV} + usr/lib64/libcuda.so.${PV} + usr/lib64/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib64/opengl/nvidia/lib/libnvidia-cfg.so.${PV} + usr/lib64/opengl/nvidia/lib/libGLcore.so.${PV} + usr/lib64/opengl/nvidia/lib/libGL.so.${PV} + usr/lib64/opengl/nvidia/tls/libnvidia-tls.so.${PV} + usr/lib64/opengl/nvidia/extensions/libwfb.so + usr/lib64/opengl/nvidia/extensions/libglx.so + usr/lib64/xorg/modules/drivers/nvidia_drv.so + usr/lib64/libXvMCNVIDIA.so.${PV} + usr/lib64/libvdpau_nvidia.so.${PV} + + usr/lib/libvdpau_trace.so.${PV} + usr/lib/libvdpau.so.${PV} + usr/lib/libcuda.so.${PV} + usr/lib/opengl/nvidia/no-tls/libnvidia-tls.so.${PV} + usr/lib/opengl/nvidia/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/tls/libnvidia-tls.so.${PV} + usr/lib/opengl/nvidia/extensions/libwfb.so + usr/lib/opengl/nvidia/extensions/libglx.so + usr/lib/xorg/modules/drivers/nvidia_drv.so + usr/lib/libXvMCNVIDIA.so.${PV} + usr/lib/libvdpau_nvidia.so.${PV}" + +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 +} + +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 + 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_SRC="${S}/src" + elif use kernel_linux; then + NV_DOC="${S}/usr/share/doc" + NV_EXEC="${S}/usr/bin" + NV_SRC="${S}/usr/src/nv" + 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 + + # Patches go below here, add brief description + cd "${S}" + 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 + + 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() { + local MLTEST=$(type dyn_unpack) + + cd "${S}" + + 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" ] || 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 + + 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 || return 0 + + # Documentation + dodoc "${NV_DOC}"/{XF86Config.sample,Copyrights} + dohtml "${NV_DOC}"/html/* + if use x86-fbsd; then + dodoc "${NV_DOC}/README" + else + # Docs + newdoc "${NV_DOC}/README.txt" README + dodoc "${NV_DOC}/NVIDIA_Changelog" + fi + + # Helper Apps + dobin ${NV_EXEC}/nvidia-xconfig || die + dobin ${NV_EXEC}/nvidia-bug-report.sh || die +} + +# 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) + + # libnvidia-cfg.so is no longer supplied in lib32; step over it gracefully + if [ -e $2.$3 ] ; then + doexe $2.$3 + dosym ${libname}.$3 $1/${libname} + [[ $3 != "1" ]] && dosym ${libname}.$3 $1/${libname}.1 + fi +} + +src_install-libs() { + local pkglibdir=lib + local inslibdir=$(get_libdir) + + if [[ ${#} -eq 2 ]] ; then + pkglibdir=${1} + inslibdir=${2} + elif has_multilib_profile && [[ ${ABI} == "x86" ]] ; then + pkglibdir=lib32 + fi + + local usrpkglibdir=usr/${pkglibdir} + local libdir=usr/X11R6/${pkglibdir} + local drvdir=${libdir}/modules/drivers + local extdir=${libdir}/modules/extensions + local incdir=usr/include/GL + local sover=${PV} + local NV_ROOT="/usr/${inslibdir}/opengl/nvidia" + local NO_TLS_ROOT="${NV_ROOT}/no-tls" + local TLS_ROOT="${NV_ROOT}/tls" + local X11_LIB_DIR="/usr/${inslibdir}/xorg" + + if use x86-fbsd; then + # on FreeBSD everything is on obj/ + pkglibdir=obj + usrpkglibdir=obj + x11pkglibdir=obj + drvdir=obj + extdir=obj + + # don't ask me why the headers are there.. glxext.h is missing + incdir=doc + + # on FreeBSD it has just .1 suffix + sover=1 + fi + + # The GLX libraries + donvidia ${NV_ROOT}/lib ${usrpkglibdir}/libGL.so ${sover} + donvidia ${NV_ROOT}/lib ${usrpkglibdir}/libGLcore.so ${sover} + + donvidia ${NV_ROOT}/lib ${usrpkglibdir}/libnvidia-cfg.so ${sover} + + dodir ${NO_TLS_ROOT} + donvidia ${NO_TLS_ROOT} ${usrpkglibdir}/libnvidia-tls.so ${sover} + + if ! use x86-fbsd; then + donvidia ${TLS_ROOT} ${usrpkglibdir}/tls/libnvidia-tls.so ${sover} + fi + + if want_tls ; then + dosym ../tls/libnvidia-tls.so ${NV_ROOT}/lib + dosym ../tls/libnvidia-tls.so.1 ${NV_ROOT}/lib + dosym ../tls/libnvidia-tls.so.${sover} ${NV_ROOT}/lib + else + dosym ../no-tls/libnvidia-tls.so ${NV_ROOT}/lib + dosym ../no-tls/libnvidia-tls.so.1 ${NV_ROOT}/lib + dosym ../no-tls/libnvidia-tls.so.${sover} ${NV_ROOT}/lib + fi + + if ! use x86-fbsd; then + # Install the .la file for libtool, to prevent e.g. bug #176423 + [ -f "${FILESDIR}/libGL.la-r2" ] || die "libGL.la-r2 missing in FILESDIR" + local ver1=$(get_version_component_range 1) + local ver2=$(get_version_component_range 2) + local ver3=$(get_version_component_range 3) + sed -e "s:\${PV}:${PV}:" \ + -e "s:\${ver1}:${ver1}:" \ + -e "s:\${ver2}:${ver2}:" \ + -e "s:\${ver3}:${ver3}:" \ + -e "s:\${libdir}:${inslibdir}:" \ + "${FILESDIR}"/libGL.la-r2 > "${D}"/${NV_ROOT}/lib/libGL.la + fi + + exeinto ${X11_LIB_DIR}/modules/drivers + + [[ -f ${drvdir}/nvidia_drv.so ]] && \ + doexe ${drvdir}/nvidia_drv.so + + insinto /usr/${inslibdir} + [[ -f ${libdir}/libXvMCNVIDIA.a ]] && \ + doins ${libdir}/libXvMCNVIDIA.a + exeinto /usr/${inslibdir} + # fix Bug 131315 + [[ -f ${libdir}/libXvMCNVIDIA.so.${PV} ]] && \ + doexe ${libdir}/libXvMCNVIDIA.so.${PV} && \ + dosym libXvMCNVIDIA.so.${PV} \ + /usr/${inslibdir}/libXvMCNVIDIA.so + + exeinto ${NV_ROOT}/extensions + [[ -f ${libdir}/modules/libnvidia-wfb.so.${sover} ]] && \ + newexe ${libdir}/modules/libnvidia-wfb.so.${sover} libwfb.so + [[ -f ${extdir}/libglx.so.${sover} ]] && \ + newexe ${extdir}/libglx.so.${sover} libglx.so + + # Includes + insinto ${NV_ROOT}/include + doins ${incdir}/*.h + + #cuda + if [[ -f usr/include/cuda/cuda.h ]]; then + dodir /usr/include/cuda + insinto /usr/include/cuda + doins usr/include/cuda/*.h + + if [[ -f usr/${pkglibdir}/libcuda.so.${PV} ]]; then + dolib.so usr/${pkglibdir}/libcuda.so.${PV} + dosym libcuda.so.${PV} /usr/${inslibdir}/libcuda.so.1 + dosym libcuda.so.1 /usr/${inslibdir}/libcuda.so + fi + fi + + #vdpau + if [[ -f usr/include/vdpau/vdpau.h ]]; then + dodir /usr/include/vdpau + insinto /usr/include/vdpau + doins usr/include/vdpau/*.h + + for vdpaulib in vdpau_nvidia vdpau vdpau_trace; do + dolib.so usr/${pkglibdir}/lib${vdpaulib}.so.${PV} + dosym lib${vdpaulib}.so.${PV} /usr/${inslibdir}/lib${vdpaulib}.so.1 + dosym lib${vdpaulib}.so.1 /usr/${inslibdir}/lib${vdpaulib}.so + done + fi +} + +pkg_preinst() { + + # 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 most 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 +} + +want_tls() { + # For uclibc or anything non glibc, return false + has_version sys-libs/glibc || return 1 + + # Old versions of glibc were lt/no-tls only + has_version '<sys-libs/glibc-2.3.2' && return 1 + + if use x86 ; then + case ${CHOST/-*} in + i486|i586|i686) ;; + *) return 1 ;; + esac + fi + + # If we've got nptl, we've got tls + built_with_use --missing true sys-libs/glibc nptl && return 0 + + # 2.3.5 turned off tls for linuxthreads glibc on i486 and i586 + if use x86 && has_version '>=sys-libs/glibc-2.3.5' ; then + case ${CHOST/-*} in + i486|i586) return 1 ;; + esac + fi + + # These versions built linuxthreads version to support tls, too + has_version '>=sys-libs/glibc-2.3.4.20040619-r2' && return 0 + + return 1 +} + +pkg_postrm() { + if use kernel_linux; then + linux-mod_pkg_postrm + fi + eselect opengl set --use-old xorg-x11 +} |