summaryrefslogtreecommitdiff
path: root/extra/opencv
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-11-05 01:22:33 -0800
committerroot <root@rshg054.dnsready.net>2012-11-05 01:22:33 -0800
commitc973e7aa43bb6c3bb4e25503eea40ddee63fcefd (patch)
treee85abee1aa1274c3d6a6f317c1a7f9df28e483f4 /extra/opencv
parent2030e810a5cfd4d3ff6e0f8930560c96f2990eb2 (diff)
Mon Nov 5 01:19:20 PST 2012
Diffstat (limited to 'extra/opencv')
-rw-r--r--extra/opencv/PKGBUILD29
-rw-r--r--extra/opencv/pkgconfig.patch35
2 files changed, 47 insertions, 17 deletions
diff --git a/extra/opencv/PKGBUILD b/extra/opencv/PKGBUILD
index 9bc79f877..229c21a0d 100644
--- a/extra/opencv/PKGBUILD
+++ b/extra/opencv/PKGBUILD
@@ -1,37 +1,32 @@
-# $Id: PKGBUILD 169755 2012-10-27 23:42:14Z eric $
+# $Id: PKGBUILD 170195 2012-11-04 17:25:47Z schiv $
# Maintainer: Ray Rashif <schiv@archlinux.org>
# Contributor: Tobias Powalowski <tpowa@archlinux.org>
pkgbase=opencv
pkgname=('opencv' 'opencv-docs' 'opencv-samples')
_realname=OpenCV
-pkgver=2.4.2
-pkgrel=5
+pkgver=2.4.3
+pkgrel=1
pkgdesc="Open Source Computer Vision Library"
arch=('i686' 'x86_64')
license=('BSD')
url="http://opencv.org/"
-depends=('jasper' 'gstreamer0.10-base' 'openexr>=1.7.0'
- 'gtk2' 'xine-lib' 'libdc1394' 'v4l-utils' 'ilmbase>=1.0.3')
+depends=('jasper' 'gstreamer0.10-base' 'gtk2'
+ 'xine-lib' 'libdc1394' 'openexr')
makedepends=('cmake' 'python2-numpy' 'eigen2')
optdepends=('opencv-docs'
'opencv-samples'
'eigen2'
'python2-numpy: Python 2.x interface')
-options=('!libtool')
-source=("http://downloads.sourceforge.net/opencvlibrary/$_realname-${pkgver}.tar.bz2")
-md5sums=('059ef86fc1724d69b75832a0d2929ff5')
+source=("http://downloads.sourceforge.net/opencvlibrary/$_realname-${pkgver}.tar.bz2"
+ 'pkgconfig.patch')
+md5sums=('c0a5af4ff9d0d540684c0bf00ef35dbe'
+ 'cb916260b5ec594fe7a0cc2e54fc569f')
_cmakeopts=('-D CMAKE_BUILD_TYPE=Release'
'-D CMAKE_INSTALL_PREFIX=/usr'
'-D CMAKE_SKIP_RPATH=ON'
'-D BUILD_TESTS=OFF'
- '-D ENABLE_SSE=ON'
- '-D ENABLE_SSE2=ON'
- '-D ENABLE_SSE3=OFF'
- '-D ENABLE_SSSE3=OFF'
- '-D ENABLE_SSE41=OFF'
- '-D ENABLE_SSE42=OFF'
'-D BUILD_EXAMPLES=ON'
'-D INSTALL_C_EXAMPLES=ON'
'-D INSTALL_PYTHON_EXAMPLES=ON'
@@ -49,9 +44,9 @@ _cmakeopts=('-D CMAKE_BUILD_TYPE=Release'
build() {
cd "$srcdir/$_realname-$pkgver"
- # x64, i.e "Athlon64" and upwards, can use SSE3
- [ $CARCH = x86_64 ] && \
- _cmakeopts=${_cmakeopts[@]/ENABLE_SSE3=OFF/ENABLE_SSE3=ON}
+ # fix pkg-config mess
+ # see https://bugs.archlinux.org/task/32430
+ patch -Np1 -i "$srcdir/pkgconfig.patch"
cmake ${_cmakeopts[@]} .
diff --git a/extra/opencv/pkgconfig.patch b/extra/opencv/pkgconfig.patch
new file mode 100644
index 000000000..84d268e61
--- /dev/null
+++ b/extra/opencv/pkgconfig.patch
@@ -0,0 +1,35 @@
+diff -Nbaur OpenCV-2.4.3.orig/cmake/OpenCVGenPkgconfig.cmake OpenCV-2.4.3/cmake/OpenCVGenPkgconfig.cmake
+--- OpenCV-2.4.3.orig/cmake/OpenCVGenPkgconfig.cmake 2012-11-04 08:40:14.243505926 +0000
++++ OpenCV-2.4.3/cmake/OpenCVGenPkgconfig.cmake 2012-11-04 08:40:42.286649120 +0000
+@@ -10,7 +10,7 @@
+ # -------------------------------------------------------------------------------------------
+ set(prefix "${CMAKE_INSTALL_PREFIX}")
+ set(exec_prefix "\${prefix}")
+-set(libdir "") #TODO: need link paths for OpenCV_EXTRA_COMPONENTS
++set(libdir "\${prefix}/${OPENCV_LIB_INSTALL_PATH}")
+ set(includedir "\${prefix}/${OPENCV_INCLUDE_INSTALL_PATH}")
+ set(VERSION ${OPENCV_VERSION})
+
+@@ -36,10 +36,11 @@
+ ocv_list_reverse(OpenCV_EXTRA_COMPONENTS)
+
+ #build the list of components
+-set(OpenCV_LIB_COMPONENTS_ "")
++set(OpenCV_LIB_COMPONENTS_ "-L\${libdir}")
+ foreach(CVLib ${OpenCV_LIB_COMPONENTS})
+ get_target_property(libpath ${CVLib} LOCATION_${CMAKE_BUILD_TYPE})
+ get_filename_component(libname "${libpath}" NAME)
++ get_filename_component(lname "${libpath}" NAME_WE)
+
+ if(INSTALL_TO_MANGLED_PATHS)
+ set(libname "${libname}.${OPENCV_VERSION}")
+@@ -52,7 +53,8 @@
+ set(installDir "${OPENCV_LIB_INSTALL_PATH}")
+ endif()
+
+- set(OpenCV_LIB_COMPONENTS_ "${OpenCV_LIB_COMPONENTS_} \${exec_prefix}/${installDir}/${libname}")
++ string(REPLACE "libopencv" "-lopencv" lname "${lname}")
++ set(OpenCV_LIB_COMPONENTS_ "${OpenCV_LIB_COMPONENTS_} ${lname}")
+ endforeach()
+
+ # add extra dependencies required for OpenCV