summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD38
1 files changed, 17 insertions, 21 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 9b9c09e03eb..45fe7f8dffc 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,9 +1,8 @@
-# Maintainer : Daniel Bermond < gmail-com: danielbermond >
+# Maintainer : Daniel Bermond <dbermond@archlinux.org>
pkgname=caffe-cuda
-_srcname=caffe
pkgver=1.0
-pkgrel=8
+pkgrel=9
pkgdesc='A deep learning framework made with expression, speed, and modularity in mind (with cuda support)'
arch=('x86_64')
url='https://caffe.berkeleyvision.org/'
@@ -25,41 +24,38 @@ optdepends=(
makedepends=('boost' 'doxygen' 'texlive-core' 'texlive-latexextra' 'ghostscript')
provides=('caffe')
conflicts=('caffe')
-source=("${_srcname}-${pkgver}.tar.gz"::"https://github.com/BVLC/caffe/archive/${pkgver}.tar.gz"
+source=("caffe-${pkgver}.tar.gz"::"https://github.com/BVLC/caffe/archive/${pkgver}.tar.gz"
'Makefile.config'
'caffe-1.0-opencv4-fix.patch')
sha256sums=('71d3c9eb8a183150f965a465824d01fe82826c22505f7aa314f700ace03fa77f'
- 'ec7e3ce95966682b6fa05ec98b4fc924f4cef15358ddf17f076d36ea01e4fb18'
+ 'eefbefb25d99e801066526eabd57ed11efd05d0f6e312e40cd030d3a13f06ed4'
'2072c8ca1393b53ef280a15c43af940cc9bf1419ae32b3d8a6541b10b8cb50e9')
prepare() {
- cp -af "${srcdir}/Makefile.config" "${srcdir}/${_srcname}-${pkgver}"
+ cp -af Makefile.config "caffe-${pkgver}"
# fix build with opencv 4
- cd "${_srcname}-${pkgver}"
- patch -Np1 -i "${srcdir}/caffe-1.0-opencv4-fix.patch"
+ # https://github.com/BVLC/caffe/pull/6625
+ patch -d "caffe-${pkgver}" -Np1 -i "${srcdir}/caffe-1.0-opencv4-fix.patch"
}
build() {
- cd "${_srcname}-${pkgver}"
-
- make all pycaffe test
- rm -rf doxygen
- make docs distribute
+ make -C "caffe-${pkgver}" all pycaffe test
+ rm -rf "caffe-${pkgver}/doxygen"
+ make -C "caffe-${pkgver}" docs distribute
}
check() {
- cd "${_srcname}-${pkgver}"
- make runtest
+ make -C "caffe-${pkgver}" runtest
}
package() {
- cd "${_srcname}-${pkgver}/distribute"
+ cd "caffe-${pkgver}/distribute"
- local _pythonver
- _pythonver="$(python -c 'import sys; print("%s.%s" %sys.version_info[0:2])')"
+ local _pyver
+ _pyver="$(python -c 'import sys; print("%s.%s" %sys.version_info[0:2])')"
- mkdir -p "$pkgdir"/usr/{bin,include,lib/python"$_pythonver"/site-packages,share/doc}
+ mkdir -p "$pkgdir"/usr/{bin,include,lib/python"$_pyver"/site-packages,share/doc}
# binaries
install -m755 bin/* "${pkgdir}/usr/bin"
@@ -73,12 +69,12 @@ package() {
# python
install -m755 python/*.py "${pkgdir}/usr/bin"
- cp -a python/caffe "${pkgdir}/usr/lib/python${_pythonver}/site-packages"
+ cp -a python/caffe "${pkgdir}/usr/lib/python${_pyver}/site-packages"
# proto
install -D -m644 proto/caffe.proto -t "${pkgdir}/usr/share/caffe"
- cd "${srcdir}/${_srcname}-${pkgver}"
+ cd "${srcdir}/caffe-${pkgver}"
# docs
cp -a doxygen/html "${pkgdir}/usr/share/doc/${pkgname}"