]> granicus.if.org Git - gc/commitdiff
Fix GC shared library tests failure (musl)
authorIvan Maidanski <ivmai@mail.ru>
Fri, 17 Mar 2017 08:21:13 +0000 (11:21 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Fri, 7 Apr 2017 15:59:15 +0000 (18:59 +0300)
Detect dl_iterate_phdr() presence by configure.

* configure.ac (dl_iterate_phdr): Add AC_CHECK_FUNCS for.
* configure.ac [ac_cv_func_dl_iterate_phdr] (HAVE_DL_ITERATE_PHDR):
AC_DEFINE it.

configure.ac

index e944b519230a1a18824cb2a271ed7818c54d3f6b..02d5f05e9a3e900e7f3fff5ffe2e2aa9a4cddfd5 100644 (file)
@@ -462,6 +462,13 @@ if test "$ac_cv_func_getcontext" = "no"; then
   AC_DEFINE([NO_GETCONTEXT], [1], [Missing getcontext()])
 fi
 
+# Check whether dl_iterate_phdr exists (as a strong symbol).
+AC_CHECK_FUNCS([dl_iterate_phdr])
+if test "$ac_cv_func_dl_iterate_phdr" = "yes"; then
+  AC_DEFINE([HAVE_DL_ITERATE_PHDR], [1],
+            [Define if 'dl_iterate_phdr' function is available.])
+fi
+
 case "$host" in
 # While IRIX 6 has libdl for the O32 and N32 ABIs, it's missing for N64
 # and unnecessary everywhere.