Bug#887931: gazebo FTBFS with libtinyxml2-dev 6.0.0+dfsg-1

peter green plugwash at p10link.net
Thu Jan 25 17:08:39 UTC 2018


Hi

I just applied the upstream patch in raspbian. The patch to the sourcecode applied fine but the patch to the buildsystem had to be applied manually.

A debdiff of what I uploaded to Raspbian is attatched, no intent to NMU in Debian.


-------------- next part --------------
diff -Nru gazebo-7.8.1+dfsg/debian/changelog gazebo-7.8.1+dfsg/debian/changelog
--- gazebo-7.8.1+dfsg/debian/changelog	2017-12-23 17:01:02.000000000 +0000
+++ gazebo-7.8.1+dfsg/debian/changelog	2018-01-25 10:47:54.000000000 +0000
@@ -1,3 +1,9 @@
+gazebo (7.8.1+dfsg-4+rpi1) buster-staging; urgency=medium
+
+  * Add patch for new tinyxml (Closes: 887931)
+
+ -- Peter Michael Green <plugwash at raspbian.org>  Thu, 25 Jan 2018 10:47:54 +0000
+
 gazebo (7.8.1+dfsg-4) unstable; urgency=medium
 
   * Team upload.
diff -Nru gazebo-7.8.1+dfsg/debian/patches/series gazebo-7.8.1+dfsg/debian/patches/series
--- gazebo-7.8.1+dfsg/debian/patches/series	2017-12-23 16:59:45.000000000 +0000
+++ gazebo-7.8.1+dfsg/debian/patches/series	2018-01-25 10:47:20.000000000 +0000
@@ -4,3 +4,4 @@
 strlen.patch
 0005-Add-Q_MOC_RUN-to-work-around-syntax-error.patch
 gazebo-7.4.0-fixmoc.patch
+tinyxml-6.0.0.patch
diff -Nru gazebo-7.8.1+dfsg/debian/patches/tinyxml-6.0.0.patch gazebo-7.8.1+dfsg/debian/patches/tinyxml-6.0.0.patch
--- gazebo-7.8.1+dfsg/debian/patches/tinyxml-6.0.0.patch	1970-01-01 00:00:00.000000000 +0000
+++ gazebo-7.8.1+dfsg/debian/patches/tinyxml-6.0.0.patch	2018-01-25 10:47:54.000000000 +0000
@@ -0,0 +1,46 @@
+Based on https://bitbucket.org/osrf/gazebo/commits/be154a72c765abd6d9517c04cd46c96870edf5c2?at=gazebo8
+Modified by Peter Michael Green to apply to the Debian package.
+# HG changeset patch
+# User Steve Peters <scpeters at openrobotics.org>
+# Date 1513105358 28800
+# Branch tinyxml2_6_gazebo8
+# Node ID be154a72c765abd6d9517c04cd46c96870edf5c2
+# Parent  028285bda338b580f60775c57dfbcb44781538d3
+support tinyxml2 version 6.0.0 on gazebo8
+
+Index: gazebo-7.8.1+dfsg/gazebo/util/CMakeLists.txt
+===================================================================
+--- gazebo-7.8.1+dfsg.orig/gazebo/util/CMakeLists.txt
++++ gazebo-7.8.1+dfsg/gazebo/util/CMakeLists.txt
+@@ -72,5 +72,13 @@ target_link_libraries(gazebo_util
+   ${tinyxml2_LIBRARIES}
+ )
+ 
++# define if tinxml2 major version >= 6
++# https://bitbucket.org/ignitionrobotics/ign-common/issues/28
++if (NOT tinyxml2_VERSION VERSION_LESS "6.0.0")
++  message(STATUS "tinyxml2_VERSION ${tinyxml2_VERSION} >= 6.0.0")
++  target_compile_definitions(gazebo_util
++    PRIVATE "TINYXML2_MAJOR_VERSION_GE_6")
++endif()
++
+ gz_install_library(gazebo_util)
+ gz_install_includes("util" ${headers} ${CMAKE_CURRENT_BINARY_DIR}/util.hh)
+Index: gazebo-7.8.1+dfsg/gazebo/util/LogPlay.cc
+===================================================================
+--- gazebo-7.8.1+dfsg.orig/gazebo/util/LogPlay.cc
++++ gazebo-7.8.1+dfsg/gazebo/util/LogPlay.cc
+@@ -118,8 +118,13 @@ void LogPlay::Open(const std::string &_l
+   {
+     gzerr << "Unable to load file[" << _logFile << "]. "
+       << "Check the Gazebo server log file for more information.\n";
++#ifdef TINYXML2_MAJOR_VERSION_GE_6
++    const char *errorStr1 = this->dataPtr->xmlDoc.ErrorStr();
++    const char *errorStr2 = nullptr;
++#else
+     const char *errorStr1 = this->dataPtr->xmlDoc.GetErrorStr1();
+     const char *errorStr2 = this->dataPtr->xmlDoc.GetErrorStr2();
++#endif
+     if (errorStr1)
+       gzlog << "Log Error 1:\n" << errorStr1 << std::endl;
+     if (errorStr2)


More information about the debian-science-maintainers mailing list