commit 1893d213c51584ae99609cbd53344c469fdd3986
Author: leigh123linux <leigh123linux(a)googlemail.com>
Date: Mon Mar 12 12:10:22 2018 +0000
Patch for new tinyxml2
kodi-pvr-vbox-3.6.12-tinyxml2_v4.patch | 48 ++++++++++++++++++++++++++++++++++
kodi-pvr-vbox.spec | 10 ++++++-
2 files changed, 57 insertions(+), 1 deletion(-)
---
diff --git a/kodi-pvr-vbox-3.6.12-tinyxml2_v4.patch
b/kodi-pvr-vbox-3.6.12-tinyxml2_v4.patch
new file mode 100644
index 0000000..1e03ce9
--- /dev/null
+++ b/kodi-pvr-vbox-3.6.12-tinyxml2_v4.patch
@@ -0,0 +1,48 @@
+--- ./src/vbox/CategoryGenreMapper.cpp.orig
++++ ./src/vbox/CategoryGenreMapper.cpp
+@@ -75,7 +75,7 @@
+ std::unique_ptr<std::string> contents =
utilities::ReadFileContents(fileHandle);
+
+ // Try to parse the document
+- if (document.Parse(contents->c_str(), contents->size()) != XML_NO_ERROR)
++ if (document.Parse(contents->c_str(), contents->size()) != XML_SUCCESS)
+ throw vbox::InvalidXMLException("XML parsing failed: " +
std::string(document.ErrorName()));
+
+ // Create mappings
+
+--- ./src/vbox/GuideChannelMapper.cpp.orig
++++ ./src/vbox/GuideChannelMapper.cpp
+@@ -88,7 +88,7 @@
+ std::unique_ptr<std::string> contents =
utilities::ReadFileContents(fileHandle);
+
+ // Try to parse the document
+- if (document.Parse(contents->c_str(), contents->size()) != XML_NO_ERROR)
++ if (document.Parse(contents->c_str(), contents->size()) != XML_SUCCESS)
+ throw vbox::InvalidXMLException("XML parsing failed: " +
std::string(document.ErrorName()));
+
+ // Create mappings
+
+--- ./src/vbox/ReminderManager.cpp.orig
++++ ./src/vbox/ReminderManager.cpp
+@@ -203,7 +203,7 @@
+ std::unique_ptr<std::string> contents =
utilities::ReadFileContents(fileHandle);
+
+ // Try to parse the document
+- if (document.Parse(contents->c_str(), contents->size()) != XML_NO_ERROR)
++ if (document.Parse(contents->c_str(), contents->size()) != XML_SUCCESS)
+ throw vbox::InvalidXMLException("XML parsing failed: " +
std::string(document.ErrorName()));
+
+ unsigned int minsBeforePop = g_vbox->GetSettings().m_remindMinsBeforeProg;
+
+--- ./src/vbox/response/Response.cpp.orig
++++ ./src/vbox/response/Response.cpp
+@@ -43,7 +43,7 @@
+ void Response::ParseRawResponse(const std::string &rawResponse)
+ {
+ // Try to parse the response as XML
+- if (m_document->Parse(rawResponse.c_str(), rawResponse.size()) != XML_NO_ERROR)
++ if (m_document->Parse(rawResponse.c_str(), rawResponse.size()) != XML_SUCCESS)
+ throw vbox::InvalidXMLException("XML parsing failed: " +
std::string(m_document->ErrorName()));
+
+ // Parse the response status
+
diff --git a/kodi-pvr-vbox.spec b/kodi-pvr-vbox.spec
index 5a6eb1b..f4462b4 100644
--- a/kodi-pvr-vbox.spec
+++ b/kodi-pvr-vbox.spec
@@ -7,7 +7,7 @@
Name: kodi-%(tr "." "-" <<<%{kodi_addon})
Version: 3.6.12
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Kodi VBox TV Gateway PVR addon
Group: Applications/Multimedia
@@ -17,6 +17,11 @@ Source0:
https://github.com/kodi-pvr/%{kodi_addon}/archive/%{short_commit
# Use external tinyxml2 library
Patch0: %{name}-3.6.10-use_external_tinyxml2.patch
+%if 0%{?fedora} >= 28
+# Use XML_SUCCESS enum instead of XML_NO_ERROR, which has been deleted in tinyxml2 4.0
+Patch1: kodi-pvr-vbox-3.6.12-tinyxml2_v4.patch
+%endif
+
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: kodi-devel >= %{kodi_version}
@@ -57,6 +62,9 @@ rm -r lib/tinyxml2/
%changelog
+* Mon Mar 12 2018 Leigh Scott <leigh123linux(a)googlemail.com> - 3.6.12-3
+- Patch for new tinyxml2
+
* Thu Mar 01 2018 RPM Fusion Release Engineering <leigh123linux(a)googlemail.com> -
3.6.12-2
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild