From 356981400a2babc503a0b6beafcfd80a5c4d531d Mon Sep 17 00:00:00 2001 From: Jose Luis Rivero Date: Fri, 12 Sep 2025 13:29:59 +0200 Subject: [PATCH 1/7] Back to skip the backwards-cpp vendor files when installing Signed-off-by: Jose Luis Rivero --- vendor/backward-cpp/CMakeLists.txt | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/vendor/backward-cpp/CMakeLists.txt b/vendor/backward-cpp/CMakeLists.txt index e625f8ac97..3b18476d5e 100644 --- a/vendor/backward-cpp/CMakeLists.txt +++ b/vendor/backward-cpp/CMakeLists.txt @@ -157,16 +157,16 @@ if(BACKWARD_TESTS) endforeach() endif() -install( - FILES "backward.hpp" - DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} -) -install( - FILES "BackwardConfig.cmake" - DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" -) # check if Backward is being used as a top-level project or included as a subproject if(CMAKE_SOURCE_DIR STREQUAL PROJECT_SOURCE_DIR) + install( + FILES "backward.hpp" + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} + ) + install( + FILES "BackwardConfig.cmake" + DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" + ) # export the targets (note that exporting backward_object does not make sense) install(TARGETS backward_interface backward EXPORT BackwardTargets) # install a CMake file for the exported targets From cf02e9d9c641cf0a40fbd2234850fcca2e9aee6b Mon Sep 17 00:00:00 2001 From: Jose Luis Rivero Date: Fri, 12 Sep 2025 13:30:10 +0200 Subject: [PATCH 2/7] Include a file with Gazebo changes Signed-off-by: Jose Luis Rivero --- .../backward-cpp/GAZEBO_MODIFIED_CODE.patch | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch diff --git a/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch new file mode 100644 index 0000000000..7ce4c65379 --- /dev/null +++ b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch @@ -0,0 +1,38 @@ +Summary: avoid installing backwards file in the system unless being + used as a top level + +Description: do not install backwards files in the Gazebo usage of +the vendor package. See https://github.com/gazebosim/gz-sim/pull/2838. +Upstream PR related: https://github.com/bombela/backward-cpp/pull/338 + +On updates, be sure of preserving this patch. + +diff --git a/vendor/backward-cpp/CMakeLists.txt b/vendor/backward-cpp/CMakeLists.txt +index e625f8ac9..3b18476d5 100644 +--- a/vendor/backward-cpp/CMakeLists.txt ++++ b/vendor/backward-cpp/CMakeLists.txt +@@ -157,16 +157,16 @@ if(BACKWARD_TESTS) + endforeach() + endif() + +-install( +- FILES "backward.hpp" +- DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} +-) +-install( +- FILES "BackwardConfig.cmake" +- DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" +-) + # check if Backward is being used as a top-level project or included as a subproject + if(CMAKE_SOURCE_DIR STREQUAL PROJECT_SOURCE_DIR) ++ install( ++ FILES "backward.hpp" ++ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} ++ ) ++ install( ++ FILES "BackwardConfig.cmake" ++ DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" ++ ) + # export the targets (note that exporting backward_object does not make sense) + install(TARGETS backward_interface backward EXPORT BackwardTargets) + # install a CMake file for the exported targets From eb7b2528405b877b45a7729169e90593e10c0ae6 Mon Sep 17 00:00:00 2001 From: Jose Luis Rivero Date: Thu, 25 Sep 2025 17:17:37 +0200 Subject: [PATCH 3/7] Remove install block in vendor Signed-off-by: Jose Luis Rivero --- vendor/backward-cpp/CMakeLists.txt | 18 -------------- .../backward-cpp/GAZEBO_MODIFIED_CODE.patch | 24 ++++++++----------- 2 files changed, 10 insertions(+), 32 deletions(-) diff --git a/vendor/backward-cpp/CMakeLists.txt b/vendor/backward-cpp/CMakeLists.txt index 3b18476d5e..711637e2db 100644 --- a/vendor/backward-cpp/CMakeLists.txt +++ b/vendor/backward-cpp/CMakeLists.txt @@ -156,21 +156,3 @@ if(BACKWARD_TESTS) backward_add_test(test/${test}.cpp backward.cpp) endforeach() endif() - -# check if Backward is being used as a top-level project or included as a subproject -if(CMAKE_SOURCE_DIR STREQUAL PROJECT_SOURCE_DIR) - install( - FILES "backward.hpp" - DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} - ) - install( - FILES "BackwardConfig.cmake" - DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" - ) - # export the targets (note that exporting backward_object does not make sense) - install(TARGETS backward_interface backward EXPORT BackwardTargets) - # install a CMake file for the exported targets - install(EXPORT BackwardTargets - NAMESPACE Backward:: - DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}") -endif() diff --git a/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch index 7ce4c65379..6d475a59ee 100644 --- a/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch +++ b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch @@ -6,7 +6,6 @@ the vendor package. See https://github.com/gazebosim/gz-sim/pull/2838. Upstream PR related: https://github.com/bombela/backward-cpp/pull/338 On updates, be sure of preserving this patch. - diff --git a/vendor/backward-cpp/CMakeLists.txt b/vendor/backward-cpp/CMakeLists.txt index e625f8ac9..3b18476d5 100644 --- a/vendor/backward-cpp/CMakeLists.txt @@ -15,6 +14,7 @@ index e625f8ac9..3b18476d5 100644 endforeach() endif() +- -install( - FILES "backward.hpp" - DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} @@ -23,16 +23,12 @@ index e625f8ac9..3b18476d5 100644 - FILES "BackwardConfig.cmake" - DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" -) - # check if Backward is being used as a top-level project or included as a subproject - if(CMAKE_SOURCE_DIR STREQUAL PROJECT_SOURCE_DIR) -+ install( -+ FILES "backward.hpp" -+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} -+ ) -+ install( -+ FILES "BackwardConfig.cmake" -+ DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}" -+ ) - # export the targets (note that exporting backward_object does not make sense) - install(TARGETS backward_interface backward EXPORT BackwardTargets) - # install a CMake file for the exported targets +-# check if Backward is being used as a top-level project or included as a subproject +-if(CMAKE_SOURCE_DIR STREQUAL PROJECT_SOURCE_DIR) +- # export the targets (note that exporting backward_object does not make sense) +- install(TARGETS backward_interface backward EXPORT BackwardTargets) +- # install a CMake file for the exported targets +- install(EXPORT BackwardTargets +- NAMESPACE Backward:: +- DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}") +-endif() From f6e26407b69c5a1395916fcbf376abdfd9e1c4e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20Ag=C3=BCero?= Date: Mon, 29 Sep 2025 16:07:13 +0200 Subject: [PATCH 4/7] Changelog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Carlos Agüero --- Changelog.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Changelog.md b/Changelog.md index 5f41a3a284..2fceb4fad8 100644 --- a/Changelog.md +++ b/Changelog.md @@ -4,6 +4,9 @@ 1. **Baseline:** this includes all changes from 9.3.0 and earlier. +1. Don't install vendored backward files + * [Pull request #3088](https://github.com/gazebosim/gz-sim/pull/3088) + 1. Parallel asset download * [Pull request #2992](https://github.com/gazebosim/gz-sim/pull/2992) From 62d8dfc10346a1838625ade678c403b74fef8e0a Mon Sep 17 00:00:00 2001 From: Steve Peters Date: Mon, 29 Sep 2025 09:37:24 -0700 Subject: [PATCH 5/7] codespell: skip *.patch files Signed-off-by: Steve Peters --- tools/pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/pyproject.toml b/tools/pyproject.toml index 9fbe60f956..b2c09b1c47 100644 --- a/tools/pyproject.toml +++ b/tools/pyproject.toml @@ -1,3 +1,3 @@ [tool.codespell] ignore-words = "tools/.codespell_ignore_words" -skip = '*/gz3d.js' +skip = '*/gz3d.js,*.patch' From bd43185ac68c8622bcdc2d3cc4393d4cbb3c5e05 Mon Sep 17 00:00:00 2001 From: Steve Peters Date: Mon, 29 Sep 2025 09:38:57 -0700 Subject: [PATCH 6/7] fix path Signed-off-by: Steve Peters --- tools/pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/pyproject.toml b/tools/pyproject.toml index b2c09b1c47..a1a6c32c6f 100644 --- a/tools/pyproject.toml +++ b/tools/pyproject.toml @@ -1,3 +1,3 @@ [tool.codespell] ignore-words = "tools/.codespell_ignore_words" -skip = '*/gz3d.js,*.patch' +skip = '*/gz3d.js,*/*.patch' From 6c59526a0dd916675ef05ce416eb7a6aae783161 Mon Sep 17 00:00:00 2001 From: Steve Peters Date: Mon, 29 Sep 2025 09:59:52 -0700 Subject: [PATCH 7/7] remove whitespace from patch fix later Signed-off-by: Steve Peters --- tools/pyproject.toml | 2 +- vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/pyproject.toml b/tools/pyproject.toml index a1a6c32c6f..9fbe60f956 100644 --- a/tools/pyproject.toml +++ b/tools/pyproject.toml @@ -1,3 +1,3 @@ [tool.codespell] ignore-words = "tools/.codespell_ignore_words" -skip = '*/gz3d.js,*/*.patch' +skip = '*/gz3d.js' diff --git a/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch index 6d475a59ee..f0eb5d53c5 100644 --- a/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch +++ b/vendor/backward-cpp/GAZEBO_MODIFIED_CODE.patch @@ -1,4 +1,4 @@ -Summary: avoid installing backwards file in the system unless being +Summary: avoid installing backwards file in the system unless being used as a top level Description: do not install backwards files in the Gazebo usage of @@ -13,7 +13,7 @@ index e625f8ac9..3b18476d5 100644 @@ -157,16 +157,16 @@ if(BACKWARD_TESTS) endforeach() endif() - + - -install( - FILES "backward.hpp"