summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorLev Velykoivanenko2018-07-21 10:50:24 +0200
committerLev Velykoivanenko2018-07-21 10:50:24 +0200
commit9ef47ebdb5afd50a5afdb04259e6b99180dcd9a6 (patch)
treedc3175a6332d2eb574f6d6770bd03652e146faf9
parentc017b2a4aa741401de16e1bdcd9fc823ce2132dc (diff)
downloadaur-9ef47ebdb5afd50a5afdb04259e6b99180dcd9a6.tar.gz
Update package to v19.15
Remove gcc6 makedepends. Change CUDA_HOST_COMPILER to use /opt/cuda/bin/gcc Add optional ccache support.
-rwxr-xr-x.SRCINFO7
-rwxr-xr-xPKGBUILD30
2 files changed, 24 insertions, 13 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 3a00521d274..23600d17a42 100755
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = python-dlib-cuda
pkgdesc = Dlib is a general purpose cross-platform C++ library designed using contract programming and modern C++ techniques.
- pkgver = 19.14
+ pkgver = 19.15
pkgrel = 1
url = http://www.dlib.net/
arch = x86_64
@@ -8,7 +8,6 @@ pkgbase = python-dlib-cuda
makedepends = cmake
makedepends = cuda
makedepends = cudnn
- makedepends = gcc6
makedepends = libx11
makedepends = python
makedepends = python2
@@ -22,8 +21,8 @@ pkgbase = python-dlib-cuda
optdepends = libpng: for PNG support
optdepends = neon: for neon support
optdepends = sqlite: for sqlite support
- source = http://dlib.net/files/dlib-19.14.tar.bz2
- md5sums = 2c2ff1a0dd116a6267f4a76aaa5bd36b
+ source = http://dlib.net/files/dlib-19.15.tar.bz2
+ sha256sums = 5340eeaaea7dd6d93d55e7a7d2fdb1f854a77b75f66049354db53671a202c11d
pkgname = python-dlib-cuda
depends = python
diff --git a/PKGBUILD b/PKGBUILD
index 0bbb06a70dc..3dc48753320 100755
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -8,14 +8,14 @@
pkgname=('python-dlib-cuda' 'python2-dlib-cuda')
_pkgname='dlib'
-pkgver=19.14
+pkgver=19.15
pkgrel=1
pkgdesc="Dlib is a general purpose cross-platform C++ library designed using contract programming and modern C++ techniques."
arch=('x86_64')
url="http://www.dlib.net/"
license=('Boost')
depends=('cuda' 'cudnn' 'libx11')
-makedepends=('cmake' 'cuda' 'cudnn' 'gcc6' 'libx11' 'python' 'python2')
+makedepends=('cmake' 'cuda' 'cudnn' 'libx11' 'python' 'python2')
optdepends=('cblas: for BLAS support'
'giflib: for GIF support'
'lapack: for LAPACK support'
@@ -24,7 +24,7 @@ optdepends=('cblas: for BLAS support'
'neon: for neon support'
'sqlite: for sqlite support')
source=("http://dlib.net/files/${_pkgname}-${pkgver}.tar.bz2")
-md5sums=('2c2ff1a0dd116a6267f4a76aaa5bd36b')
+sha256sums=('5340eeaaea7dd6d93d55e7a7d2fdb1f854a77b75f66049354db53671a202c11d')
# Detecting whether certain cpu optimisations can be made
_avx_available=()
@@ -45,16 +45,28 @@ fi
build() {
cd "${srcdir}/${_pkgname}-${pkgver}"
- # Exporting compiler environment variables
- # This is necessary to get cuda support
- export CC=$(command -v gcc-6)
- export CXX=$(command -v g++-6)
+ # Preparing array of variables setting the compiler for CUDA and optionally
+ # ccache support.
+ # Code based on the dlib package found in the AUR.
+ # To enable ccache support you need to install the following package:
+ # https://github.com/pingplug/PKGBUILDs/tree/master/others/ccache-ext
+ _compiler_vars=( '--set' 'CUDA_HOST_COMPILER=/opt/cuda/bin/gcc' )
+ if [[ -f "/usr/lib/ccache/bin/nvcc-ccache" ]]; then
+ _compiler_vars+=( '--set' 'CUDA_NVCC_EXECUTABLE=/usr/lib/ccache/bin/nvcc-ccache' )
+ _compiler_vars+=( '--set' 'CUDA_HOST_COMPILER=/usr/lib/ccache/bin/gcc-7' )
+ fi
# Compiling for Python 3
- python setup.py build "${_avx_available[@]}" "${_sse2_available[@]}" "${_sse4_available[@]}"
+ python setup.py build "${_avx_available[@]}" \
+ "${_sse2_available[@]}" \
+ "${_sse4_available[@]}" \
+ "${_compiler_vars[@]}"
# Compiling for Python 2
- python2 setup.py build "${_avx_available[@]}" "${_sse2_available[@]}" "${_sse4_available[@]}"
+ python2 setup.py build "${_avx_available[@]}" \
+ "${_sse2_available[@]}" \
+ "${_sse4_available[@]}" \
+ "${_compiler_vars[@]}"
}
package_python-dlib-cuda() {