diff options
author | Michael Biebl <biebl@debian.org> | 2013-03-19 16:39:05 +0100 |
---|---|---|
committer | Michael Biebl <biebl@debian.org> | 2013-03-19 16:40:53 +0100 |
commit | d36d1eedecb5f3a0fd0627a606e6fe0573e9dc23 (patch) | |
tree | 46f56062b636c7ff67f1f0e8c479dd9d1fef00f5 | |
parent | 1e09cb378241f004fed3530b8814320b7355b5d8 (diff) | |
download | rsyslog-d36d1eedecb5f3a0fd0627a606e6fe0573e9dc23.tar.gz |
Check for SYS_gettid and use it conditionally
Cherry pick patch from upstream which fixes the build on architectures
which don't have SYS_gettid. (Closes: #703429)
-rw-r--r-- | debian/changelog | 7 | ||||
-rw-r--r-- | debian/patches/02-sys-gettid.patch | 39 | ||||
-rw-r--r-- | debian/patches/series | 1 |
3 files changed, 47 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog index d9662b3..a5d6c90 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +rsyslog (7.3.8-2) UNRELEASED; urgency=low + + * Cherry pick patch from upstream which fixes the build on architectures + which don't have SYS_gettid. (Closes: #703429) + + -- Michael Biebl <biebl@debian.org> Tue, 19 Mar 2013 16:37:48 +0100 + rsyslog (7.3.8-1) experimental; urgency=low * New upstream development release from the v7-devel branch. diff --git a/debian/patches/02-sys-gettid.patch b/debian/patches/02-sys-gettid.patch new file mode 100644 index 0000000..93fa01f --- /dev/null +++ b/debian/patches/02-sys-gettid.patch @@ -0,0 +1,39 @@ +From aef0be0c1799fbb20955fc1dc014cb9c9772af88 Mon Sep 17 00:00:00 2001 +From: Rainer Gerhards <rgerhards@adiscon.com> +Date: Tue, 19 Mar 2013 16:20:25 +0100 +Subject: [PATCH] bugfix: solve compile problems on non-Linux platforms + +Thanks to Michael Biebl for alerting us on this issue. +--- + configure.ac | 1 + + runtime/debug.c | 2 +- + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 7a4af19..6876980 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -122,6 +122,7 @@ AC_CHECK_DECL([SCM_CREDENTIALS], [AC_DEFINE(HAVE_SCM_CREDENTIALS, [1], [set defi + #include <sys/socket.h>]) + AC_CHECK_DECL([SO_TIMESTAMP], [AC_DEFINE(HAVE_SO_TIMESTAMP, [1], [set define])], [], [#include <sys/types.h> + #include <sys/socket.h>]) ++AC_CHECK_DECL([SYS_gettid], [AC_DEFINE(HAVE_SYS_gettid, [1], [set define])], [], [#include <sys/syscall.h>]) + AC_CHECK_MEMBER([struct sysinfo.uptime], [AC_DEFINE(HAVE_SYSINFO_UPTIME, [1], [set define])], [], [#include <sys/sysinfo.h>]) + + # Check for MAXHOSTNAMELEN +diff --git a/runtime/debug.c b/runtime/debug.c +index 3cb2223..876f61d 100644 +--- a/runtime/debug.c ++++ b/runtime/debug.c +@@ -303,7 +303,7 @@ static inline void dbgFuncDBRemoveMutexLock(dbgFuncDB_t *pFuncDB, pthread_mutex_ + void + dbgOutputTID(char* name) + { +-# ifdef HAVE_SYSCALL ++# if defined(HAVE_SYSCALL) && defined(HAVE_SYS_gettid) + if(bOutputTidToStderr) + fprintf(stderr, "thread tid %u, name '%s'\n", + (unsigned)syscall(SYS_gettid), name); +-- +1.7.10.4 + diff --git a/debian/patches/series b/debian/patches/series index 2113a56..8bc190a 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,2 +1,3 @@ # Debian patches for rsyslog 01-dont_create_db.patch +02-sys-gettid.patch |