diff options
author | Michał Masłowski <mtjm@mtjm.eu> | 2013-01-12 13:04:54 +0100 |
---|---|---|
committer | Michał Masłowski <mtjm@mtjm.eu> | 2013-01-12 13:04:54 +0100 |
commit | 24633b6f6af8dc77ca77224448d226d8e99c9ce1 (patch) | |
tree | 0e862445be6a105957104f94f7e4f2668e1fdbba /community/python-pycuda/PKGBUILD | |
parent | d28ed89b1e41f7e71045a5c2e898aa3b369eda47 (diff) | |
parent | 8c2563c3c13cb7a279544f6926cbdd2eb902cc9a (diff) |
Merge branch 'master' of ssh://parabolagnulinux.org:1863/home/parabola/abslibre-pre-mips64el
Conflicts:
community/cdemu-daemon/PKGBUILD
community/chmsee/PKGBUILD
community/fceux/PKGBUILD
community/ginac/PKGBUILD
community/gstreamermm/PKGBUILD
community/gtksourceviewmm/PKGBUILD
community/lgi/PKGBUILD
community/libmirage/PKGBUILD
core/gawk/PKGBUILD
core/gettext/PKGBUILD
extra/enca/PKGBUILD
extra/gnutls/PKGBUILD
extra/hdf5/PKGBUILD
extra/kdebase/PKGBUILD
extra/libass/PKGBUILD
extra/libdiscid/PKGBUILD
extra/libxcomposite/PKGBUILD
extra/libxdamage/PKGBUILD
extra/maxima/PKGBUILD
extra/nx/PKGBUILD
extra/opencv/PKGBUILD
extra/pidgin/PKGBUILD
extra/redland/PKGBUILD
extra/sharutils/PKGBUILD
extra/soundtouch/PKGBUILD
extra/sqlite/PKGBUILD
extra/twisted/PKGBUILD
libre/dpkg/PKGBUILD
Diffstat (limited to 'community/python-pycuda/PKGBUILD')
-rw-r--r-- | community/python-pycuda/PKGBUILD | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/community/python-pycuda/PKGBUILD b/community/python-pycuda/PKGBUILD new file mode 100644 index 000000000..ada4857bb --- /dev/null +++ b/community/python-pycuda/PKGBUILD @@ -0,0 +1,66 @@ +# $Id: PKGBUILD 82154 2013-01-09 16:03:12Z stephane $ +# Maintainer: Stéphane Gaudreault <stephane@archlinux.org> +pkgbase=python-pycuda +pkgname=('python-pycuda' 'python2-pycuda' 'pycuda-headers') +pkgver=2012.1 +pkgrel=1 +pkgdesc="Python wrapper for Nvidia CUDA" +arch=('i686' 'x86_64') +url="http://mathema.tician.de/software/pycuda" +license=('MIT') +source=(http://pypi.python.org/packages/source/p/pycuda/pycuda-${pkgver}.tar.gz) +makedepends=('ctags' 'python2-distribute' 'python-distribute' 'python2-numpy' 'python-numpy' 'mesa' 'cuda' 'boost' 'nvidia-utils') +sha1sums=('dd52ee697ae9f6256efac3bca682be9c6e7c9649') + +build() { + cd "${srcdir}" + + _arch='' + [ "$CARCH" = "x86_64" ] && _arch='64' + + cp -a pycuda-${pkgver}{,-python2} + + cd "${srcdir}"/pycuda-${pkgver} + python3 ./configure.py \ + --cuda-root=/opt/cuda \ + --cuda-inc-dir=/opt/cuda/include \ + --cudadrv-lib-dir=/opt/cuda/lib${_arch} \ + --cudart-lib-dir=/opt/cuda/lib${_arch} \ + --no-use-shipped-boost \ + --boost-python-libname=boost_python3 + make + + cd "${srcdir}"/pycuda-${pkgver}-python2 + python2 ./configure.py \ + --cuda-root=/opt/cuda \ + --cuda-inc-dir=/opt/cuda/include \ + --cudadrv-lib-dir=/opt/cuda/lib${_arch} \ + --cudart-lib-dir=/opt/cuda/lib${_arch} \ + --no-use-shipped-boost + make +} + +package_python-pycuda() { + depends=('cuda' 'nvidia-utils' 'python-numpy' 'python-pytools' 'python' 'boost-libs' 'pycuda-headers') + cd "${srcdir}"/pycuda-${pkgver} + python3 setup.py install --prefix=/usr --root="${pkgdir}" --skip-build --optimize=1 + + rm -fr "${pkgdir}"/usr/include +} + +package_python2-pycuda() { + depends=('cuda' 'nvidia-utils' 'python2-numpy' 'python2-pytools' 'python2' 'boost-libs' 'pycuda-headers') + cd "${srcdir}"/pycuda-${pkgver}-python2 + python2 setup.py install --prefix=/usr --root="${pkgdir}" --skip-build --optimize=1 + + rm -fr "${pkgdir}"/usr/include +} + +package_pycuda-headers() { + cd "${srcdir}"/pycuda-${pkgver} + install -dm755 "${pkgdir}"/usr/include/pycuda + + for file in $(ls -1 src/cuda/*.hpp); do + install -m644 ${file} "${pkgdir}"/usr/include/pycuda + done +} |