diff options
-rw-r--r-- | meta-networking/recipes-connectivity/snort/snort/0001-chdeck-for-gettid-API-during-configure.patch | 48 | ||||
-rw-r--r-- | meta-networking/recipes-connectivity/snort/snort_2.9.14.bb | 1 |
2 files changed, 49 insertions, 0 deletions
diff --git a/meta-networking/recipes-connectivity/snort/snort/0001-chdeck-for-gettid-API-during-configure.patch b/meta-networking/recipes-connectivity/snort/snort/0001-chdeck-for-gettid-API-during-configure.patch new file mode 100644 index 0000000000..eff610de7c --- /dev/null +++ b/meta-networking/recipes-connectivity/snort/snort/0001-chdeck-for-gettid-API-during-configure.patch | |||
@@ -0,0 +1,48 @@ | |||
1 | From c45ab69f9428e4d2fc1146301a4546bb2b42c9ae Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Sat, 27 Jul 2019 00:25:58 -0700 | ||
4 | Subject: [PATCH] chdeck for gettid API during configure | ||
5 | |||
6 | glibc 2.30 added gettid syscall wrapper | ||
7 | |||
8 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
9 | --- | ||
10 | configure.in | 2 +- | ||
11 | src/util.h | 2 ++ | ||
12 | 2 files changed, 3 insertions(+), 1 deletion(-) | ||
13 | |||
14 | diff --git a/configure.in b/configure.in | ||
15 | index 000bb91..d79e6d0 100644 | ||
16 | --- a/configure.in | ||
17 | +++ b/configure.in | ||
18 | @@ -256,7 +256,7 @@ SN_CHECK_DECLS(printf fprintf syslog puts fputs fputc fopen \ | ||
19 | strcasecmp strncasecmp strerror perror socket sendto \ | ||
20 | vsnprintf snprintf strtoul) | ||
21 | |||
22 | -AC_CHECK_FUNCS([sigaction strlcpy strlcat strerror vswprintf wprintf memrchr inet_ntop]) | ||
23 | +AC_CHECK_FUNCS([sigaction strlcpy strlcat strerror vswprintf wprintf memrchr inet_ntop gettid]) | ||
24 | |||
25 | AC_CHECK_FUNC([snprintf],[have_snprintf="yes"],[have_snprintf="no"]) | ||
26 | AM_CONDITIONAL(BUILD_SNPRINTF, test "x$have_snprintf" != "xyes") | ||
27 | diff --git a/src/util.h b/src/util.h | ||
28 | index 6880906..c310b83 100644 | ||
29 | --- a/src/util.h | ||
30 | +++ b/src/util.h | ||
31 | @@ -374,6 +374,7 @@ static inline int IsEmptyStr(const char *str) | ||
32 | return 0; | ||
33 | } | ||
34 | |||
35 | +#if !HAVE_GETTID | ||
36 | static inline pid_t gettid(void) | ||
37 | { | ||
38 | #if defined(LINUX) && defined(SYS_gettid) | ||
39 | @@ -382,5 +383,6 @@ static inline pid_t gettid(void) | ||
40 | return getpid(); | ||
41 | #endif | ||
42 | } | ||
43 | +#endif | ||
44 | |||
45 | #endif /*__UTIL_H__*/ | ||
46 | -- | ||
47 | 2.22.0 | ||
48 | |||
diff --git a/meta-networking/recipes-connectivity/snort/snort_2.9.14.bb b/meta-networking/recipes-connectivity/snort/snort_2.9.14.bb index b11890c490..6ead49bb61 100644 --- a/meta-networking/recipes-connectivity/snort/snort_2.9.14.bb +++ b/meta-networking/recipes-connectivity/snort/snort_2.9.14.bb | |||
@@ -12,6 +12,7 @@ SRC_URI = "https://www.snort.org/downloads/archive/snort/${BP}.tar.gz \ | |||
12 | file://fix-host-contamination-when-enable-static-daq.patch \ | 12 | file://fix-host-contamination-when-enable-static-daq.patch \ |
13 | file://disable-run-test-program-while-cross-compiling.patch \ | 13 | file://disable-run-test-program-while-cross-compiling.patch \ |
14 | file://configure.in-disable-tirpc-checking-for-fedora.patch \ | 14 | file://configure.in-disable-tirpc-checking-for-fedora.patch \ |
15 | file://0001-chdeck-for-gettid-API-during-configure.patch \ | ||
15 | " | 16 | " |
16 | 17 | ||
17 | SRC_URI[md5sum] = "d1689c7ccaaa7bfcfa83b5bff6b8f9b8" | 18 | SRC_URI[md5sum] = "d1689c7ccaaa7bfcfa83b5bff6b8f9b8" |