forked from pool/hugin
Accepting request 1099040 from graphics
- Add fix_build_with_exiv2_0-28.pach, fixing build with exiv2-0.28 (forwarded request 1096982 from tux93) OBS-URL: https://build.opensuse.org/request/show/1099040 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/hugin?expand=0&rev=78
This commit is contained in:
commit
c02b78d91d
90
fix_build_with_exiv2_0-28.pach
Normal file
90
fix_build_with_exiv2_0-28.pach
Normal file
@ -0,0 +1,90 @@
|
||||
diff --git a/src/hugin_base/panodata/Exiv2Helper.cpp b/src/hugin_base/panodata/Exiv2Helper.cpp
|
||||
--- a/src/hugin_base/panodata/Exiv2Helper.cpp
|
||||
+++ b/src/hugin_base/panodata/Exiv2Helper.cpp
|
||||
@@ -40,7 +40,11 @@
|
||||
Exiv2::ExifData::iterator itr = exifData.findKey(Exiv2::ExifKey(keyName));
|
||||
if (itr != exifData.end() && itr->count())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ value = itr->toInt64();
|
||||
+#else
|
||||
value = itr->toLong();
|
||||
+#endif
|
||||
return true;
|
||||
}
|
||||
else
|
||||
@@ -165,7 +169,11 @@
|
||||
{
|
||||
if(it!=exifData.end() && it->count())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ return it->toInt64();
|
||||
+#else
|
||||
return it->toLong();
|
||||
+#endif
|
||||
}
|
||||
return 0;
|
||||
};
|
||||
diff --git a/src/hugin_base/panodata/SrcPanoImage.cpp b/src/hugin_base/panodata/SrcPanoImage.cpp
|
||||
--- a/src/hugin_base/panodata/SrcPanoImage.cpp
|
||||
+++ b/src/hugin_base/panodata/SrcPanoImage.cpp
|
||||
@@ -384,7 +384,11 @@
|
||||
pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageWidthPixels"));
|
||||
if (pos != xmpData.end())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ croppedWidth = pos->toInt64();
|
||||
+#else
|
||||
croppedWidth = pos->toLong();
|
||||
+#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -394,7 +398,11 @@
|
||||
pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaImageHeightPixels"));
|
||||
if (pos != xmpData.end())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ croppedHeight = pos->toInt64();
|
||||
+#else
|
||||
croppedHeight = pos->toLong();
|
||||
+#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -408,7 +416,11 @@
|
||||
double hfov = 0;
|
||||
if (pos != xmpData.end())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ hfov = 360 * croppedWidth / (double)pos->toInt64();
|
||||
+#else
|
||||
hfov = 360 * croppedWidth / (double)pos->toLong();
|
||||
+#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -419,7 +431,11 @@
|
||||
pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.FullPanoHeightPixels"));
|
||||
if (pos != xmpData.end())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ fullHeight = pos->toInt64();
|
||||
+#else
|
||||
fullHeight = pos->toLong();
|
||||
+#endif
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -430,7 +446,11 @@
|
||||
pos = xmpData.findKey(Exiv2::XmpKey("Xmp.GPano.CroppedAreaTopPixels"));
|
||||
if (pos != xmpData.end())
|
||||
{
|
||||
+#if defined EXIV2_VERSION && EXIV2_TEST_VERSION(0,28,0)
|
||||
+ cropTop = pos->toInt64();
|
||||
+#else
|
||||
cropTop = pos->toLong();
|
||||
+#endif
|
||||
}
|
||||
else
|
||||
{
|
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 5 15:41:15 UTC 2023 - Marcel Kuehlhorn <tux93@opensuse.org>
|
||||
|
||||
- Add fix_build_with_exiv2_0-28.pach, fixing build with exiv2-0.28
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Dec 24 18:00:39 UTC 2022 - Petr Vorel <pvorel@suse.cz>
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package hugin
|
||||
#
|
||||
# Copyright (c) 2022 SUSE LLC
|
||||
# Copyright (c) 2023 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -31,6 +31,8 @@ Group: Productivity/Graphics/Other
|
||||
URL: http://hugin.sourceforge.net/
|
||||
Source: https://downloads.sourceforge.net/project/%{name}/%{name}/%{name}-%{mversion}/%{name}-%{version}.tar.bz2
|
||||
Patch0: hugin.appdata.patch
|
||||
# PATCH-FIX-UPSTREAM fix build with exiv2-0.28
|
||||
Patch1: fix_build_with_exiv2_0-28.pach
|
||||
BuildRequires: Mesa-devel
|
||||
BuildRequires: OpenEXR-devel
|
||||
BuildRequires: cmake >= 3.1.0
|
||||
|
Loading…
x
Reference in New Issue
Block a user