From 19a900ef591c16be264880270a7baad457938615 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Wed, 14 Nov 2012 15:07:19 +0100 Subject: [PATCH] New package: catalyst-12.11-beta (propietary AMD GPU driver). --- srcpkgs/catalyst-dkms | 1 + srcpkgs/catalyst-opencl | 1 + srcpkgs/catalyst/INSTALL | 16 +++ srcpkgs/catalyst/catalyst-dkms.template | 31 ++++++ srcpkgs/catalyst/catalyst-opencl.rshlibs | 8 ++ srcpkgs/catalyst/catalyst-opencl.template | 25 +++++ srcpkgs/catalyst/catalyst.rshlibs | 23 +++++ srcpkgs/catalyst/files/atieventsd.service | 9 ++ srcpkgs/catalyst/files/dkms.conf | 7 ++ srcpkgs/catalyst/files/signature.from.12.9 | 1 + srcpkgs/catalyst/template | 108 +++++++++++++++++++++ srcpkgs/xbps-git/template | 2 +- 12 files changed, 231 insertions(+), 1 deletion(-) create mode 120000 srcpkgs/catalyst-dkms create mode 120000 srcpkgs/catalyst-opencl create mode 100644 srcpkgs/catalyst/INSTALL create mode 100644 srcpkgs/catalyst/catalyst-dkms.template create mode 100644 srcpkgs/catalyst/catalyst-opencl.rshlibs create mode 100644 srcpkgs/catalyst/catalyst-opencl.template create mode 100644 srcpkgs/catalyst/catalyst.rshlibs create mode 100644 srcpkgs/catalyst/files/atieventsd.service create mode 100644 srcpkgs/catalyst/files/dkms.conf create mode 100644 srcpkgs/catalyst/files/signature.from.12.9 create mode 100644 srcpkgs/catalyst/template diff --git a/srcpkgs/catalyst-dkms b/srcpkgs/catalyst-dkms new file mode 120000 index 0000000000..96a1eca006 --- /dev/null +++ b/srcpkgs/catalyst-dkms @@ -0,0 +1 @@ +catalyst \ No newline at end of file diff --git a/srcpkgs/catalyst-opencl b/srcpkgs/catalyst-opencl new file mode 120000 index 0000000000..96a1eca006 --- /dev/null +++ b/srcpkgs/catalyst-opencl @@ -0,0 +1 @@ +catalyst \ No newline at end of file diff --git a/srcpkgs/catalyst/INSTALL b/srcpkgs/catalyst/INSTALL new file mode 100644 index 0000000000..a9b81a19fc --- /dev/null +++ b/srcpkgs/catalyst/INSTALL @@ -0,0 +1,16 @@ +# Create libGL and libglx symlinks for catalyst. +case ${ACTION} in +post) + rm -f usr/lib/libGL.so usr/lib/libGL.so.1 + rm -f usr/lib/xorg/modules/extensions/libglx.so + + # libGL + cd usr/lib + ln -sf fglrx-libGL.so.1.2 libGL.so + ln -sf fglrx-libGL.so.1.2 libGL.so.1 + + # libglx + cd ../../usr/lib/xorg/modules/extensions + ln -sf ../fglrx/fglrx-libglx.so libglx.so + ;; +esac diff --git a/srcpkgs/catalyst/catalyst-dkms.template b/srcpkgs/catalyst/catalyst-dkms.template new file mode 100644 index 0000000000..abba4363eb --- /dev/null +++ b/srcpkgs/catalyst/catalyst-dkms.template @@ -0,0 +1,31 @@ +# Template file for 'nvidia-dkms'. +# +short_desc="AMD catalyst driver -- DKMS kernel module" +long_desc=" + This package contains the AMD non free kernel module files for DKMS." + +nonfree=yes +triggers="dkms" +dkms_modules="fglrx ${version}_${revision}" + +do_install() { + local _fglrx=fglrx-${version}_${revision} + + vmkdir usr/lib/modprobe.d + vmkdir usr/lib/modules-load.d + vmkdir usr/src/${_fglrx} + + cd ${wrksrc}/fglrx + cp -r common/lib/modules/fglrx/build_mod/* ${DESTDIR}/usr/src/${_fglrx} + + vinstall arch/${_ARCHDIR}/lib/modules/fglrx/build_mod/libfglrx_ip.a \ + 644 usr/src/${_fglrx} + + vinstall ${FILESDIR}/dkms.conf 644 usr/src/${_fglrx} + + sed -i -e "s/@VERSION@/${version}-${revision}/" \ + ${DESTDIR}/usr/src/${_fglrx}/dkms.conf + + echo "blacklist radeon" > ${DESTDIR}/usr/lib/modprobe.d/catalyst.conf + echo "fglrx" > ${DESTDIR}/usr/lib/modules-load.d/catalyst.conf +} diff --git a/srcpkgs/catalyst/catalyst-opencl.rshlibs b/srcpkgs/catalyst/catalyst-opencl.rshlibs new file mode 100644 index 0000000000..3699ce3897 --- /dev/null +++ b/srcpkgs/catalyst/catalyst-opencl.rshlibs @@ -0,0 +1,8 @@ +libpthread.so.0 +libm.so.6 x86_64 +libdl.so.2 +libgcc_s.so.1 +libc.so.6 +ld-linux-x86-64.so.2 +ld-linux.so.2 +librt.so.1 x86_64 diff --git a/srcpkgs/catalyst/catalyst-opencl.template b/srcpkgs/catalyst/catalyst-opencl.template new file mode 100644 index 0000000000..72cd9fc662 --- /dev/null +++ b/srcpkgs/catalyst/catalyst-opencl.template @@ -0,0 +1,25 @@ +# Template file for 'nvidia-opencl'. +# +short_desc="AMD catalyst driver -- OpenCL implementation" +long_desc=" + This package contains the AMD non free OpenCL implementation." + +nonfree=yes +provides="libOpenCL-${version}" +replaces="libOpenCL>=0" + +do_install() { + cd ${wrksrc}/fglrx/arch/${_ARCHDIR} + + vinstall usr/bin/clinfo 755 usr/bin + + vmkdir usr/lib + vmkdir etc/OpenCL/vendors + + install -m644 etc/OpenCL/vendors/amdocl*.icd \ + ${DESTDIR}/etc/OpenCL/vendors + + install -m755 usr/lib${_ARCHLIB}/libamdocl*.so ${DESTDIR}/usr/lib/ + install -m755 usr/lib${_ARCHLIB}/libOpenCL.so.1 ${DESTDIR}/usr/lib/ + ln -s libOpenCL.so.1 ${DESTDIR}/usr/lib/libOpenCL.so +} diff --git a/srcpkgs/catalyst/catalyst.rshlibs b/srcpkgs/catalyst/catalyst.rshlibs new file mode 100644 index 0000000000..3212059d06 --- /dev/null +++ b/srcpkgs/catalyst/catalyst.rshlibs @@ -0,0 +1,23 @@ +libX11.so.6 +libXext.so.6 +libXrandr.so.2 +libXrender.so.1 +libm.so.6 +libGL.so.1 +libc.so.6 +libdl.so.2 +libXfixes.so.3 +libQtGui.so.4 +libQtCore.so.4 +libXxf86vm.so.1 +libICE.so.6 +libSM.so.6 +libfontconfig.so.1 +libpthread.so.0 +libfreetype.so.6 +libXinerama.so.1 +libXcursor.so.1 +libstdc++.so.6 +libgcc_s.so.1 +libcrypt.so.1 +librt.so.1 diff --git a/srcpkgs/catalyst/files/atieventsd.service b/srcpkgs/catalyst/files/atieventsd.service new file mode 100644 index 0000000000..ccf3a5975f --- /dev/null +++ b/srcpkgs/catalyst/files/atieventsd.service @@ -0,0 +1,9 @@ +[Unit] +Description=Catalyst event Daemon +Requires=acpid.socket + +[Service] +ExecStart=/usr/sbin/atieventsd --nodaemon + +[Install] +WantedBy=multi-user.target diff --git a/srcpkgs/catalyst/files/dkms.conf b/srcpkgs/catalyst/files/dkms.conf new file mode 100644 index 0000000000..5403442c20 --- /dev/null +++ b/srcpkgs/catalyst/files/dkms.conf @@ -0,0 +1,7 @@ +PACKAGE_NAME="fglrx" +PACKAGE_VERSION="@VERSION@" +CLEAN="rm -f *.*o" +BUILT_MODULE_NAME[0]="fglrx" +MAKE[0]="sh make.sh --nohints --uname_r=$kernelver --norootcheck" +DEST_MODULE_LOCATION[0]="/updates" +AUTOINSTALL="yes" diff --git a/srcpkgs/catalyst/files/signature.from.12.9 b/srcpkgs/catalyst/files/signature.from.12.9 new file mode 100644 index 0000000000..2a31e93bb8 --- /dev/null +++ b/srcpkgs/catalyst/files/signature.from.12.9 @@ -0,0 +1 @@ +9777c589791007f4aeef06c922ad54a2:ae59f5b9572136d99fdd36f0109d358fa643f2bd4a2644d9efbb4fe91a9f6590a145:f612f0b01f2565cd9bd834f8119b309bae11a1ed4a2661c49fdf3fad11986cc4f641f1ba1f2265909a8e34ff1699309bf211a7eb4d7662cd9f8e3faf14986d92f646f1bc \ No newline at end of file diff --git a/srcpkgs/catalyst/template b/srcpkgs/catalyst/template new file mode 100644 index 0000000000..99f119b7be --- /dev/null +++ b/srcpkgs/catalyst/template @@ -0,0 +1,108 @@ +# Template file for 'catalyst' +pkgname=catalyst +_distver=12.11 +version=${_distver}beta +revision=1 +short_desc="AMD catalyst driver -- libraries and utilities" +maintainer="Juan RP " +license="Propietary AMD license" +homepage="http://www.amd.com" +long_desc=" + This package contains the libraries and utilities for + the non free AMD GPU linux kernel driver." + +create_wrksrc=yes +nostrip=yes +nonfree=yes +subpackages="${pkgname}-dkms ${pkgname}-opencl" +depends="${pkgname}-dkms-${version}_${revision}" +makedepends="unzip" +conflicts="nvidia>=0" + +distfiles=http://www2.ati.com/drivers/beta/amd-driver-installer-catalyst-${_distver}-beta-x86.x86_64.zip +checksum=0c3e0c96b3daf8a6647ba2285374c96b7d57bc0ee69fbc7dc0c091cd482caffc + +if [ "${XBPS_MACHINE}" = "i686" ]; then + _ARCHDIR="x86" +elif [ "${XBPS_MACHINE}" = "x86_64" ]; then + _ARCHDIR="x86_64" + _ARCHLIB="64" + _ARCHXPIC="_64a" +fi + +do_build() { + chmod 755 *.run + ./amd-driver-installer*.run --extract fglrx +} + +do_install() { + cd ${wrksrc}/fglrx + + install -dm755 ${DESTDIR}/usr/{bin,sbin} + install -dm755 ${DESTDIR}/usr/lib/{dri,xorg/modules/{dri,drivers,extensions/fglrx,linux},systemd/system} + install -dm755 ${DESTDIR}/usr/include/GL + install -dm755 ${DESTDIR}/etc/{ati,acpi/events,security/console.apps} + install -dm755 ${DESTDIR}/usr/share/{applications,ati/amdcccle,man/man8,pixmaps} + + # binaries + install -m755 common/usr/sbin/* ${DESTDIR}/usr/sbin/ + install -m755 common/usr/X11R6/bin/* ${DESTDIR}/usr/bin/ + install -m755 arch/${_ARCHDIR}/usr/sbin/* ${DESTDIR}/usr/sbin/ + install -m755 arch/${_ARCHDIR}/usr/X11R6/bin/* ${DESTDIR}/usr/bin/ + + # headers + install -m644 common/usr/include/GL/* ${DESTDIR}/usr/include/GL/ + + # xorg/dri/gl/... drivers + cd xpic${_ARCHXPIC}/usr/X11R6/lib${_ARCHLIB}/modules + install -m755 *.so ${DESTDIR}/usr/lib/xorg/modules/ + install -m755 drivers/*.so ${DESTDIR}/usr/lib/xorg/modules/drivers/ + install -m755 linux/*.so ${DESTDIR}/usr/lib/xorg/modules/linux/ + install -m755 extensions/fglrx/fglrx-libglx.so ${DESTDIR}/usr/lib/xorg/modules/extensions/fglrx/ + + cd ${wrksrc}/fglrx/arch/${_ARCHDIR}/usr/X11R6/lib${_ARCHLIB} + + install -m755 modules/dri/fglrx_dri.so ${DESTDIR}/usr/lib/xorg/modules/dri/ + ln -s /usr/lib/xorg/modules/dri/fglrx_dri.so ${DESTDIR}/usr/lib/dri/ + install -m755 fglrx/fglrx-libGL.so.1.2 ${DESTDIR}/usr/lib/ + install -m755 *.so* ${DESTDIR}/usr/lib/ + install -m644 libAMDXvBA.cap ${DESTDIR}/usr/lib/ + + cd ${wrksrc}/fglrx/arch/${_ARCHDIR}/usr/lib${_ARCHLIB} + + install -m755 *.so* ${DESTDIR}/usr/lib/ + # needed symlinks + ln -s libatiuki.so.1.0 ${DESTDIR}/usr/lib/libatiuki.so.1 + ln -s libAMDXvBA.so.1.0 ${DESTDIR}/usr/lib/libAMDXvBA.so.1 + ln -s libXvBAW.so.1.0 ${DESTDIR}/usr/lib/libXvBAW.so + ln -s libfglrx_dm.so.1.0 ${DESTDIR}/usr/lib/libfglrx_dm.so.1 + + # various files + cd ${wrksrc}/fglrx/common + + install -m644 usr/share/man/man8/* ${DESTDIR}/usr/share/man/man8/ + install -m644 usr/share/applications/* ${DESTDIR}/usr/share/applications/ + install -m644 usr/share/icons/* ${DESTDIR}/usr/share/pixmaps/ + install -m644 usr/share/ati/amdcccle/* ${DESTDIR}/usr/share/ati/amdcccle/ + install -m644 etc/ati/* ${DESTDIR}/etc/ati/ + install -m755 ${wrksrc}/fglrx/packages/Ubuntu/dists/source/replacements/authatieventsd.sh ${DESTDIR}/etc/ati/ + install -m644 etc/security/console.apps/amdcccle-su ${DESTDIR}/etc/security/console.apps/ + install -m644 usr/share/applications/*.desktop ${DESTDIR}/usr/share/applications/ + # use ACPI example files + install -m755 usr/share/doc/fglrx/examples/etc/acpi/*.sh ${DESTDIR}/etc/acpi/ + install -m644 usr/share/doc/fglrx/examples/etc/acpi/events/* ${DESTDIR}/etc/acpi/events/ + # systemd scripts + install -m644 ${FILESDIR}/atieventsd.service ${DESTDIR}/usr/lib/systemd/system/ + + # provided in catalyst-opencl package + rm ${DESTDIR}/usr/lib/lib{amdocl*,OpenCL}.so* + + # we remove the watermark + install -m644 ${FILESDIR}/signature.from.12.9 ${DESTDIR}/etc/ati/signature + + # licenses + install -Dm644 ${wrksrc}/fglrx/common/usr/share/doc/fglrx/LICENSE.TXT \ + ${DESTDIR}/usr/share/licenses/${pkgname}/LICENSE.TXT + install -Dm644 ${wrksrc}/fglrx/common/usr/share/doc/amdcccle/ccc_copyrights.txt \ + ${DESTDIR}/usr/share/licenses/${pkgname}/amdcccle_copyrights.txt +} diff --git a/srcpkgs/xbps-git/template b/srcpkgs/xbps-git/template index 3408aeb394..37d2007d42 100644 --- a/srcpkgs/xbps-git/template +++ b/srcpkgs/xbps-git/template @@ -1,7 +1,7 @@ # Template file for 'xbps-git' pkgname=xbps-git version="$(date -u +%Y%m%d)" -revision=1 +revision=2 nofetch=yes noextract=yes build_style=configure