extra/opencv to 4.0.1-3

This commit is contained in:
Kevin Mihelich 2019-01-06 16:44:12 +00:00
parent 925db9728e
commit ed7b800fdd

View file

@ -7,19 +7,20 @@
pkgbase=opencv
pkgname=(opencv opencv-samples)
pkgver=4.0.1
pkgrel=2
pkgrel=3
pkgdesc="Open Source Computer Vision Library"
arch=(x86_64)
license=(BSD)
url="http://opencv.org/"
depends=(intel-tbb openexr gst-plugins-base libdc1394 cblas lapack libgphoto2 jasper ffmpeg)
makedepends=(cmake python-numpy python-setuptools mesa eigen hdf5 lapacke gtk3 vtk glew)
makedepends=(cmake python-numpy python-setuptools mesa eigen hdf5 lapacke gtk3 vtk glew ant java-environment)
optdepends=('opencv-samples: samples'
'gtk3: for the HighGUI module'
'vtk: for the viz module'
'hdf5: support for HDF5 format'
'opencl-icd-loader: For coding with OpenCL'
'python-numpy: Python interface')
'python-numpy: Python interface'
'java-runtime: Java interface')
source=("$pkgbase-$pkgver.tar.gz::https://github.com/opencv/opencv/archive/$pkgver.zip"
"opencv_contrib-$pkgver.tar.gz::https://github.com/opencv/opencv_contrib/archive/$pkgver.tar.gz")
sha256sums=('b79ccdc4797a959c5ab17249a8a302c066248ae070e4d7010e2d77a625fdb30a'
@ -31,6 +32,7 @@ prepare() {
build() {
cd build
export JAVA_HOME="/usr/lib/jvm/default"
# cmake's FindLAPACK doesn't add cblas to LAPACK_LIBRARIES, so we need to specify them manually
_pythonpath=`python -c "from sysconfig import get_path; print(get_path('platlib'))"`
cmake ../$pkgname-$pkgver \
@ -53,7 +55,8 @@ build() {
-DLAPACK_CBLAS_H="/usr/include/cblas.h" \
-DLAPACK_LAPACKE_H="/usr/include/lapacke.h" \
-DOPENCV_GENERATE_PKGCONFIG=ON \
-DOPENCV_ENABLE_NONFREE=ON
-DOPENCV_ENABLE_NONFREE=ON \
-DOPENCV_JNI_INSTALL_PATH=lib
make
}