summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2023-01-31 17:42:45 +0800
committerKhem Raj <raj.khem@gmail.com>2023-02-01 09:11:49 -0800
commitf05ea5c2e81b72549fa345815d2ae8835a8d7f2c (patch)
tree25b6cfd58b3d970e16904f09539ead56f663f60e
parent60084508a4f10d7cd136a41cae7882e99bf8b433 (diff)
downloadmeta-openembedded-f05ea5c2e81b72549fa345815d2ae8835a8d7f2c.tar.gz
syslog-ng: workaround segfault for ppc64le
For now syslog-ng segfaults on ppc64le. The problem could be reproduced by simply adding syslog-ng to IMAGE_INSTALL and then building and starting an image for qemuppc64. The underlying root cause is unknown yet. This workaround, on the other hand, helps improve the situation a little bit in the sense that users can at least use syslog-ng on ppc64le targets. Note that this workaround should be dropped once the upstream issues[1][2] are fixed. This has also stated very clearly in the patch. [1] https://sourceware.org/bugzilla/show_bug.cgi?id=30062 [2] https://github.com/syslog-ng/syslog-ng/issues/4285 Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-oe/recipes-support/syslog-ng/files/0001-plugin.c-workaround-powerpc64le-segfaults-error.patch46
-rw-r--r--meta-oe/recipes-support/syslog-ng/syslog-ng_3.38.1.bb1
2 files changed, 47 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/syslog-ng/files/0001-plugin.c-workaround-powerpc64le-segfaults-error.patch b/meta-oe/recipes-support/syslog-ng/files/0001-plugin.c-workaround-powerpc64le-segfaults-error.patch
new file mode 100644
index 0000000000..343e6fdade
--- /dev/null
+++ b/meta-oe/recipes-support/syslog-ng/files/0001-plugin.c-workaround-powerpc64le-segfaults-error.patch
@@ -0,0 +1,46 @@
1From 616446afab61ab98b28c81605e2efd4a689f37d1 Mon Sep 17 00:00:00 2001
2From: Chen Qi <Qi.Chen@windriver.com>
3Date: Fri, 20 Jan 2023 14:59:14 +0800
4Subject: [PATCH] plugin.c: workaround powerpc64le segfaults error
5
6syslog-ng segfaults on powerpc64le, workaround this error.
7See https://github.com/syslog-ng/syslog-ng/issues/4285 and
8https://sourceware.org/bugzilla/show_bug.cgi?id=30062 for more details.
9This patch should be dropped once the above issues are fixed.
10
11Upstream-Status: Inappropriate [OE Specific]
12
13Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
14---
15 lib/plugin.c | 8 ++------
16 1 file changed, 2 insertions(+), 6 deletions(-)
17
18diff --git a/lib/plugin.c b/lib/plugin.c
19index fbbfb92..3a03617 100644
20--- a/lib/plugin.c
21+++ b/lib/plugin.c
22@@ -528,10 +528,7 @@ plugin_discover_candidate_modules(PluginContext *context)
23 }
24 }
25 g_free(module_name);
26- if (mod)
27- g_module_close(mod);
28- else
29- mod = NULL;
30+ mod = NULL;
31 }
32 }
33 g_dir_close(dir);
34@@ -663,8 +660,7 @@ plugin_list_modules(FILE *out, gboolean verbose)
35 first = FALSE;
36 }
37 g_free(module_name);
38- if (mod)
39- g_module_close(mod);
40+ mod = NULL;
41 }
42 }
43 g_dir_close(dir);
44--
452.17.1
46
diff --git a/meta-oe/recipes-support/syslog-ng/syslog-ng_3.38.1.bb b/meta-oe/recipes-support/syslog-ng/syslog-ng_3.38.1.bb
index 76945095ac..182a253d35 100644
--- a/meta-oe/recipes-support/syslog-ng/syslog-ng_3.38.1.bb
+++ b/meta-oe/recipes-support/syslog-ng/syslog-ng_3.38.1.bb
@@ -23,6 +23,7 @@ SRC_URI = "https://github.com/balabit/syslog-ng/releases/download/${BP}/${BP}.ta
23 file://syslog-ng-tmp.conf \ 23 file://syslog-ng-tmp.conf \
24 file://syslog-ng.service-the-syslog-ng-service.patch \ 24 file://syslog-ng.service-the-syslog-ng-service.patch \
25" 25"
26SRC_URI:append:powerpc64le = " file://0001-plugin.c-workaround-powerpc64le-segfaults-error.patch"
26 27
27SRC_URI[sha256sum] = "5491f686d0b829b69b2e0fc0d66a62f51991aafaee005475bfa38fab399441f7" 28SRC_URI[sha256sum] = "5491f686d0b829b69b2e0fc0d66a62f51991aafaee005475bfa38fab399441f7"
28 29