- fix building with exiv2 0.27
authorJan Rękorajski <baggins@pld-linux.org>
Mon, 11 Feb 2019 22:29:21 +0000 (23:29 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Mon, 11 Feb 2019 22:29:21 +0000 (23:29 +0100)
digikam.spec
exiv2-0.27.patch [new file with mode: 0644]

index 65c4a40..4cbbcc4 100644 (file)
@@ -11,6 +11,7 @@ License:      GPL
 Group:         X11/Applications/Graphics
 Source0:       http://download.kde.org/stable/digikam/%{name}-%{version}.tar.xz
 # Source0-md5: 7811cc633e7e1770d1d9860fa36ea251
+Patch0:                exiv2-0.27.patch
 URL:           http://www.digikam.org/
 BuildRequires: ImageMagick-devel
 BuildRequires: clapack-devel
@@ -22,8 +23,13 @@ BuildRequires:       jasper-devel
 BuildRequires: java-opencv
 BuildRequires: kf5-kcoreaddons-devel
 BuildRequires: kf5-kdoctools >= 5.38.0
+BuildRequires: kf5-extra-cmake-modules
+BuildRequires: ka5-libkipi-devel
+BuildRequires: kf5-kdoctools-devel
 BuildRequires: kf5-kfilemetadata-devel
+BuildRequires: kf5-ki18n-devel
 BuildRequires: kf5-kiconthemes-devel
+BuildRequires: kf5-kio-devel
 BuildRequires: kf5-knotifications-devel
 BuildRequires: kf5-knotifyconfig-devel
 BuildRequires: kf5-kservice-devel
@@ -74,6 +80,7 @@ Interfejs KDE do gphoto2 - pliki nagłówkowe.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 install -d build
diff --git a/exiv2-0.27.patch b/exiv2-0.27.patch
new file mode 100644 (file)
index 0000000..d8c73a9
--- /dev/null
@@ -0,0 +1,35 @@
+--- digikam-5.9.0/core/cmake/modules/FindExiv2.cmake~  2018-03-19 10:41:56.000000000 +0100
++++ digikam-5.9.0/core/cmake/modules/FindExiv2.cmake   2019-02-11 22:51:15.308354934 +0100
+@@ -54,7 +54,7 @@
+ # Get the version number from exiv2/version.hpp and store it in the cache:
+ if(EXIV2_INCLUDE_DIR  AND NOT  EXIV2_VERSION)
+-  file(READ ${EXIV2_INCLUDE_DIR}/exiv2/version.hpp EXIV2_VERSION_CONTENT)
++  file(READ ${EXIV2_INCLUDE_DIR}/exiv2/exv_conf.h EXIV2_VERSION_CONTENT)
+   string(REGEX MATCH "#define EXIV2_MAJOR_VERSION +\\( *([0-9]+) *\\)"  _dummy "${EXIV2_VERSION_CONTENT}")
+   set(EXIV2_VERSION_MAJOR "${CMAKE_MATCH_1}")
+--- digikam-5.9.0/core/libs/dmetadata/metaengine_p.h~  2018-03-19 10:41:58.000000000 +0100
++++ digikam-5.9.0/core/libs/dmetadata/metaengine_p.h   2019-02-11 23:13:30.270882447 +0100
+@@ -70,6 +70,7 @@
+ #include <exiv2/types.hpp>
+ #include <exiv2/exif.hpp>
+ #include <exiv2/xmpsidecar.hpp>
++#include <exiv2/version.hpp>
+ // Check if Exiv2 support XMP
+--- digikam-5.9.0/core/libs/dmetadata/metaengine_exif.cpp~     2018-03-19 10:41:58.000000000 +0100
++++ digikam-5.9.0/core/libs/dmetadata/metaengine_exif.cpp      2019-02-11 23:16:52.323399768 +0100
+@@ -1007,7 +1007,11 @@
+         if (pos == d->exifMetadata().end() || pos->count() != 1 || pos->toLong() != 0)
+         {
++#if EXIV2_TEST_VERSION(0,27,0)
++            throw Exiv2::Error(Exiv2::kerErrorMessage, "Exif.Image.NewSubfileType missing or not set as main image");
++#else
+             throw Exiv2::Error(1, "Exif.Image.NewSubfileType missing or not set as main image");
++#endif
+         }
+         // Remove sub-IFD tags
This page took 0.628363 seconds and 4 git commands to generate.