d_asctime_r=''
d_asinh=''
d_atanh=''
+d_attribute_always_inline=''
d_attribute_deprecated=''
d_attribute_format=''
d_attribute_malloc=''
d_madvise=''
d_malloc_good_size=''
d_malloc_size=''
+d_malloc_usable_size=''
d_mblen=''
d_mbrlen=''
d_mbrtowc=''
signal_t=''
d_wait4=''
d_waitpid=''
+d_wcrtomb=''
d_wcscmp=''
d_wcstombs=''
d_wcsxfrm=''
set backtrace d_backtrace
eval $inlibc
-: add flags if using c backtrace
+: Check if C backtrace is actually supported.
case "$usecbacktrace" in
"") usecbacktrace=$undef ;;
[yY]*|true|$define)
case "$d_backtrace" in
[yY]*|true|$define)
- case " $ccflags " in
- *" -DUSE_C_BACKTRACE "*) ;; # Already there.
- *) ccflags="$ccflags -DUSE_C_BACKTRACE -g" ;;
- esac
;;
*)
echo "This system does not support backtrace" >&4
eval $setvar
$rm -f attrib*
+: Look for GCC-style attribute always_inline
+case "$d_attribute_always_inline" in
+'')
+echo " "
+echo "Checking whether your compiler can handle __attribute__((always_inline)) ..." >&4
+$cat >attrib.c <<'EOCP'
+#include <stdio.h>
+static __inline__ __attribute__((always_inline)) int I_will_always_be_inlined(void);
+EOCP
+if $cc $ccflags -c attrib.c >attrib.out 2>&1 ; then
+ if $contains 'warning' attrib.out >/dev/null 2>&1; then
+ echo "Your C compiler doesn't support __attribute__((always_inline))."
+ val="$undef"
+ else
+ echo "Your C compiler supports __attribute__((always_inline))."
+ val="$define"
+ fi
+else
+ echo "Your C compiler doesn't seem to understand __attribute__ at all."
+ val="$undef"
+fi
+;;
+*) val="$d_attribute_always_inline" ;;
+esac
+set d_attribute_always_inline
+eval $setvar
+$rm -f attrib*
+
: see if getpgrp exists
set getpgrp d_getpgrp
eval $inlibc
echo "Checking to see if you have isless..." >&4
$cat >try.c <<EOCP
#include <math.h>
-int main() { return isless(0.0); }
+int main() { return isless(2.0, 1.0); }
EOCP
set try
if eval $compile; then
set malloc_good_size d_malloc_good_size
eval $inlibc
+: see if malloc_usable_size exists
+set malloc_usable_size d_malloc_usable_size
+eval $inlibc
+
: see if mblen exists
set mblen d_mblen
eval $inlibc
set waitpid d_waitpid
eval $inlibc
+: see if wcrtomb exists
+set wcrtomb d_wcrtomb
+eval $inlibc
+
: look for wcscmp
echo " "
$cat >try.c <<'EOCP'
d_atanh='$d_atanh'
d_atolf='$d_atolf'
d_atoll='$d_atoll'
+d_attribute_always_inline='$d_attribute_always_inline'
d_attribute_deprecated='$d_attribute_deprecated'
d_attribute_format='$d_attribute_format'
d_attribute_malloc='$d_attribute_malloc'
d_madvise='$d_madvise'
d_malloc_good_size='$d_malloc_good_size'
d_malloc_size='$d_malloc_size'
+d_malloc_usable_size='$d_malloc_usable_size'
d_mblen='$d_mblen'
d_mbrlen='$d_mbrlen'
d_mbrtowc='$d_mbrtowc'
d_vsnprintf='$d_vsnprintf'
d_wait4='$d_wait4'
d_waitpid='$d_waitpid'
+d_wcrtomb='$d_wcrtomb'
d_wcscmp='$d_wcscmp'
d_wcstombs='$d_wcstombs'
d_wcsxfrm='$d_wcsxfrm'