1 # Maintainer: Carson Reynolds <carson@k2.t.u-tokyo.ac.jp>
2 # Contributor: Lawrence Lee <valheru AT facticius DOT net>
3 # Contributor: Ismael Barros Barros <razielmine@gmail.com>
9 pkgdesc="NVIDIA's CUDA architecture can be programmed in the only C language environment that unlocks the processing power of GPUs to solve the most complex compute-intensive challenges."
10 arch=('i686' 'x86_64')
11 [ "$CARCH" = "i686" ] && ARCH=x86
12 [ "$CARCH" = "x86_64" ] && ARCH=x86_64
13 url="http://www.nvidia.com/object/cuda_home.html"
15 depends=('cuda-toolkit-old'
18 source=(http://developer.download.nvidia.com/compute/cuda/2_2/sdk/cudasdk_${_pkgver}_linux.run
20 md5sums=('6ba1f419a88139530c0e82176bb1a8af' 'fa0a2c93ecc9bcdca8ce4c644572d62a')
23 mkdir -p $pkgdir/usr/share/licenses/cuda-sdk
24 mkdir -p $pkgdir/usr/share/doc/cuda-sdk
25 mkdir -p $pkgdir/usr/share/cuda-sdk/bin
26 mkdir -p $pkgdir/usr/share/cuda-sdk/lib
27 mkdir -p $pkgdir/usr/share/cuda-sdk/releaseNotesData
28 mkdir -p $pkgdir/usr/share/cuda-sdk/tools
30 #Create links for gcc-3.4 build environment
31 mkdir -p $pkgdir/usr/share/cuda-sdk/bin
32 ln -s /usr/bin/gcc-4.3 $pkgdir/usr/share/cuda-sdk/bin/gcc
33 ln -s /usr/bin/g++-4.3 $pkgdir/usr/share/cuda-sdk/bin/g++
37 sh cudasdk_${_pkgver}_linux.run --noexec --keep --nox11 &> /dev/null
40 patch -p0 -i $srcdir/common.mk.patch || return 1
41 sed -i 's|GCC34DIR|'"$pkgdir"'/usr/share/cuda-sdk/bin|' $srcdir/pkg/sdk/common/common.mk
42 #echo "check x86 patch"
45 CUDA_INSTALL_PATH=/usr make || return 1
48 cp -rf $srcdir/pkg/sdk/ $pkgdir/usr/share/cuda-sdk
51 install -m 755 $srcdir/pkg/sdk/bin/linux/release/* $pkgdir/usr/share/cuda-sdk/bin
52 mv $srcdir/pkg/sdk/doc/cudpp_license.txt $pkgdir/usr/share/licenses/cuda-sdk
53 mv $srcdir/pkg/sdk/doc/license.txt $pkgdir/usr/share/licenses/cuda-sdk
54 install -m 644 $srcdir/pkg/sdk/doc/* $pkgdir/usr/share/doc/cuda-sdk
57 #TODO: dxtc & simpleTexture must run as root since the data directory is not writable by default
58 #TODO: matrixMulDrv & simpleTexture are not passing tests