summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Bermond2019-11-20 23:41:07 +0000
committerDaniel Bermond2019-11-20 23:41:07 +0000
commitdee6d8c58f9526488e0a68f8f42aa759f92070a5 (patch)
tree134e8808145e5b9b7993fa34ffe4ce2c1560a268
parent0ab4024105d4d5345a42fdd5b5fea66297ca841e (diff)
downloadaur-dee6d8c58f9526488e0a68f8f42aa759f92070a5.tar.gz
Update Makefile for python 3.8. Cosmetic changes.
-rw-r--r--.SRCINFO4
-rw-r--r--Makefile.config4
-rw-r--r--PKGBUILD38
3 files changed, 21 insertions, 25 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ddf9b65f9b3..28e26f224ed 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = caffe-cuda
pkgdesc = A deep learning framework made with expression, speed, and modularity in mind (with cuda support)
pkgver = 1.0
- pkgrel = 8
+ pkgrel = 9
url = https://caffe.berkeleyvision.org/
arch = x86_64
license = BSD
@@ -48,7 +48,7 @@ pkgbase = caffe-cuda
source = Makefile.config
source = caffe-1.0-opencv4-fix.patch
sha256sums = 71d3c9eb8a183150f965a465824d01fe82826c22505f7aa314f700ace03fa77f
- sha256sums = ec7e3ce95966682b6fa05ec98b4fc924f4cef15358ddf17f076d36ea01e4fb18
+ sha256sums = eefbefb25d99e801066526eabd57ed11efd05d0f6e312e40cd030d3a13f06ed4
sha256sums = 2072c8ca1393b53ef280a15c43af940cc9bf1419ae32b3d8a6541b10b8cb50e9
pkgname = caffe-cuda
diff --git a/Makefile.config b/Makefile.config
index f30fd693a01..d4bf065c01a 100644
--- a/Makefile.config
+++ b/Makefile.config
@@ -26,8 +26,8 @@ CUDA_ARCH := -gencode arch=compute_30,code=sm_30 \
BLAS := open
BLAS_INCLUDE := /usr/include
BLAS_LIB := /usr/lib
-PYTHON_LIBRARIES := boost_python$(_PYMAJ) python$(_PYVER)m
-PYTHON_INCLUDE := /usr/include/python$(_PYVER)m \
+PYTHON_LIBRARIES := boost_python$(_PYMAJ) python$(_PYVER)
+PYTHON_INCLUDE := /usr/include/python$(_PYVER) \
/usr/lib/python$(_PYVER)/site-packages/numpy/core/include
PYTHON_LIB := /usr/lib
WITH_PYTHON_LAYER := 1
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}"