Accepting request 209071 from KDE:Extra
Added opencv-pkgconfig.patch: make sure to provide link flags in OpenCV pc file (bnc#853036) OBS-URL: https://build.opensuse.org/request/show/209071 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/opencv?expand=0&rev=47
This commit is contained in:
parent
ceb3478124
commit
2b1552364b
35
opencv-pkgconfig.patch
Normal file
35
opencv-pkgconfig.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
diff -baur opencv-2.4.7.orig/cmake/OpenCVGenPkgconfig.cmake opencv-2.4.7/cmake/OpenCVGenPkgconfig.cmake
|
||||||
|
--- opencv-2.4.7.orig/cmake/OpenCVGenPkgconfig.cmake 2013-11-12 20:31:27.253763202 +0000
|
||||||
|
+++ opencv-2.4.7/cmake/OpenCVGenPkgconfig.cmake 2013-11-12 20:41:48.936262732 +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}")
|
||||||
|
|
||||||
|
if(CMAKE_BUILD_TYPE MATCHES "Release")
|
||||||
|
@@ -35,10 +35,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}")
|
||||||
|
@@ -51,7 +52,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
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sun Dec 1 17:37:36 UTC 2013 - hrvoje.senjan@gmail.com
|
||||||
|
|
||||||
|
- Added opencv-pkgconfig.patch: make sure to provide link flags in
|
||||||
|
OpenCV pc file (bnc#853036)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Nov 12 23:07:23 UTC 2013 - hrvoje.senjan@gmail.com
|
Tue Nov 12 23:07:23 UTC 2013 - hrvoje.senjan@gmail.com
|
||||||
|
|
||||||
|
@ -35,6 +35,9 @@ Patch1: %{name}-samples.patch
|
|||||||
Patch2: %{name}-underlinking.patch
|
Patch2: %{name}-underlinking.patch
|
||||||
# PATCH-FIX-OPENSUSE improve-sphinx-search.diff -- properly find sphinx with alphabetic chars in version
|
# PATCH-FIX-OPENSUSE improve-sphinx-search.diff -- properly find sphinx with alphabetic chars in version
|
||||||
Patch3: improve-sphinx-search.diff
|
Patch3: improve-sphinx-search.diff
|
||||||
|
# PATCH-FIX-UPSTREAM opencv-pkgconfig.patch -- Make sure to provide link flags in OpenCV pc file (bnc#853036). Issue is exposed when e.g. a project relies on
|
||||||
|
# getting opencv vars via pc (first), and then via CMake, as is the case with nomacs
|
||||||
|
Patch4: opencv-pkgconfig.patch
|
||||||
BuildRequires: cmake
|
BuildRequires: cmake
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: gstreamer-0_10-plugins-base-devel
|
BuildRequires: gstreamer-0_10-plugins-base-devel
|
||||||
@ -120,6 +123,7 @@ This package contains the documentation and examples for the OpenCV library.
|
|||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
%patch3 -p0
|
%patch3 -p0
|
||||||
|
%patch4 -p1
|
||||||
|
|
||||||
# Remove Windows specific files
|
# Remove Windows specific files
|
||||||
rm -f doc/packaging.txt
|
rm -f doc/packaging.txt
|
||||||
|
Loading…
Reference in New Issue
Block a user