[oe-commits] [meta-openembedded] 03/12: ltrace: Fix build on mips

git at git.openembedded.org git at git.openembedded.org
Sat Sep 7 18:29:18 UTC 2019


This is an automated email from the git hooks/post-receive script.

khem pushed a commit to branch master-next
in repository meta-openembedded.

commit 720a2ffe85cff1d24012b14e9ab47a6a239cd9eb
Author: Khem Raj <raj.khem at gmail.com>
AuthorDate: Fri Sep 6 14:23:41 2019 -0700

    ltrace: Fix build on mips
    
    Newer kernel UAPI headers for mips have moved these needed defines
    around
    
    Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
 .../ltrace/ltrace/include_unistd_nr.patch          | 30 ++++++++++++++++++++++
 meta-oe/recipes-devtools/ltrace/ltrace_git.bb      |  1 +
 2 files changed, 31 insertions(+)

diff --git a/meta-oe/recipes-devtools/ltrace/ltrace/include_unistd_nr.patch b/meta-oe/recipes-devtools/ltrace/ltrace/include_unistd_nr.patch
new file mode 100644
index 0000000..e4490bb
--- /dev/null
+++ b/meta-oe/recipes-devtools/ltrace/ltrace/include_unistd_nr.patch
@@ -0,0 +1,30 @@
+kernel headers have restructured mips syscall generation in kernel
+in recent versions, however, ltrace still has logic to define the
+syscall numbers based on old logic, this patch includes the legacy
+UAPI headers to get these defines
+
+Fixes errors e.g.
+../../../../git/sysdeps/linux-gnu/mips/trace.c:138:29: error: '__NR_O32_Linux' undeclared (first use in this function)
+  const int syscallbase[] = {__NR_O32_Linux, __NR_N32_Linux,
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem at gmail.com>
+--- a/sysdeps/linux-gnu/mips/trace.c
++++ b/sysdeps/linux-gnu/mips/trace.c
+@@ -34,6 +34,16 @@
+ #include <assert.h>
+ #include <asm/unistd.h>
+ 
++#ifndef __NR_O32_Linux
++#include <asm/unistd_nr_o32.h>
++#endif
++#ifndef __NR_N32_Linux
++#include <asm/unistd_nr_n64.h>
++#endif
++#ifndef __NR_N64_Linux
++#include <asm/unistd_nr_n32.h>
++#endif
++
+ #include "backend.h"
+ #include "common.h"
+ #include "debug.h"
diff --git a/meta-oe/recipes-devtools/ltrace/ltrace_git.bb b/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
index 3dc269c..ead637c 100644
--- a/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
+++ b/meta-oe/recipes-devtools/ltrace/ltrace_git.bb
@@ -27,6 +27,7 @@ SRC_URI = "git://github.com/sparkleholic/ltrace.git;branch=master;protocol=http
            file://0001-mips-plt.c-Delete-include-error.h.patch \
            file://0001-move-fprintf-into-same-block-where-modname-and-symna.patch \
            file://0001-hook-Do-not-append-int-to-std-string.patch \
+           file://include_unistd_nr.patch \
            "
 S = "${WORKDIR}/git"
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list