diff options
author | Jim Meyering <jim@meyering.net> | 2003-01-15 21:11:27 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2003-01-15 21:11:27 +0000 |
commit | d7d13fa5c291d0addfe2688ebfe805e0fd4078e3 (patch) | |
tree | 95d792a734f011f62afa100e74cf335cb524bfd6 /m4 | |
parent | d24ceb3b32681f1fa7548ca41d4bbb6cc78ca9d8 (diff) | |
download | coreutils-d7d13fa5c291d0addfe2688ebfe805e0fd4078e3.tar.xz |
Add tsearch.o IFF we have to use the replacement ftw.c.
Diffstat (limited to 'm4')
-rw-r--r-- | m4/ftw.m4 | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -9,6 +9,7 @@ AC_DEFUN([AC_FUNC_FTW], AC_REQUIRE([AC_HEADER_DIRENT]) AC_CHECK_HEADERS(sys/param.h) AC_CHECK_DECLS([stpcpy]) + AC_CHECK_FUNC([tdestroy], , [need_tsearch=1]) # The following test would fail prior to glibc-2.3.2, because `depth' # would be 2 rather than 4. @@ -42,5 +43,11 @@ main () [ac_cv_func_ftw_working=yes], [ac_cv_func_ftw_working=no], [ac_cv_func_ftw_working=no])]) -test $ac_cv_func_ftw_working = no && AC_LIBOBJ([ftw]) +if test $ac_cv_func_ftw_working = no; then + AC_LIBOBJ([ftw]) + # Add tsearch.o IFF we have to use the replacement ftw.c. + if test -n "$need_tsearch"; then + AC_LIBOBJ([tsearch]) + fi +fi ])# AC_FUNC_FTW |