aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2024-02-20 15:39:07 -0800
committerKhem Raj <raj.khem@gmail.com>2024-02-21 19:59:51 -0800
commit97700116c248fea659020090ae2a165b8a02eed1 (patch)
tree2f79701a4d85e28946e7b7464a4544b9e4a5916c
parentbe6deab87e96fe93f12676ba42a2ed3fa89308dc (diff)
downloadmeta-openembedded-97700116c248fea659020090ae2a165b8a02eed1.tar.gz
snort: Do not use llvm libunwind
If llvm unwind is present then disable unwinding support since it will not have all unw_* functions eg. unw_strerror Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-networking/recipes-connectivity/snort/snort3/0001-cmake-Check-for-HP-libunwind.patch33
-rw-r--r--meta-networking/recipes-connectivity/snort/snort3_git.bb3
2 files changed, 35 insertions, 1 deletions
diff --git a/meta-networking/recipes-connectivity/snort/snort3/0001-cmake-Check-for-HP-libunwind.patch b/meta-networking/recipes-connectivity/snort/snort3/0001-cmake-Check-for-HP-libunwind.patch
new file mode 100644
index 00000000000..7b7a0d098f6
--- /dev/null
+++ b/meta-networking/recipes-connectivity/snort/snort3/0001-cmake-Check-for-HP-libunwind.patch
@@ -0,0 +1,33 @@
+From 433a412fad2ab0383ac3c625d183a71684f2b97b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 20 Feb 2024 15:35:14 -0800
+Subject: [PATCH] cmake: Check for HP libunwind
+
+This is to ensure that cmake does not detect LLVM unwinder, which
+can provide the support for some HP unwinder functionality but not all
+e.g. unw_strerror goes missing. By checking for libunwind-common.h in
+tests we ensure that this test passes only with HP libunwind.
+
+Upstream-Status: Inappropriate [OE-Specific]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ cmake/FindLibunwind.cmake | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/cmake/FindLibunwind.cmake b/cmake/FindLibunwind.cmake
+index f66800a18..1ad66fc83 100644
+--- a/cmake/FindLibunwind.cmake
++++ b/cmake/FindLibunwind.cmake
+@@ -22,7 +22,7 @@ find_package(PkgConfig QUIET)
+ pkg_check_modules(PC_LIBUNWIND libunwind)
+
+ find_path(LIBUNWIND_INCLUDE_DIRS
+- NAMES libunwind.h
++ NAMES libunwind-common.h
+ HINTS ${PC_LIBUNWIND_INCLUDE_DIRS}
+ )
+
+--
+2.43.2
+
diff --git a/meta-networking/recipes-connectivity/snort/snort3_git.bb b/meta-networking/recipes-connectivity/snort/snort3_git.bb
index f40a1d7d6fd..0f4a86f61e9 100644
--- a/meta-networking/recipes-connectivity/snort/snort3_git.bb
+++ b/meta-networking/recipes-connectivity/snort/snort3_git.bb
@@ -9,7 +9,8 @@ PV = "3+git${SRCPV}"
DEPENDS = "flex hwloc libdaq libdnet libpcap libpcre libtirpc libunwind luajit zlib"
-SRC_URI = "git://github.com/snort3/snort3.git;protocol=https;branch=master"
+SRC_URI = "git://github.com/snort3/snort3.git;protocol=https;branch=master \
+ file://0001-cmake-Check-for-HP-libunwind.patch"
SRCREV = "e1760a8dbb829bb3fcf1a340ab6cc4bb80a47ecd"
S = "${WORKDIR}/git"