From 610864f67fab340179dd6f04f4100a635c743b15 Mon Sep 17 00:00:00 2001 From: Filip Sund Date: Fri, 4 Jul 2025 12:59:00 +0200 Subject: [PATCH 1/2] Fix ciso646 and cmake version issues --- octomap/PKGBUILD | 16 +++++++++++++--- octomap/fix-ciso646-header.patch | 24 ++++++++++++++++++++++++ octomap/fix-cmake-version.patch | 9 +++++++++ 3 files changed, 46 insertions(+), 3 deletions(-) create mode 100644 octomap/fix-ciso646-header.patch create mode 100644 octomap/fix-cmake-version.patch diff --git a/octomap/PKGBUILD b/octomap/PKGBUILD index 13a4775..a8c5f99 100644 --- a/octomap/PKGBUILD +++ b/octomap/PKGBUILD @@ -15,8 +15,18 @@ makedepends=('cmake') provides=('octomap') conflicts=('octomap-git') options=('staticlibs') -source=("${pkgname}-${pkgver}.tar.gz"::"https://github.com/OctoMap/octomap/archive/v${pkgver}.tar.gz") -sha256sums=('8da2576ec6a0993e8900db7f91083be8682d8397a7be0752c85d1b7dd1b8e992') +source=("${pkgname}-${pkgver}.tar.gz"::"https://github.com/OctoMap/octomap/archive/v${pkgver}.tar.gz" + "fix-ciso646-header.patch" + "fix-cmake-version.patch") +sha256sums=('8da2576ec6a0993e8900db7f91083be8682d8397a7be0752c85d1b7dd1b8e992' + 'SKIP' + 'SKIP') + +prepare() { + cd "$srcdir/octomap-$pkgver" + patch -Np1 -i ../fix-ciso646-header.patch + patch -Np1 -i ../fix-cmake-version.patch +} build() { cd "$srcdir/octomap-$pkgver/octomap" @@ -31,4 +41,4 @@ package() { cd build make DESTDIR="${pkgdir}" install install -Dm644 ../LICENSE.txt "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.txt" -} +} \ No newline at end of file diff --git a/octomap/fix-ciso646-header.patch b/octomap/fix-ciso646-header.patch new file mode 100644 index 0000000..3887aa0 --- /dev/null +++ b/octomap/fix-ciso646-header.patch @@ -0,0 +1,24 @@ +diff -ura octomap-1.10.0.orig/octomap/include/octomap/OcTreeKey.h octomap-1.10.0.new/octomap/include/octomap/OcTreeKey.h +--- octomap-1.10.0.orig/octomap/include/octomap/OcTreeKey.h 2025-07-04 12:46:08.736803128 +0200 ++++ octomap-1.10.0.new/octomap/include/octomap/OcTreeKey.h 2025-07-04 12:41:52.669078078 +0200 +@@ -37,7 +37,7 @@ + /* According to c++ standard including this header has no practical effect + * but it can be used to determine the c++ standard library implementation. + */ +-#include ++#include + + #include + +diff -ura octomap-1.10.0.orig/octomap/src/Pointcloud.cpp octomap-1.10.0.new/octomap/src/Pointcloud.cpp +--- octomap-1.10.0.orig/octomap/src/Pointcloud.cpp 2025-07-04 12:46:08.738439105 +0200 ++++ octomap-1.10.0.new/octomap/src/Pointcloud.cpp 2025-07-04 12:41:53.310878043 +0200 +@@ -34,7 +34,7 @@ + /* According to c++ standard including this header has no practical effect + * but it can be used to determine the c++ standard library implementation. + */ +-#include ++#include + + #if defined(_MSC_VER) || defined(_LIBCPP_VERSION) + #include diff --git a/octomap/fix-cmake-version.patch b/octomap/fix-cmake-version.patch new file mode 100644 index 0000000..a1f0a1a --- /dev/null +++ b/octomap/fix-cmake-version.patch @@ -0,0 +1,9 @@ +diff -ura octomap-1.10.0.orig/CMakeLists.txt octomap-1.10.0.new/CMakeLists.txt +--- octomap-1.10.0.orig/CMakeLists.txt 2025-07-04 12:46:08.734930419 +0200 ++++ octomap-1.10.0.new/CMakeLists.txt 2025-07-04 12:45:01.142613588 +0200 +@@ -1,4 +1,4 @@ +-CMAKE_MINIMUM_REQUIRED(VERSION 3.0.2) ++CMAKE_MINIMUM_REQUIRED(VERSION 3.5) + PROJECT( octomap-distribution ) + + ENABLE_TESTING() # enable CTest environment of subprojects \ No newline at end of file From 1d91c91149822eea8e49807847f05da1124ec76c Mon Sep 17 00:00:00 2001 From: Filip Sund Date: Fri, 4 Jul 2025 13:26:03 +0200 Subject: [PATCH 2/2] Set minimum cmake version --- libccd/PKGBUILD | 1 + 1 file changed, 1 insertion(+) diff --git a/libccd/PKGBUILD b/libccd/PKGBUILD index 5e41e94..bc45642 100644 --- a/libccd/PKGBUILD +++ b/libccd/PKGBUILD @@ -23,6 +23,7 @@ build() { cmake ${srcdir}/${_dir} \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ + -DCMAKE_POLICY_VERSION_MINIMUM=3.5 \ -DCMAKE_BUILD_TYPE=Release make