[oe-commits] [meta-openembedded] 08/09: openocd: Fix build with glibc 2.30

git at git.openembedded.org git at git.openembedded.org
Mon Jul 29 00:13:15 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 954d8b922d6cdac331fba5b3b29516299eddbb96
Author: Khem Raj <raj.khem at gmail.com>
AuthorDate: Sat Jul 27 14:41:12 2019 -0700

    openocd: Fix build with glibc 2.30
    
    sys/syctl.h is deprecated starting 2.30
    
    Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
 .../0001-Do-not-include-syscrtl.h-with-glibc.patch | 33 ++++++++++++++++++++++
 meta-oe/recipes-devtools/openocd/openocd_git.bb    |  1 +
 2 files changed, 34 insertions(+)

diff --git a/meta-oe/recipes-devtools/openocd/openocd/0001-Do-not-include-syscrtl.h-with-glibc.patch b/meta-oe/recipes-devtools/openocd/openocd/0001-Do-not-include-syscrtl.h-with-glibc.patch
new file mode 100644
index 0000000..618ce26
--- /dev/null
+++ b/meta-oe/recipes-devtools/openocd/openocd/0001-Do-not-include-syscrtl.h-with-glibc.patch
@@ -0,0 +1,33 @@
+From a763610719e7d7f6cdc45569b6fbfdb91bb7c87b Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem at gmail.com>
+Date: Sat, 27 Jul 2019 14:30:08 -0700
+Subject: [PATCH] Do not include syscrtl.h with glibc
+
+glibc 2.30 has deprecated it see [1]
+Fixes
+sys/sysctl.h:21:2: error: "The <sys/sysctl.h> header is deprecated and will be removed." [-Werror,-W#warnings]
+
+[1] https://sourceware.org/git/?p=glibc.git;a=commit;h=744e829637162bb7d5029632aacf341c64b86990
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem at gmail.com>
+---
+ src/helper/options.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/helper/options.c b/src/helper/options.c
+index 12755e010..4007e37f6 100644
+--- a/src/helper/options.c
++++ b/src/helper/options.c
+@@ -34,7 +34,7 @@
+ #if IS_DARWIN
+ #include <libproc.h>
+ #endif
+-#ifdef HAVE_SYS_SYSCTL_H
++#if defined(HAVE_SYS_SYSCTL_H) && !defined(__GLIBC__)
+ #include <sys/sysctl.h>
+ #endif
+ #if IS_WIN32 && !IS_CYGWIN
+-- 
+2.22.0
+
diff --git a/meta-oe/recipes-devtools/openocd/openocd_git.bb b/meta-oe/recipes-devtools/openocd/openocd_git.bb
index b50c3ac..df10177 100644
--- a/meta-oe/recipes-devtools/openocd/openocd_git.bb
+++ b/meta-oe/recipes-devtools/openocd/openocd_git.bb
@@ -10,6 +10,7 @@ SRC_URI = " \
     git://repo.or.cz/r/jimtcl.git;protocol=http;destsuffix=git/jimtcl;name=jimtcl \
     git://repo.or.cz/r/libjaylink.git;protocol=http;destsuffix=git/src/jtag/drivers/libjaylink;name=libjaylink \
     file://0001-esirisc_flash-Rename-PAGE_SIZE-to-FLASH_PAGE_SIZE.patch \
+    file://0001-Do-not-include-syscrtl.h-with-glibc.patch \
 "
 
 SRCREV_FORMAT = "openocd"

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


More information about the Openembedded-commits mailing list