]> git.pld-linux.org Git - packages/exiv2.git/commitdiff
- cmake hacking replaced by no-xmpsdk-install patch
authorJakub Bogusz <qboosh@pld-linux.org>
Sun, 3 Mar 2019 13:51:16 +0000 (14:51 +0100)
committerJakub Bogusz <qboosh@pld-linux.org>
Sun, 3 Mar 2019 13:51:16 +0000 (14:51 +0100)
- obsolete -static

exiv2-no-xmpsdk-install.patch [new file with mode: 0644]
exiv2.spec

diff --git a/exiv2-no-xmpsdk-install.patch b/exiv2-no-xmpsdk-install.patch
new file mode 100644 (file)
index 0000000..e21b641
--- /dev/null
@@ -0,0 +1,23 @@
+--- exiv2-0.27.0-Source/xmpsdk/CMakeLists.txt.orig     2018-12-20 14:45:17.000000000 +0100
++++ exiv2-0.27.0-Source/xmpsdk/CMakeLists.txt  2019-03-03 11:01:53.674620695 +0100
+@@ -50,9 +50,3 @@
+ if (BUILD_SHARED_LIBS)
+     set_property(TARGET xmp PROPERTY POSITION_INDEPENDENT_CODE ON)
+ endif()
+-
+-# 1119  Install libxmp.a for use by third party applications (Thanks, Emmanuel)
+-install(TARGETS xmp EXPORT exiv2Config
+-        LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
+-        ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
+-)
+--- exiv2-0.27.0-Source/src/CMakeLists.txt.orig        2018-12-20 14:45:16.000000000 +0100
++++ exiv2-0.27.0-Source/src/CMakeLists.txt     2019-03-03 13:59:23.100261141 +0100
+@@ -147,7 +147,7 @@
+ target_include_directories(exiv2lib PRIVATE ${ZLIB_INCLUDE_DIR})
+ if (EXIV2_ENABLE_XMP)
+-    target_link_libraries(exiv2lib PUBLIC xmp)
++    target_link_libraries(exiv2lib PRIVATE xmp)
+ elseif(EXIV2_ENABLE_EXTERNAL_XMP)
+     target_link_libraries(exiv2lib PUBLIC ${XMPSDK_LIBRARY})
+     target_include_directories(exiv2lib PUBLIC ${XMPSDK_INCLUDE_DIR})
index d928ec3b4fe18109774c9bc4efc91f36b3b432f6..2e1383cb8899564b2e7d90fffd7dd76e041022bf 100644 (file)
@@ -14,6 +14,7 @@ Group:                Applications/Graphics
 Source0:       http://www.exiv2.org/builds/%{name}-%{version}-Source.tar.gz
 # Source0-md5: b7f49949deafa96a9e6a22d42bd91031
 Patch0:                cmake.patch
+Patch1:                %{name}-no-xmpsdk-install.patch
 URL:           http://www.exiv2.org/
 BuildRequires: cmake >= 3.3.2
 %{?with_curl:BuildRequires:    curl-devel}
@@ -52,6 +53,7 @@ Requires:     expat-devel
 %{?with_libssh:Requires:       libssh-devel}
 Requires:      libstdc++-devel
 Requires:      zlib-devel
+Obsoletes:     exiv2-static
 
 %description devel
 EXIF and IPTC metadata manipulation library development files.
@@ -62,6 +64,7 @@ Pliki programistyczne biblioteki do obróbki metadanych EXIF i IPTC.
 %prep
 %setup -q -n %{name}-0.27.0-Source
 %patch0 -p1
+%patch1 -p1
 
 %build
 install -d build
@@ -77,21 +80,6 @@ cd build
 %endif
 
 %{__make}
-cd ..
-
-# Regenerate exiv2Config.cmake without references to libxmp.a
-install -d build-cmake
-cd build-cmake
-%cmake .. \
-       -DEXIV2_BUILD_PO=ON \
-       -DEXIV2_BUILD_SAMPLES=OFF \
-       %{?with_curl:-DEXIV2_ENABLE_CURL=ON} \
-       %{?with_libssh:-DEXIV2_ENABLE_SSH=ON} \
-       -DEXIV2_ENABLE_VIDEO=ON \
-       -DEXIV2_ENABLE_XMP=OFF \
-%if %{with curl} || %{with libssh}
-       -DEXIV2_ENABLE_WEBREADY=ON
-%endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -99,13 +87,6 @@ rm -rf $RPM_BUILD_ROOT
 %{__make} -C build install \
        DESTDIR=$RPM_BUILD_ROOT
 
-# internally used Adobe XMP SDK
-%{__rm} $RPM_BUILD_ROOT%{_libdir}/libxmp.a
-
-%{__rm} $RPM_BUILD_ROOT%{_libdir}/cmake/exiv2/exiv2Config{,-pld}.cmake
-cp -p build-cmake/src/CMakeFiles/Export/_usr/%{_lib}/cmake/exiv2/exiv2Config{,-pld}.cmake \
-       $RPM_BUILD_ROOT%{_libdir}/cmake/exiv2/
-
 %find_lang %{name}
 
 %clean
This page took 0.31542 seconds and 4 git commands to generate.