From 395a015365e40d2f826658b1216096a6f110f064 Mon Sep 17 00:00:00 2001 From: das Date: Wed, 14 Dec 2005 02:10:17 +0000 Subject: * unix/configure.in: run check for fts API on all platforms, since Linux glibc2 and *BSDs also have this and using fts is more efficient than recursive opendir/readdir (sync with HEAD). * unix/configure: regen. --- ChangeLog | 7 +++++++ unix/configure | 42 ++++++++++++++++++++---------------------- unix/configure.in | 26 ++++++++++++-------------- 3 files changed, 39 insertions(+), 36 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7a1de45..e61d115 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2005-12-14 Daniel Steffen + + * unix/configure.in: run check for fts API on all platforms, since Linux + glibc2 and *BSDs also have this and using fts is more efficient than + recursive opendir/readdir (sync with HEAD). + * unix/configure: regen. + 2005-12-12 Jeff Hobbs * unix/tcl.m4, unix/configure: Fix sh quoting error reported in diff --git a/unix/configure b/unix/configure index d15bc30..97281c5 100755 --- a/unix/configure +++ b/unix/configure @@ -7493,29 +7493,28 @@ EOF #-------------------------------------------------------------------- -# Check for support of fts functions on Darwin (readdir replacement) +# Check for support of fts functions (readdir replacement) #-------------------------------------------------------------------- -if test "`uname -s`" = "Darwin" ; then - echo $ac_n "checking for fts""... $ac_c" 1>&6 -echo "configure:7502: checking for fts" >&5 +echo $ac_n "checking for fts""... $ac_c" 1>&6 +echo "configure:7501: checking for fts" >&5 if eval "test \"`echo '$''{'tcl_cv_api_fts'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - cat > conftest.$ac_ext < conftest.$ac_ext < - #include - #include + #include + #include int main() { char*const p[2] = {"/", NULL}; - FTS *f = fts_open(p, FTS_PHYSICAL|FTS_NOCHDIR|FTS_NOSTAT, NULL); - FTSENT *e = fts_read(f); fts_close(f); + FTS *f = fts_open(p, FTS_PHYSICAL|FTS_NOCHDIR|FTS_NOSTAT, NULL); + FTSENT *e = fts_read(f); fts_close(f); ; return 0; } EOF -if { (eval echo configure:7519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:7518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* tcl_cv_api_fts=yes else @@ -7528,12 +7527,11 @@ rm -f conftest* fi echo "$ac_t""$tcl_cv_api_fts" 1>&6 - if test $tcl_cv_api_fts = yes; then - cat >> confdefs.h <<\EOF +if test $tcl_cv_api_fts = yes; then + cat >> confdefs.h <<\EOF #define HAVE_FTS 1 EOF - fi fi #-------------------------------------------------------------------- @@ -7548,17 +7546,17 @@ fi do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7552: checking for $ac_hdr" >&5 +echo "configure:7550: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7560: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7588,17 +7586,17 @@ done do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:7592: checking for $ac_hdr" >&5 +echo "configure:7590: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:7602: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:7600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -7625,7 +7623,7 @@ fi done echo $ac_n "checking FIONBIO vs. O_NONBLOCK for nonblocking I/O""... $ac_c" 1>&6 -echo "configure:7629: checking FIONBIO vs. O_NONBLOCK for nonblocking I/O" >&5 +echo "configure:7627: checking FIONBIO vs. O_NONBLOCK for nonblocking I/O" >&5 if test -f /usr/lib/NextStep/software_version; then system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` else @@ -7705,7 +7703,7 @@ HTML_DIR='$(DISTDIR)/html' if test "`uname -s`" = "Darwin" ; then echo $ac_n "checking how to package libraries""... $ac_c" 1>&6 -echo "configure:7709: checking how to package libraries" >&5 +echo "configure:7707: checking how to package libraries" >&5 # Check whether --enable-framework or --disable-framework was given. if test "${enable_framework+set}" = set; then enableval="$enable_framework" diff --git a/unix/configure.in b/unix/configure.in index 18079e9..6c0dd88 100644 --- a/unix/configure.in +++ b/unix/configure.in @@ -3,7 +3,7 @@ dnl This file is an input file used by the GNU "autoconf" program to dnl generate the file "configure", which is run during Tcl installation dnl to configure the system for the local environment. # -# RCS: @(#) $Id: configure.in,v 1.106.2.22 2005/12/05 15:10:33 dgp Exp $ +# RCS: @(#) $Id: configure.in,v 1.106.2.23 2005/12/14 02:10:21 das Exp $ AC_INIT(../generic/tcl.h) AC_PREREQ(2.13) @@ -436,21 +436,19 @@ fi SC_ENABLE_LANGINFO #-------------------------------------------------------------------- -# Check for support of fts functions on Darwin (readdir replacement) +# Check for support of fts functions (readdir replacement) #-------------------------------------------------------------------- -if test "`uname -s`" = "Darwin" ; then - AC_CACHE_CHECK([for fts], tcl_cv_api_fts, [ - AC_TRY_LINK([#include - #include - #include ], - [char*const p[2] = {"/", NULL}; - FTS *f = fts_open(p, FTS_PHYSICAL|FTS_NOCHDIR|FTS_NOSTAT, NULL); - FTSENT *e = fts_read(f); fts_close(f);], - tcl_cv_api_fts=yes, tcl_cv_api_fts=no)]) - if test $tcl_cv_api_fts = yes; then - AC_DEFINE(HAVE_FTS) - fi +AC_CACHE_CHECK([for fts], tcl_cv_api_fts, [ + AC_TRY_LINK([#include + #include + #include ], + [char*const p[2] = {"/", NULL}; + FTS *f = fts_open(p, FTS_PHYSICAL|FTS_NOCHDIR|FTS_NOSTAT, NULL); + FTSENT *e = fts_read(f); fts_close(f);], + tcl_cv_api_fts=yes, tcl_cv_api_fts=no)]) +if test $tcl_cv_api_fts = yes; then + AC_DEFINE(HAVE_FTS, 1, [Do we have fts functions?]) fi #-------------------------------------------------------------------- -- cgit v0.12