Tags 887929 +patch
Thanks

From looking at a patch for another package with much the same problem ( 
https://bitbucket.org/osrf/gazebo/commits/be154a72c765abd6d9517c04cd46c96870edf5c2?at=gazebo8 ) it seems that 
"GetErrorStr1" and "GetErrorStr2" have been replaced by "ErrorStr".

I whipped up a patch for trigger-rally based on this and it built successfully 
for Raspbian buster. I have not tested whether or not the resulting package 
actually works.

diff -Nru trigger-rally-0.6.5+dfsg/debian/changelog 
trigger-rally-0.6.5+dfsg/debian/changelog
--- trigger-rally-0.6.5+dfsg/debian/changelog   2016-12-20 00:00:50.000000000 
+0000
+++ trigger-rally-0.6.5+dfsg/debian/changelog   2018-01-25 11:16:57.000000000 
+0000
@@ -1,3 +1,11 @@
+trigger-rally (0.6.5+dfsg-2+rpi1) buster-staging; urgency=medium
+
+  * Fix FTBFS with tinyxml2 6.0.0. Fix inspired by 
https://bitbucket.org/osrf/gazebo/commits/be154a72c765abd6d9517c04cd46c96870edf5c2?at=gazebo8
+  * Bump build-dependency because i'm pretty sure fix will break builds with
+    earlier tinyxml2.
+
+ -- Peter Michael Green <[email protected]>  Thu, 25 Jan 2018 11:16:57 
+0000
+
 trigger-rally (0.6.5+dfsg-2) unstable; urgency=medium
 
   * Team upload.
diff -Nru trigger-rally-0.6.5+dfsg/debian/control 
trigger-rally-0.6.5+dfsg/debian/control
--- trigger-rally-0.6.5+dfsg/debian/control     2016-12-20 00:00:50.000000000 
+0000
+++ trigger-rally-0.6.5+dfsg/debian/control     2018-01-25 11:16:57.000000000 
+0000
@@ -9,7 +9,7 @@
  libsdl2-image-dev,
  docbook-to-man,
  libglew-dev,
- libtinyxml2-dev
+ libtinyxml2-dev (>= 6.0.0)
 Standards-Version: 3.9.8
 Uploaders: Stefan Potyra <[email protected]>,
  Barry deFreese <[email protected]>,
diff -Nru trigger-rally-0.6.5+dfsg/debian/patches/libxml2-6.0.0.patch 
trigger-rally-0.6.5+dfsg/debian/patches/libxml2-6.0.0.patch
--- trigger-rally-0.6.5+dfsg/debian/patches/libxml2-6.0.0.patch 1970-01-01 
00:00:00.000000000 +0000
+++ trigger-rally-0.6.5+dfsg/debian/patches/libxml2-6.0.0.patch 2018-01-25 
11:16:57.000000000 +0000
@@ -0,0 +1,31 @@
+Description: Fix FTBFS with tinyxml2 6.0.0. 
+   It looks like "GetErrorStr1" and "GetErrorStr2" were replaced by "ErrorStr"
+   Fix inspired by 
https://bitbucket.org/osrf/gazebo/commits/be154a72c765abd6d9517c04cd46c96870edf5c2?at=gazebo8
+Author: Peter Michael Green <[email protected]>
+
+Index: trigger-rally-0.6.5+dfsg/src/PEngine/util.cpp
+===================================================================
+--- trigger-rally-0.6.5+dfsg.orig/src/PEngine/util.cpp
++++ trigger-rally-0.6.5+dfsg/src/PEngine/util.cpp
+@@ -231,7 +231,7 @@ XMLElement *PUtil::loadRootElement(XMLDo
+   XMLElement *rootelem = doc.FirstChildElement(rootName);
+   if (!rootelem) {
+     PUtil::outLog() << "Load failed: TinyXML error" << std::endl;
+-    PUtil::outLog() << "TinyXML: " << doc.GetErrorStr1() << ", " << 
doc.GetErrorStr2() << std::endl;
++    PUtil::outLog() << "TinyXML: " << doc.ErrorStr() << std::endl;
+     return nullptr;
+   }
+ 
+Index: trigger-rally-0.6.5+dfsg/src/Trigger/main.cpp
+===================================================================
+--- trigger-rally-0.6.5+dfsg.orig/src/Trigger/main.cpp
++++ trigger-rally-0.6.5+dfsg/src/Trigger/main.cpp
+@@ -498,7 +498,7 @@ void MainApp::loadConfig()
+   XMLElement *rootelem = PUtil::loadRootElement(xmlfile, cfgfilename, 
"config");
+   if (!rootelem) {
+     PUtil::outLog() << "Error: Couldn't load configuration file" << std::endl;
+-    PUtil::outLog() << "TinyXML: " << xmlfile.GetErrorStr1() << ", " << 
xmlfile.GetErrorStr2() << std::endl;
++    PUtil::outLog() << "TinyXML: " << xmlfile.ErrorStr() << std::endl;
+     PUtil::outLog() << "Your data paths are probably not set up correctly" << 
std::endl;
+     throw MakePException ("Boink");
+   }
diff -Nru trigger-rally-0.6.5+dfsg/debian/patches/series 
trigger-rally-0.6.5+dfsg/debian/patches/series
--- trigger-rally-0.6.5+dfsg/debian/patches/series      2016-12-20 
00:00:50.000000000 +0000
+++ trigger-rally-0.6.5+dfsg/debian/patches/series      2018-01-25 
11:16:57.000000000 +0000
@@ -1,3 +1,4 @@
 verbose-build.patch
 disable-strip.patch
 20_system_tinyxml.patch
+libxml2-6.0.0.patch

Reply via email to