import gnome-color-manager-3.28.0-3.el8

This commit is contained in:
CentOS Sources 2020-04-28 05:33:19 -04:00 committed by Andrew Lukoshko
parent 52433c1b83
commit 726b29ecf0
2 changed files with 54 additions and 1 deletions

View File

@ -0,0 +1,41 @@
diff --git a/src/gcm-helper-exiv.cpp b/src/gcm-helper-exiv.cpp
index 9854e79..7ec6994 100644
--- a/src/gcm-helper-exiv.cpp
+++ b/src/gcm-helper-exiv.cpp
@@ -21,6 +21,12 @@
#include <exiv2/image.hpp>
#include <exiv2/exif.hpp>
+
+#if EXIV2_MAJOR_VERSION >= 1 || (EXIV2_MAJOR_VERSION == 0 && EXIV2_MINOR_VERSION >= 27)
+#define HAVE_EXIV2_ERROR_CODE
+#include <exiv2/error.hpp>
+#endif
+
#include <iostream>
#include <iomanip>
@@ -51,7 +57,11 @@ main (int argc, char* const argv[])
if (argc == 2)
filename = argv[1];
if (filename.empty())
+#ifdef HAVE_EXIV2_ERROR_CODE
+ throw Exiv2::Error(Exiv2::kerErrorMessage, "No filename specified");
+#else
throw Exiv2::Error(1, "No filename specified");
+#endif
image = Exiv2::ImageFactory::open(filename);
image->readMetadata();
@@ -60,7 +70,11 @@ main (int argc, char* const argv[])
if (exifData.empty()) {
std::string error(argv[1]);
error += ": No Exif data found in the file";
+#ifdef HAVE_EXIV2_ERROR_CODE
+ throw Exiv2::Error(Exiv2::kerErrorMessage, error);
+#else
throw Exiv2::Error(1, error);
+#endif
}
/* try to find make, model and serial number */

View File

@ -1,12 +1,14 @@
Name: gnome-color-manager
Version: 3.28.0
Release: 1%{?dist}
Release: 3%{?dist}
Summary: Color management tools for GNOME
License: GPLv2+
URL: http://mail.gnome.org/mailman/listinfo/gnome-color-manager-list
Source0: http://download.gnome.org/sources/gnome-color-manager/3.28/%{name}-%{version}.tar.xz
Patch0: gnome-color-manager-exiv2-027.patch
BuildRequires: gtk3-devel >= 3.0.0
BuildRequires: desktop-file-utils
BuildRequires: gettext
@ -42,6 +44,8 @@ and generate color profiles in the GNOME desktop.
%prep
%setup -q
%patch0 -p1 -b .exiv2-027
%build
%meson
%meson_build
@ -73,6 +77,14 @@ and generate color profiles in the GNOME desktop.
%{_mandir}/man1/*.1*
%changelog
* Tue Oct 29 2019 Tomas Pelka <tpelka@redhat.com> - 3.28.0-3
- Rebuild again to correctly trigger side-tag gating (exiv2)
Resolves: bz#1757445
* Tue Oct 15 2019 Jan Grulich <jgrulich@redhat.com> - 3.28.0-2
- Rebuild (exiv2)
Resolves: bz#1757445
* Mon Mar 12 2018 Kalev Lember <klember@redhat.com> - 3.28.0-1
- Update to 3.28.0