]> code.ossystems Code Review - openembedded-core.git/commitdiff
strace: Define own sigmask macro if not defined already in signal.h
authorKhem Raj <raj.khem@gmail.com>
Thu, 21 Jul 2011 06:10:16 +0000 (23:10 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 22 Jul 2011 10:49:35 +0000 (11:49 +0100)
This is required especially on uclibc systems where BSD compatible
obsolete functions are disabled by kconfig. Therefore we check
if the macro is undefined then we define it. Therefore eglibc/glibc
builds should work as they use to.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
meta/recipes-devtools/strace/strace-4.5.20/sigmask.patch [new file with mode: 0644]
meta/recipes-devtools/strace/strace_4.5.20.bb

diff --git a/meta/recipes-devtools/strace/strace-4.5.20/sigmask.patch b/meta/recipes-devtools/strace/strace-4.5.20/sigmask.patch
new file mode 100644 (file)
index 0000000..9bca528
--- /dev/null
@@ -0,0 +1,22 @@
+sigmask is a macro which is dropped if BSD compatibility is
+not enabled. So we check if the macro does not exist then
+we define it to __sigmask
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+Index: strace-4.5.20/signal.c
+===================================================================
+--- strace-4.5.20.orig/signal.c        2010-02-23 13:26:16.000000000 -0800
++++ strace-4.5.20/signal.c     2011-07-20 23:06:35.842339197 -0700
+@@ -140,6 +140,11 @@
+ #endif
+ #endif /* LINUX */
++#if !defined (sigmask) && defined (__sigmask)
++/* Compute mask for signal SIG.  */
++#define sigmask(sig)   __sigmask(sig)
++#endif /* sigmask */
++
+ const char *const signalent0[] = {
+ #include "signalent.h"
+ };
index 3dba59fdab8e4e91d1665ec17181dac1b8f5c0c4..391669f5da37e6500977f8cc9a977bb5cd248077 100644 (file)
@@ -3,9 +3,11 @@ HOMEPAGE = "http://strace.sourceforge.net"
 SECTION = "console/utils"
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=4535377ede62550fdeaf39f595fd550a"
-PR = "r1"
+PR = "r2"
 
-SRC_URI = "${SOURCEFORGE_MIRROR}/strace/strace-${PV}.tar.bz2"
+SRC_URI = "${SOURCEFORGE_MIRROR}/strace/strace-${PV}.tar.bz2 \
+           file://sigmask.patch \
+          "
 
 SRC_URI[md5sum] = "64dfe10d9db0c1e34030891695ffca4b"
 SRC_URI[sha256sum] = "ea8c059369eaa5ad90b246f34eab247d0ee48bfdee2670c7196320a4669ccabd"