valgrind: fix musl compile
PATCH v2 1/1 valgrind: fix musl compile
Add musl libc detection (based on suggestions by Romain Naour and Arnout Vandecappelle) and add some tweaks for musl support (based on OpenWRT patch [1]).
Fixes ([2]):
checking the glibc version... unsupported version
configure: error: Valgrind requires glibc version 2.2 or later
Patch suggested upstream (see [3]).
[1] https://dev.openwrt.org/browser/trunk/package/devel/valgrind/patches/200-musl_fix.patch?rev=46302
[2] http://autobuild.buildroot.org/results/7b0/7b048ba58918f0a08498c61327fcf35a85a84837
[3] https://bugs.kde.org/show_bug.cgi?id=359202
---
Changes v1 -> v2:
- add proper musl libc detection (suggested by Romain Naour and Arnout Vandecappelle)
--- package/valgrind/0004-Fixes-for-musl-libc.patch | 98 +++++++++++++++++++++++++ package/valgrind/valgrind.mk | 3 + 2 files changed, 101 insertions(+) create mode 100644 package/valgrind/0004-Fixes-for-musl-libc.patch
package/valgrind/0004-Fixes-for-musl-libc.patch new file +98 -0
@@ -0,0 +1,98 @@ +From d096693009d951e9e235a880db906b0dfcdd5733 Mon Sep 17 00:00:00 2001 +From: Peter Seiderer <[email protected]> +Date: Sat, 31 Oct 2015 19:45:04 +0100 +Subject: [PATCH] Fixes for musl libc. + +- add musl libc detection (prevents configure error) +- adjust preload and symbol names (based on the OpenWrt + patch, see [1]) + +[1] https://dev.openwrt.org/browser/trunk/package/devel/valgrind/patches/200-musl_fix.patch?rev=46302 + +Signed-off-by: Peter Seiderer <[email protected]> +--- + configure.ac | 14 +++++++++++++- + coregrind/vg_preloaded.c | 2 +- + include/pub_tool_redir.h | 9 ++++++++- + 3 files changed, 22 insertions(+), 3 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 8ab7f9b..e9d71cd 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -1009,6 +1009,13 @@ if test x$VGCONF_PLATFORM_PRI_CAPS = xX86_SOLARIS \ + GLIBC_VERSION="solaris" + fi + ++# GLIBC_VERSION is empty if a musl libc is used, so use the toolchain tuple ++# in this case. ++if test x$GLIBC_VERSION = x; then ++ if $CC -dumpmachine | grep -q musl; then ++ GLIBC_VERSION=musl ++ fi ++fi + + AC_MSG_CHECKING([the glibc version]) + +@@ -1064,10 +1071,15 @@ case "${GLIBC_VERSION}" in + # DEFAULT_SUPP set in host_os switch-case above. + # No other suppression file is used. + ;; ++ musl) ++ AC_MSG_RESULT(Musl) ++ AC_DEFINE([MUSL_LIBC], 1, [Define to 1 if you're using Musl libc]) ++ # no DEFAULT_SUPP file yet for musl libc. ++ ;; + 2.0|2.1|*) + AC_MSG_RESULT([unsupported version ${GLIBC_VERSION}]) + AC_MSG_ERROR([Valgrind requires glibc version 2.2 or later,]) +- AC_MSG_ERROR([Darwin libc, Bionic libc or Solaris libc]) ++ AC_MSG_ERROR([musl libc, Darwin libc, Bionic libc or Solaris libc]) + ;; + esac + +diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c +index 2ea7a7a..e49c832 100644 +--- a/coregrind/vg_preloaded.c ++++ b/coregrind/vg_preloaded.c +@@ -56,7 +56,7 @@ + void VG_NOTIFY_ON_LOAD(freeres)( void ); + void VG_NOTIFY_ON_LOAD(freeres)( void ) + { +-# if !defined(__UCLIBC__) \ ++# if !defined(__UCLIBC__) && defined(__GLIBC__) \ + && !defined(VGPV_arm_linux_android) \ + && !defined(VGPV_x86_linux_android) \ + && !defined(VGPV_mips32_linux_android) \ +diff --git a/include/pub_tool_redir.h b/include/pub_tool_redir.h +index bac00d7..b8cd97e 100644 +--- a/include/pub_tool_redir.h ++++ b/include/pub_tool_redir.h +@@ -242,8 +242,11 @@ + /* --- Soname of the standard C library. --- */ + + #if defined(VGO_linux) || defined(VGO_solaris) ++# if defined(__GLIBC__) || defined(__UCLIBC__) + # define VG_Z_LIBC_SONAME libcZdsoZa // libc.so* +- ++#else ++# define VG_Z_LIBC_SONAME libcZdZa // libc.* ++#endif + #elif defined(VGO_darwin) && (DARWIN_VERS <= DARWIN_10_6) + # define VG_Z_LIBC_SONAME libSystemZdZaZddylib // libSystem.*.dylib + +@@ -274,7 +277,11 @@ + /* --- Soname of the pthreads library. --- */ + + #if defined(VGO_linux) ++# if defined(__GLIBC__) || defined(__UCLIBC__) + # define VG_Z_LIBPTHREAD_SONAME libpthreadZdsoZd0 // libpthread.so.0 ++#else ++# define VG_Z_LIBPTHREAD_SONAME libcZdZa // libc.* ++#endif + #elif defined(VGO_darwin) + # define VG_Z_LIBPTHREAD_SONAME libSystemZdZaZddylib // libSystem.*.dylib + #elif defined(VGO_solaris) +-- +2.1.4 +
package/valgrind/valgrind.mk +3 -0
@@ -12,6 +12,9 @@ VALGRIND_LICENSE_FILES = COPYING COPYING.DOCS VALGRIND_CONF_OPTS = --disable-ubsan VALGRIND_INSTALL_STAGING = YES +# patch 0004-Fixes-for-musl-libc.patch touching configure.ac +VALGRIND_AUTORECONF = YES + ifeq ($(BR2_GCC_ENABLE_TLS),y) VALGRIND_CONF_OPTS += --enable-tls else
Signature · 1 line
2.1.4
PATCH v2 1/1 valgrind: fix musl compile
Quoted 19 lines · Peter Seiderer
Add musl libc detection (based on suggestions by Romain Naour and Arnout Vandecappelle) and add some tweaks for musl support (based on OpenWRT patch [1]).
Fixes ([2]):
checking the glibc version... unsupported version
configure: error: Valgrind requires glibc version 2.2 or laterPatch suggested upstream (see [3]).
[1] https://dev.openwrt.org/browser/trunk/package/devel/valgrind/patches/200-musl_fix.patch?rev=46302
[2] http://autobuild.buildroot.org/results/7b0/7b048ba58918f0a08498c61327fcf35a85a84837
[3] https://bugs.kde.org/show_bug.cgi?id=359202Signed-off-by Peter Seiderer <[email protected]>---
Changes v1 -> v2:
- add proper musl libc detection (suggested by Romain Naour and Arnout Vandecappelle)
[snip]
package/valgrind/0004-Fixes-for-musl-libc.patch line 50
Quoted 10 lines
++ musl)
++AC_MSG_RESULT(Musl)
++AC_DEFINE([MUSL_LIBC], 1, [Define to 1 if you're using Musl libc])
++ # noDEFAULT_SUPPfile yet for musl libc.
++ ;;package/valgrind/0004-Fixes-for-musl-libc.patch new file +5
-0+ 2.0|2.1|*) + AC_MSG_RESULT([unsupported version ${GLIBC_VERSION}]) + AC_MSG_ERROR([Valgrind requires glibc version 2.2 or later,]) +- AC_MSG_ERROR([Darwin libc, Bionic libc or Solaris libc]) ++ AC_MSG_ERROR([musl libc, Darwin libc, Bionic libc or Solaris libc])
Actuallly, uClibc was already supported as well :-)
package/valgrind/0004-Fixes-for-musl-libc.patch line 63
Quoted 13 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +13
-0+ ;; + esac + +diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c +index 2ea7a7a..e49c832 100644 +--- a/coregrind/vg_preloaded.c ++++ b/coregrind/vg_preloaded.c +@@ -56,7 +56,7 @@ + void VG_NOTIFY_ON_LOAD(freeres)( void ); + void VG_NOTIFY_ON_LOAD(freeres)( void ) + { +-# if !defined(__UCLIBC__) \ ++# if !defined(__UCLIBC__) && defined(__GLIBC__) \
Adding defined(__GLIBC__) effectively excludes android (bionic), doesn't it?
package/valgrind/0004-Fixes-for-musl-libc.patch line 75
Quoted 12 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +12
-0+ && !defined(VGPV_arm_linux_android) \ + && !defined(VGPV_x86_linux_android) \ + && !defined(VGPV_mips32_linux_android) \ +diff --git a/include/pub_tool_redir.h b/include/pub_tool_redir.h +index bac00d7..b8cd97e 100644 +--- a/include/pub_tool_redir.h ++++ b/include/pub_tool_redir.h +@@ -242,8 +242,11 @@ + /* --- Soname of the standard C library. --- */ + + #if defined(VGO_linux) || defined(VGO_solaris) ++# if defined(__GLIBC__) || defined(__UCLIBC__)
AFAICS, on solaris neither of these is defined, so that's probably not good
either. I guess it's better to revert the condition and check on musl instead.
Quoted 5 lines
+ # define
VG_Z_LIBC_SONAMElibcZdsoZa // libc.so*
+-
++#else
++# defineVG_Z_LIBC_SONAMElibcZdZa // libc.*
++#endif
Quoted 8 lines
+ #elif
defined(VGO_darwin)&& (DARWIN_VERS<=DARWIN_10_6)
+ # defineVG_Z_LIBC_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+
+@@ -274,7 +277,11 @@
+ /* --- Soname of the pthreads library. --- */
+
+ #ifdefined(VGO_linux)
++# ifdefined(__GLIBC__)||defined(__UCLIBC__)
Same here.
Regards,
Arnout
Quoted 25 lines
+ # define
VG_Z_LIBPTHREAD_SONAMElibpthreadZdsoZd0 // libpthread.so.0
++#else
++# defineVG_Z_LIBPTHREAD_SONAMElibcZdZa // libc.*
++#endif
+ #elifdefined(VGO_darwin)
+ # defineVG_Z_LIBPTHREAD_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+ #elifdefined(VGO_solaris)
+--
+2.1.4(quoted diff) +1
-0+package/valgrind/valgrind.mk +3
-0@@ -12,6 +12,9 @@ VALGRIND_LICENSE_FILES = COPYING COPYING.DOCS VALGRIND_CONF_OPTS = --disable-ubsan VALGRIND_INSTALL_STAGING = YES +# patch 0004-Fixes-for-musl-libc.patch touching configure.ac +VALGRIND_AUTORECONF = YES + ifeq ($(BR2_GCC_ENABLE_TLS),y) VALGRIND_CONF_OPTS += --enable-tls else
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH v2 1/1 valgrind: fix musl compile
Hello Arnout,
Quoted 32 lines · Arnout Vandecappelle
Quoted 19 lines · Peter Seiderer
Add musl libc detection (based on suggestions by Romain Naour and Arnout Vandecappelle) and add some tweaks for musl support (based on OpenWRT patch [1]).
Fixes ([2]):
checking the glibc version... unsupported version
configure: error: Valgrind requires glibc version 2.2 or laterPatch suggested upstream (see [3]).
[1] https://dev.openwrt.org/browser/trunk/package/devel/valgrind/patches/200-musl_fix.patch?rev=46302
[2] http://autobuild.buildroot.org/results/7b0/7b048ba58918f0a08498c61327fcf35a85a84837
[3] https://bugs.kde.org/show_bug.cgi?id=359202Signed-off-by Peter Seiderer <[email protected]>---
Changes v1 -> v2:
- add proper musl libc detection (suggested by Romain Naour and Arnout Vandecappelle)[snip]
package/valgrind/0004-Fixes-for-musl-libc.patch line 50
Quoted 10 lines
++ musl)
++AC_MSG_RESULT(Musl)
++AC_DEFINE([MUSL_LIBC], 1, [Define to 1 if you're using Musl libc])
++ # noDEFAULT_SUPPfile yet for musl libc.
++ ;;package/valgrind/0004-Fixes-for-musl-libc.patch new file +5
-0+ 2.0|2.1|*) + AC_MSG_RESULT([unsupported version ${GLIBC_VERSION}]) + AC_MSG_ERROR([Valgrind requires glibc version 2.2 or later,]) +- AC_MSG_ERROR([Darwin libc, Bionic libc or Solaris libc]) ++ AC_MSG_ERROR([musl libc, Darwin libc, Bionic libc or Solaris libc])
Quoted 1 line
Actuallly, uClibc was already supported as well :-)
O.k, will add uclibc as well...
Quoted 17 lines
Quoted 4 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +3
-0+ ;; + esac +package/valgrind/0004-Fixes-for-musl-libc.patch line 63
Quoted 10 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +10
-0+diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c +index 2ea7a7a..e49c832 100644 +--- a/coregrind/vg_preloaded.c ++++ b/coregrind/vg_preloaded.c +@@ -56,7 +56,7 @@ + void VG_NOTIFY_ON_LOAD(freeres)( void ); + void VG_NOTIFY_ON_LOAD(freeres)( void ) + { +-# if !defined(__UCLIBC__) \ ++# if !defined(__UCLIBC__) && defined(__GLIBC__) \Adding
defined(__GLIBC__)effectively excludes android (bionic), doesn't it?
Quoted 15 lines
package/valgrind/0004-Fixes-for-musl-libc.patch line 75
Quoted 12 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +12
-0+ && !defined(VGPV_arm_linux_android) \ + && !defined(VGPV_x86_linux_android) \ + && !defined(VGPV_mips32_linux_android) \ +diff --git a/include/pub_tool_redir.h b/include/pub_tool_redir.h +index bac00d7..b8cd97e 100644 +--- a/include/pub_tool_redir.h ++++ b/include/pub_tool_redir.h +@@ -242,8 +242,11 @@ + /* --- Soname of the standard C library. --- */ + + #if defined(VGO_linux) || defined(VGO_solaris) ++# if defined(__GLIBC__) || defined(__UCLIBC__)AFAICS, on solaris neither of these is defined, so that's probably not good
either. I guess it's better to revert the condition and check on musl instead.
O.k, will do...
Quoted 15 lines
Quoted 14 lines
+ # define
VG_Z_LIBC_SONAMElibcZdsoZa // libc.so*
+-
++#else
++# defineVG_Z_LIBC_SONAMElibcZdZa // libc.*
++#endif
+ #elifdefined(VGO_darwin)&& (DARWIN_VERS<=DARWIN_10_6)
+ # defineVG_Z_LIBC_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+
+@@ -274,7 +277,11 @@
+ /* --- Soname of the pthreads library. --- */
+
+ #ifdefined(VGO_linux)
++# ifdefined(__GLIBC__)||defined(__UCLIBC__)
Quoted 2 lines
Same here.
O.k, will do...
Quoted 33 lines
Regards,
ArnoutQuoted 25 lines
+ # define
VG_Z_LIBPTHREAD_SONAMElibpthreadZdsoZd0 // libpthread.so.0
++#else
++# defineVG_Z_LIBPTHREAD_SONAMElibcZdZa // libc.*
++#endif
+ #elifdefined(VGO_darwin)
+ # defineVG_Z_LIBPTHREAD_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+ #elifdefined(VGO_solaris)
+--
+2.1.4(quoted diff) +1
-0+package/valgrind/valgrind.mk +3
-0@@ -12,6 +12,9 @@ VALGRIND_LICENSE_FILES = COPYING COPYING.DOCS VALGRIND_CONF_OPTS = --disable-ubsan VALGRIND_INSTALL_STAGING = YES +# patch 0004-Fixes-for-musl-libc.patch touching configure.ac +VALGRIND_AUTORECONF = YES + ifeq ($(BR2_GCC_ENABLE_TLS),y) VALGRIND_CONF_OPTS += --enable-tls else
PATCH v2 1/1 valgrind: fix musl compile
Hello Arnout,
(one more e-mail, hit the send button too early)
Quoted 36 lines · Peter Seiderer
Hello Arnout,
Quoted 32 lines · Arnout Vandecappelle
Quoted 19 lines · Peter Seiderer
Add musl libc detection (based on suggestions by Romain Naour and Arnout Vandecappelle) and add some tweaks for musl support (based on OpenWRT patch [1]).
Fixes ([2]):
checking the glibc version... unsupported version
configure: error: Valgrind requires glibc version 2.2 or laterPatch suggested upstream (see [3]).
[1] https://dev.openwrt.org/browser/trunk/package/devel/valgrind/patches/200-musl_fix.patch?rev=46302
[2] http://autobuild.buildroot.org/results/7b0/7b048ba58918f0a08498c61327fcf35a85a84837
[3] https://bugs.kde.org/show_bug.cgi?id=359202Signed-off-by Peter Seiderer <[email protected]>---
Changes v1 -> v2:
- add proper musl libc detection (suggested by Romain Naour and Arnout Vandecappelle)[snip]
Quoted 10 lines
++ musl)
++AC_MSG_RESULT(Musl)
++AC_DEFINE([MUSL_LIBC], 1, [Define to 1 if you're using Musl libc])
++ # noDEFAULT_SUPPfile yet for musl libc.
++ ;;package/valgrind/0004-Fixes-for-musl-libc.patch new file +5
-0+ 2.0|2.1|*) + AC_MSG_RESULT([unsupported version ${GLIBC_VERSION}]) + AC_MSG_ERROR([Valgrind requires glibc version 2.2 or later,]) +- AC_MSG_ERROR([Darwin libc, Bionic libc or Solaris libc]) ++ AC_MSG_ERROR([musl libc, Darwin libc, Bionic libc or Solaris libc])
Quoted 20 lines
Quoted 1 line
Actuallly, uClibc was already supported as well :-)
O.k, will add uclibc as well...
Quoted 16 lines
Quoted 4 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +3
-0+ ;; + esac +package/valgrind/0004-Fixes-for-musl-libc.patch line 63
Quoted 10 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +10
-0+diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c +index 2ea7a7a..e49c832 100644 +--- a/coregrind/vg_preloaded.c ++++ b/coregrind/vg_preloaded.c +@@ -56,7 +56,7 @@ + void VG_NOTIFY_ON_LOAD(freeres)( void ); + void VG_NOTIFY_ON_LOAD(freeres)( void ) + { +-# if !defined(__UCLIBC__) \ ++# if !defined(__UCLIBC__) && defined(__GLIBC__) \Adding
defined(__GLIBC__)effectively excludes android (bionic), doesn't it?
Not sure about this one, I think it is o.k. for the buildroot case:
- old behavior was __UCLIBC__ or __GLIBC__ is defined (!__UCLIBC__ means __GLIBC__ is defined)
- new behavior is __UCLIBC__ or __GLIBC__ or MUSL_LIBC is defined, so from !__UCLIBC__ follows __GLIBC__ or MUSL_LIBC, so the need to check explicit for __GLIBC__ ...
Do I miss something? Not sure about the right solution for upstream...
Thanks for review...
Regards,
Peter
Quoted 76 lines
Quoted 16 lines
package/valgrind/0004-Fixes-for-musl-libc.patch line 75
Quoted 13 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +12
-0+ && !defined(VGPV_arm_linux_android) \ + && !defined(VGPV_x86_linux_android) \ + && !defined(VGPV_mips32_linux_android) \ +diff --git a/include/pub_tool_redir.h b/include/pub_tool_redir.h +index bac00d7..b8cd97e 100644 +--- a/include/pub_tool_redir.h ++++ b/include/pub_tool_redir.h +@@ -242,8 +242,11 @@ + /* --- Soname of the standard C library. --- */ + + #if defined(VGO_linux) || defined(VGO_solaris) ++# if defined(__GLIBC__) || defined(__UCLIBC__)AFAICS, on solaris neither of these is defined, so that's probably not good
either. I guess it's better to revert the condition and check on musl instead.O.k, will do...
Quoted 15 lines
Quoted 14 lines
+ # define
VG_Z_LIBC_SONAMElibcZdsoZa // libc.so*
+-
++#else
++# defineVG_Z_LIBC_SONAMElibcZdZa // libc.*
++#endif
+ #elifdefined(VGO_darwin)&& (DARWIN_VERS<=DARWIN_10_6)
+ # defineVG_Z_LIBC_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+
+@@ -274,7 +277,11 @@
+ /* --- Soname of the pthreads library. --- */
+
+ #ifdefined(VGO_linux)
++# ifdefined(__GLIBC__)||defined(__UCLIBC__)Quoted 2 lines
Same here.
O.k, will do...
Quoted 24 lines
Regards,
ArnoutQuoted 18 lines
+ # define
VG_Z_LIBPTHREAD_SONAMElibpthreadZdsoZd0 // libpthread.so.0
++#else
++# defineVG_Z_LIBPTHREAD_SONAMElibcZdZa // libc.*
++#endif
+ #elifdefined(VGO_darwin)
+ # defineVG_Z_LIBPTHREAD_SONAMElibSystemZdZaZddylib // libSystem.*.dylib
+ #elifdefined(VGO_solaris)
+--
+2.1.4(quoted diff) +1
-0+package/valgrind/valgrind.mk +0
-0@@ -12,6 +12,9 @@ VALGRIND_LICENSE_FILES = COPYING COPYING.DOCS VALGRIND_CONF_OPTS = --disable-ubsan VALGRIND_INSTALL_STAGING = YESQuoted 9 lines
package/valgrind/valgrind.mk VALGRIND_LICENSE_FILES = COPYING COPYING.DOCS · line 20
Quoted 7 lines
package/valgrind/valgrind.mk +3
-0+# patch 0004-Fixes-for-musl-libc.patch touching configure.ac +VALGRIND_AUTORECONF = YES + ifeq ($(BR2_GCC_ENABLE_TLS),y) VALGRIND_CONF_OPTS += --enable-tls else_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
PATCH v2 1/1 valgrind: fix musl compile
Quoted 11 lines · Peter Seiderer
Hello Arnout,
(one more e-mail, hit the send button too early)
Quoted 5 lines · Peter Seiderer
Hello Arnout,
Quoted 1 line · Arnout Vandecappelle
On 09-02-16 21:53, Peter Seiderer wrote:
[snip]
Quoted 13 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
package/valgrind/0004-Fixes-for-musl-libc.patch new file +4
-0+diff --git a/coregrind/vg_preloaded.c b/coregrind/vg_preloaded.c +index 2ea7a7a..e49c832 100644 +--- a/coregrind/vg_preloaded.c ++++ b/coregrind/vg_preloaded.cQuoted 8 lines
Quoted 8 lines
Quoted 6 lines
+@@ -56,7 +56,7 @@
+ void VG_NOTIFY_ON_LOAD(freeres)( void );
+ void VG_NOTIFY_ON_LOAD(freeres)( void )
+ {+-# if !defined(__UCLIBC__) \ ++# if !defined(__UCLIBC__) && defined(__GLIBC__) \Adding
defined(__GLIBC__)effectively excludes android (bionic), doesn't it?
Quoted 8 lines
Not sure about this one, I think it is o.k. for the buildroot case:
- old behavior was__UCLIBC__or__GLIBC__is defined (!__UCLIBC__ means__GLIBC__is defined)
- new behavior is__UCLIBC__or__GLIBC__orMUSL_LIBCis defined, so from !__UCLIBC__ follows__GLIBC__orMUSL_LIBC, so the need to check explicit for__GLIBC__...Do I miss something? Not sure about the right solution for upstream...
I did indeed mean for upstream. And also for buildroot in the longer term,
because at some point we _will_ start supporting a fourth libc.
Regards,
Arnout
[snip]
Signature · 6 lines
Arnout Vandecappelle arnout dot vandecappelle at essensium dot com Senior Embedded Software Architect . . . . . . +32-478-010353 (mobile) Essensium, Mind division . . . . . . . . . . . . . . http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium . . . . . BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF