package/sysdig: remove patch that doesn't apply

Patch 0001-cmake-Check-USE_BUNDLED_DEPS-before-getting-nlohmann.patch
should have been deleted as part of Buildroot commit
08792a60df ("package/sysdig: bump to
version 0.29.3"). Indeed, this patch was merged upstream as commit
114436c1a45142ef73acfc2607fbc6572782160f between 0.29.2 and 0.29.3.

This fixes the following build failure:

Applying 0001-cmake-Check-USE_BUNDLED_DEPS-before-getting-nlohmann.patch using patch:
patching file cmake/modules/nlohmann-json.cmake
Reversed (or previously applied) patch detected!  Skipping patch.
1 out of 1 hunk ignored -- saving rejects to file cmake/modules/nlohmann-json.cmake.rej

There are no autobuilder failures, probably because getting to build
sysdig requires so many special conditions that it never triggered.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
(cherry picked from commit e434d8a29f)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
This commit is contained in:
Thomas Petazzoni 2023-07-31 22:10:52 +02:00 committed by Peter Korsgaard
parent 7127899951
commit e9584abeb0

View File

@ -1,52 +0,0 @@
From 0dbebd008c04d266dc41c4bec8280a0744fd5130 Mon Sep 17 00:00:00 2001
From: Francis Laniel <flaniel@linux.microsoft.com>
Date: Wed, 13 Apr 2022 18:01:11 +0100
Subject: [PATCH] cmake: Check USE_BUNDLED_DEPS before getting
nlohmann-json.
Upstream: https://github.com/draios/sysdig/pull/1869
Signed-off-by: Francis Laniel <flaniel@linux.microsoft.com>
---
cmake/modules/nlohmann-json.cmake | 29 +++++++++++++++++++----------
1 file changed, 19 insertions(+), 10 deletions(-)
diff --git a/cmake/modules/nlohmann-json.cmake b/cmake/modules/nlohmann-json.cmake
index bb1279d7..feb0f071 100644
--- a/cmake/modules/nlohmann-json.cmake
+++ b/cmake/modules/nlohmann-json.cmake
@@ -16,13 +16,22 @@
# limitations under the License.
#
-set(NJSON_SRC "${PROJECT_BINARY_DIR}/njson-prefix/src/njson")
-message(STATUS "Using bundled nlohmann-json in '${NJSON_SRC}'")
-set(NJSON_INCLUDE_DIR "${NJSON_SRC}/single_include")
-ExternalProject_Add(
- njson
- URL "https://github.com/nlohmann/json/archive/v3.3.0.tar.gz"
- URL_HASH "SHA256=2fd1d207b4669a7843296c41d3b6ac5b23d00dec48dba507ba051d14564aa801"
- CONFIGURE_COMMAND ""
- BUILD_COMMAND ""
- INSTALL_COMMAND "")
+if(NOT USE_BUNDLED_DEPS)
+ find_path(NJSON_INCLUDE_DIR NAMES nlohmann/json.hpp)
+ if(NJSON_INCLUDE_DIR)
+ message(STATUS "Found njson: include: ${NJSON_INCLUDE_DIR}")
+ else()
+ message(FATAL_ERROR "Couldn't find system njson")
+ endif()
+else()
+ set(NJSON_SRC "${PROJECT_BINARY_DIR}/njson-prefix/src/njson")
+ message(STATUS "Using bundled nlohmann-json in '${NJSON_SRC}'")
+ set(NJSON_INCLUDE_DIR "${NJSON_SRC}/single_include")
+ ExternalProject_Add(
+ njson
+ URL "https://github.com/nlohmann/json/archive/v3.3.0.tar.gz"
+ URL_HASH "SHA256=2fd1d207b4669a7843296c41d3b6ac5b23d00dec48dba507ba051d14564aa801"
+ CONFIGURE_COMMAND ""
+ BUILD_COMMAND ""
+ INSTALL_COMMAND "")
+endif()
--
2.25.1