summaryrefslogtreecommitdiff
path: root/sci-electronics/gazebo
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-08-25 15:54:35 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-08-25 15:54:35 +0100
commitd0bb3151c569ab6e40c84c177f43bff3c7ce4780 (patch)
tree0c543a2f299a437229bcd5db5c62697a41243689 /sci-electronics/gazebo
parent601320c16301dbd7e8830e8c2ab7d6aef5b65abe (diff)
gentoo auto-resync : 25:08:2023 - 15:54:35
Diffstat (limited to 'sci-electronics/gazebo')
-rw-r--r--sci-electronics/gazebo/Manifest6
-rw-r--r--sci-electronics/gazebo/files/ffmpeg6.patch40
-rw-r--r--sci-electronics/gazebo/files/protobuf.patch226
-rw-r--r--sci-electronics/gazebo/gazebo-11.13.0.ebuild (renamed from sci-electronics/gazebo/gazebo-11.12.0-r1.ebuild)2
4 files changed, 230 insertions, 44 deletions
diff --git a/sci-electronics/gazebo/Manifest b/sci-electronics/gazebo/Manifest
index 973475089f61..23f76299dbfb 100644
--- a/sci-electronics/gazebo/Manifest
+++ b/sci-electronics/gazebo/Manifest
@@ -1,6 +1,6 @@
AUX cmake.patch 699 BLAKE2B 64edc9a3e51952ca5e15488a4fa148028d77bbb3a294937d9df263e8f0d78c59e6d2a40574534aa12911d79b8871901ff5fd16af236f32f0e580b7e86a3f8198 SHA512 95693482c14ddbc759af20c7ef30d1660e8630b21cf52d15ca14e8ef08d3631483c736e67423e2cabf1a8c8b834e8e25ece8a7bd15f71b38853b71d2fdcbce8f
-AUX ffmpeg6.patch 1571 BLAKE2B 114c3c0625e002fa383c749835cbef041d49dbbdd6ee82eb5214029daa2a17d193cc92855d825a28820dd0f61aec4e0dd6d4c1eafa2c4ea5ca90fabd0c0cbc32 SHA512 d6d479fc5e7923c86e037e17f42959500888f2aaa5f9ca16a136c5c8c2f98dd5e48b112ae5cbe6741a85ddcf40e0087fcf78a21d9713dd9c8e390b02e5dd4916
+AUX protobuf.patch 8899 BLAKE2B c8d181250926a7b22aa67e17b1e38b9713c50578458452d02b9af89400d4194f31808563709cbfc81fdb4709ee57032fbb77d26ff413bc069a5dc0407a57146b SHA512 eb36f0000204788ad9fa40d8fcdc0fcb6fc8d27489c5bae3cc12e910a7046936ed1d6adc23b3498060ee6da380df5f238bde17b699b3c3b0eec9f1c75a6c07e9
AUX qwt2.patch 592 BLAKE2B 77c1f9ffa4e1754d8f6bcbd7eff2dfa470abb2c265fb44a4d8a652d0be85b0f337fea7c8786b1f52ecf285a1b78d61238ce61a0d28ca2895d21b700ed3890585 SHA512 16e0c25c13985badc1f4870e02d35d9d72c3006abcc8ae736327b88b15323c2c52892a3d76c5a745b46f512b5f2b2bebd70e390bec2515d954a47e4a08c94792
-DIST gazebo-11.12.0.tar.bz2 56542859 BLAKE2B f2da8371fa4655cc831401fcf6ceec8c82d507a93515762c078ac20a78cb4b739c9f373ef53bebc71b5d7e1c1cf4b98928b3e855fca6943a09da554ee19df1cb SHA512 8f60d432ab07084951bbe31c632f04f2fa11500441fb81fe27078a5cb5b67ba681889e1079844d44a5a30df562797d51683fd674942db9fd8c4d853e3e2c5d3e
-EBUILD gazebo-11.12.0-r1.ebuild 1892 BLAKE2B 698e63e9edf3ed6d5b5001d5b4bb11ce3b09585d5fead33300213073a181e2319c15726038425f37d3b51908e72cc41c12a2d6f1110fa170dedc1eba04dd2036 SHA512 d56f6b0fa0196fa7b8d814fea811d2d394978f2a8cd593ca65bc150119f8cb8e9d81e80a7a86b8a5e08d6c1ef71fa84496b89ac605264e1743920e1e58a7a329
+DIST gazebo-11.13.0.tar.bz2 56636967 BLAKE2B 7c0ef875711e832a213631d97584edc2300d25be6d538d6f2ac782ab279b6518e1fb7c59d895a1c7b92fbaec46bb0e7c505afb34f05ab2eece016f5bd15a7c3f SHA512 a77ce4a02f723c615738d11a13aa10fa5124705bc9ca95153477d8df25b296eef7d442769379d3888a9ba0f04c1e5a3e38d686e7b5eef393b91bdc78f792c390
+EBUILD gazebo-11.13.0.ebuild 1893 BLAKE2B 01d3b523ca6342fea4be572679cbee959da6dbe89084680786ef5e0edb655f6fa3051e69aedfbfd0f929f41211447029b59021d31c22fe3ead1a07e803d57467 SHA512 e2f5973099b478942089d2863d2751ee7b47bf46db4ae0730cd3a765af3e484ef63c5c5df5d41c99eb32b47acf7775f6818cb70befad0e7a65c54bd27e6b75de
MISC metadata.xml 244 BLAKE2B 5a5426f4a80c61e49915e23ab7298bd1e53d89bd5361ad61fdaa3a50c88e7f27ea69205fd8c407addfdfde991e10cbe70aa554bfd737daf9d3d639c4eddd5934 SHA512 052b13f84da2d92069cdab006492e4b72274519bae5081f01ee4605215c7dca16bade6fa3856a7fec9435d1b564e607c9c52e0f9fdf199363af330778bf6c0af
diff --git a/sci-electronics/gazebo/files/ffmpeg6.patch b/sci-electronics/gazebo/files/ffmpeg6.patch
deleted file mode 100644
index 932d1e31c9d1..000000000000
--- a/sci-electronics/gazebo/files/ffmpeg6.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-Index: gazebo-11.12.0/gazebo/common/AudioDecoder.cc
-===================================================================
---- gazebo-11.12.0.orig/gazebo/common/AudioDecoder.cc
-+++ gazebo-11.12.0/gazebo/common/AudioDecoder.cc
-@@ -364,6 +364,7 @@ bool AudioDecoder::SetFile(const std::st
- return false;
- }
-
-+#if LIBAVCODEC_VERSION_MAJOR < 60
- #if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(56, 60, 100)
- if (this->codec->capabilities & AV_CODEC_CAP_TRUNCATED)
- this->codecCtx->flags |= AV_CODEC_FLAG_TRUNCATED;
-@@ -371,6 +372,7 @@ bool AudioDecoder::SetFile(const std::st
- if (this->codec->capabilities & CODEC_CAP_TRUNCATED)
- this->codecCtx->flags |= CODEC_FLAG_TRUNCATED;
- #endif
-+#endif
-
- // Open codec
- if (avcodec_open2(this->codecCtx, this->codec, nullptr) < 0)
-Index: gazebo-11.12.0/gazebo/common/Video.cc
-===================================================================
---- gazebo-11.12.0.orig/gazebo/common/Video.cc
-+++ gazebo-11.12.0/gazebo/common/Video.cc
-@@ -214,6 +214,7 @@ bool Video::Load(const std::string &_fil
- return false;
- }
-
-+#if LIBAVCODEC_VERSION_MAJOR < 60
- // Inform the codec that we can handle truncated bitstreams -- i.e.,
- // bitstreams where frame boundaries can fall in the middle of packets
- #if LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(56, 60, 100)
-@@ -223,6 +224,7 @@ bool Video::Load(const std::string &_fil
- if (codec->capabilities & CODEC_CAP_TRUNCATED)
- this->codecCtx->flags |= CODEC_FLAG_TRUNCATED;
- #endif
-+#endif
-
- // Open codec
- if (avcodec_open2(this->codecCtx, codec, nullptr) < 0)
diff --git a/sci-electronics/gazebo/files/protobuf.patch b/sci-electronics/gazebo/files/protobuf.patch
new file mode 100644
index 000000000000..c815d7a9aab3
--- /dev/null
+++ b/sci-electronics/gazebo/files/protobuf.patch
@@ -0,0 +1,226 @@
+From 92a44c60e4b38d147fd92ed480e33e61cc68c928 Mon Sep 17 00:00:00 2001
+From: Silvio Traversaro <silvio@traversaro.it>
+Date: Tue, 6 Jun 2023 13:50:07 +0200
+Subject: [PATCH 1/6] Support for protobuf >= 22 by using find_package(Protobuf
+ CONFIG)
+
+---
+ cmake/SearchForStuff.cmake | 49 +++++++++++++++++++++++++-----------
+ cmake/gazebo-config.cmake.in | 15 ++++++++---
+ 2 files changed, 46 insertions(+), 18 deletions(-)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index b1cb3f37b3..e0fbd68274 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -25,29 +25,48 @@ if (CMAKE_BUILD_TYPE)
+ endif()
+
+ ########################################
+-if (PROTOBUF_VERSION LESS 2.3.0)
++if (DEFINED PROTOBUF_VERSION AND PROTOBUF_VERSION GREATER_EQUAL 22.0)
+ BUILD_ERROR("Incorrect version: Gazebo requires protobuf version 2.3.0 or greater")
+ endif()
+
+ ########################################
+ # The Google Protobuf library for message generation + serialization
+-find_package(Protobuf REQUIRED)
+-if (NOT PROTOBUF_FOUND)
+- BUILD_ERROR ("Missing: Google Protobuf (libprotobuf-dev)")
+-endif()
+-if (NOT PROTOBUF_PROTOC_EXECUTABLE)
+- BUILD_ERROR ("Missing: Google Protobuf Compiler (protobuf-compiler)")
+-endif()
+-if (NOT PROTOBUF_PROTOC_LIBRARY)
+- BUILD_ERROR ("Missing: Google Protobuf Compiler Library (libprotoc-dev)")
++
++# Protobuf >= 22 requires to link abseil, so we are constrained to use
++# find_package(Protobuf) and link to protobuf::libprotobuf,
++# see https://github.com/conda-forge/conda-forge-pinning-feedstock/issues/4075#issuecomment-1569242816
++if (DEFINED PROTOBUF_VERSION AND PROTOBUF_VERSION GREATER_EQUAL 22.0)
++ set(GZ_PROTOBUF_USE_CMAKE_CONFIG_DEFAULT ON)
++else()
++ set(GZ_PROTOBUF_USE_CMAKE_CONFIG_DEFAULT OFF)
+ endif()
++option(GZ_PROTOBUF_USE_CMAKE_CONFIG "If true use protobuf-config.cmake to find protobuf" ${GZ_PROTOBUF_USE_CMAKE_CONFIG_DEFAULT})
++mark_as_advanced(GZ_PROTOBUF_USE_CMAKE_CONFIG)
+
+-if ("${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
+- set (GZ_PROTOBUF_LIBRARY ${PROTOBUF_LIBRARY_DEBUG})
+- set (GZ_PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY_DEBUG})
++if(NOT GZ_PROTOBUF_USE_CMAKE_CONFIG)
++ find_package(Protobuf REQUIRED)
++ if (NOT PROTOBUF_FOUND)
++ BUILD_ERROR ("Missing: Google Protobuf (libprotobuf-dev)")
++ endif()
++ if (NOT PROTOBUF_PROTOC_EXECUTABLE)
++ BUILD_ERROR ("Missing: Google Protobuf Compiler (protobuf-compiler)")
++ endif()
++ if (NOT PROTOBUF_PROTOC_LIBRARY)
++ BUILD_ERROR ("Missing: Google Protobuf Compiler Library (libprotoc-dev)")
++ endif()
++ if ("${CMAKE_BUILD_TYPE}" STREQUAL "Debug")
++ set (GZ_PROTOBUF_LIBRARY ${PROTOBUF_LIBRARY_DEBUG})
++ set (GZ_PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY_DEBUG})
++ else()
++ set (GZ_PROTOBUF_LIBRARY ${PROTOBUF_LIBRARY})
++ set (GZ_PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY})
++ endif()
+ else()
+- set (GZ_PROTOBUF_LIBRARY ${PROTOBUF_LIBRARY})
+- set (GZ_PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY})
++ set (GZ_PROTOBUF_LIBRARY protobuf::libprotobuf)
++ set (GZ_PROTOBUF_PROTOC_LIBRARY protobuf::libprotoc)
++ if(NOT DEFINED PROTOBUF_PROTOC_LIBRARY)
++ get_target_property(PROTOBUF_PROTOC_LIBRARY protobuf::protoc LOCATION)
++ endif()
+ endif()
+
+ ########################################
+diff --git a/cmake/gazebo-config.cmake.in b/cmake/gazebo-config.cmake.in
+index 96993f93fa..ac1de2c061 100644
+--- a/cmake/gazebo-config.cmake.in
++++ b/cmake/gazebo-config.cmake.in
+@@ -166,9 +166,18 @@ list(APPEND @PKG_NAME@_INCLUDE_DIRS ${Boost_INCLUDE_DIRS})
+ list(APPEND @PKG_NAME@_LIBRARIES ${Boost_LIBRARIES})
+
+ # Find protobuf
+-find_package(Protobuf REQUIRED)
+-list(APPEND @PKG_NAME@_INCLUDE_DIRS ${PROTOBUF_INCLUDE_DIRS})
+-list(APPEND @PKG_NAME@_LIBRARIES ${PROTOBUF_LIBRARIES})
++set(GZ_PROTOBUF_USE_CMAKE_CONFIG @GZ_PROTOBUF_USE_CMAKE_CONFIG@)
++
++if(NOT GZ_PROTOBUF_USE_CMAKE_CONFIG)
++ find_package(Protobuf REQUIRED)
++ list(APPEND @PKG_NAME@_INCLUDE_DIRS ${PROTOBUF_INCLUDE_DIRS})
++ list(APPEND @PKG_NAME@_LIBRARIES ${PROTOBUF_LIBRARIES})
++else()
++ find_package(Protobuf CONFIG REQUIRED)
++ list(APPEND @PKG_NAME@_INCLUDE_DIRS ${PROTOBUF_INCLUDE_DIRS})
++ list(APPEND @PKG_NAME@_LIBRARIES protobuf::libprotoc)
++ list(APPEND @PKG_NAME@_LIBRARIES protobuf::libprotobuf)
++endif()
+
+ # Find SDFormat
+ find_package(sdformat9 REQUIRED VERSION 9.8)
+
+From 83f05b7778ff2933d8bd3b9149207dd17a20b9b4 Mon Sep 17 00:00:00 2001
+From: Silvio Traversaro <silvio@traversaro.it>
+Date: Tue, 6 Jun 2023 14:18:48 +0200
+Subject: [PATCH 2/6] Update SearchForStuff.cmake
+
+---
+ cmake/SearchForStuff.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index e0fbd68274..d25b7a4a63 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -25,7 +25,7 @@ if (CMAKE_BUILD_TYPE)
+ endif()
+
+ ########################################
+-if (DEFINED PROTOBUF_VERSION AND PROTOBUF_VERSION GREATER_EQUAL 22.0)
++if (PROTOBUF_VERSION LESS 2.3.0)
+ BUILD_ERROR("Incorrect version: Gazebo requires protobuf version 2.3.0 or greater")
+ endif()
+
+
+From 398e832301429b2f406a5a0e35187ca8fabd50ad Mon Sep 17 00:00:00 2001
+From: Silvio Traversaro <silvio@traversaro.it>
+Date: Tue, 6 Jun 2023 23:25:06 +0200
+Subject: [PATCH 3/6] Update SearchForStuff.cmake
+
+---
+ cmake/SearchForStuff.cmake | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index d25b7a4a63..2f0b53358f 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -62,6 +62,7 @@ if(NOT GZ_PROTOBUF_USE_CMAKE_CONFIG)
+ set (GZ_PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY})
+ endif()
+ else()
++ find_package(Protobuf CONFIG REQUIRED)
+ set (GZ_PROTOBUF_LIBRARY protobuf::libprotobuf)
+ set (GZ_PROTOBUF_PROTOC_LIBRARY protobuf::libprotoc)
+ if(NOT DEFINED PROTOBUF_PROTOC_LIBRARY)
+
+From d46bf2353a25b38b9613b67f2567f729e133d2b7 Mon Sep 17 00:00:00 2001
+From: Silvio Traversaro <silvio@traversaro.it>
+Date: Tue, 6 Jun 2023 23:55:22 +0200
+Subject: [PATCH 4/6] Update SearchForStuff.cmake
+
+---
+ cmake/SearchForStuff.cmake | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index 2f0b53358f..1bbadd3c29 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -66,7 +66,9 @@ else()
+ set (GZ_PROTOBUF_LIBRARY protobuf::libprotobuf)
+ set (GZ_PROTOBUF_PROTOC_LIBRARY protobuf::libprotoc)
+ if(NOT DEFINED PROTOBUF_PROTOC_LIBRARY)
+- get_target_property(PROTOBUF_PROTOC_LIBRARY protobuf::protoc LOCATION)
++ get_target_property(PROTOBUF_PROTOC_LIBRARY_VAR protobuf::protoc LOCATION)
++ set(PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY_VAR} CACHE STRING "")
++ mark_as_advanced(PROTOBUF_PROTOC_LIBRARY)
+ endif()
+ endif()
+
+
+From f372ef83b99bf2dc2f4a456ab74c7831c347ec89 Mon Sep 17 00:00:00 2001
+From: Silvio Traversaro <silvio@traversaro.it>
+Date: Wed, 7 Jun 2023 00:39:40 +0200
+Subject: [PATCH 5/6] Update SearchForStuff.cmake
+
+---
+ cmake/SearchForStuff.cmake | 6 ++----
+ 1 file changed, 2 insertions(+), 4 deletions(-)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index 1bbadd3c29..c400bee0e3 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -65,10 +65,8 @@ else()
+ find_package(Protobuf CONFIG REQUIRED)
+ set (GZ_PROTOBUF_LIBRARY protobuf::libprotobuf)
+ set (GZ_PROTOBUF_PROTOC_LIBRARY protobuf::libprotoc)
+- if(NOT DEFINED PROTOBUF_PROTOC_LIBRARY)
+- get_target_property(PROTOBUF_PROTOC_LIBRARY_VAR protobuf::protoc LOCATION)
+- set(PROTOBUF_PROTOC_LIBRARY ${PROTOBUF_PROTOC_LIBRARY_VAR} CACHE STRING "")
+- mark_as_advanced(PROTOBUF_PROTOC_LIBRARY)
++ if(NOT DEFINED PROTOBUF_PROTOC_EXECUTABLE)
++ get_target_property(PROTOBUF_PROTOC_EXECUTABLE protobuf::protoc LOCATION)
+ endif()
+ endif()
+
+
+From c4674eee1ad234d4a74bafc1d3ec401b595d3d63 Mon Sep 17 00:00:00 2001
+From: Steve Peters <computersthatmove@gmail.com>
+Date: Wed, 14 Jun 2023 09:27:16 -0700
+Subject: [PATCH 6/6] Fix whitespace
+
+Signed-off-by: Steve Peters <scpeters@openrobotics.org>
+---
+ cmake/SearchForStuff.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cmake/SearchForStuff.cmake b/cmake/SearchForStuff.cmake
+index c400bee0e3..948cf0a8a1 100644
+--- a/cmake/SearchForStuff.cmake
++++ b/cmake/SearchForStuff.cmake
+@@ -32,7 +32,7 @@ endif()
+ ########################################
+ # The Google Protobuf library for message generation + serialization
+
+-# Protobuf >= 22 requires to link abseil, so we are constrained to use
++# Protobuf >= 22 requires to link abseil, so we are constrained to use
+ # find_package(Protobuf) and link to protobuf::libprotobuf,
+ # see https://github.com/conda-forge/conda-forge-pinning-feedstock/issues/4075#issuecomment-1569242816
+ if (DEFINED PROTOBUF_VERSION AND PROTOBUF_VERSION GREATER_EQUAL 22.0)
diff --git a/sci-electronics/gazebo/gazebo-11.12.0-r1.ebuild b/sci-electronics/gazebo/gazebo-11.13.0.ebuild
index 1ba53c80d837..801fdd8a98a1 100644
--- a/sci-electronics/gazebo/gazebo-11.12.0-r1.ebuild
+++ b/sci-electronics/gazebo/gazebo-11.13.0.ebuild
@@ -65,7 +65,7 @@ CMAKE_BUILD_TYPE=RelWithDebInfo
PATCHES=(
"${FILESDIR}/qwt2.patch"
"${FILESDIR}/cmake.patch"
- "${FILESDIR}/ffmpeg6.patch"
+ "${FILESDIR}/protobuf.patch"
)
src_configure() {