summaryrefslogtreecommitdiffstats
path: root/unix/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'unix/configure.in')
-rw-r--r--unix/configure.in47
1 files changed, 24 insertions, 23 deletions
diff --git a/unix/configure.in b/unix/configure.in
index b781697..791497f 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.20 2005/11/16 22:05:28 dgp Exp $
+# RCS: @(#) $Id: configure.in,v 1.106.2.21 2005/11/27 02:34:42 das Exp $
AC_INIT(../generic/tcl.h)
AC_PREREQ(2.13)
@@ -24,6 +24,8 @@ fi
if test "${exec_prefix}" = "NONE"; then
exec_prefix=$prefix
fi
+# Make sure srcdir is fully qualified!
+srcdir=`cd $srcdir ; pwd`
TCL_SRC_DIR=`cd $srcdir/..; pwd`
#------------------------------------------------------------------------
@@ -43,11 +45,17 @@ fi
AC_PROG_CC
-#------------------------------------------------------------------------
-# Threads support
-#------------------------------------------------------------------------
+#--------------------------------------------------------------------
+# Supply substitutes for missing POSIX header files. Special
+# notes:
+# - stdlib.h doesn't define strtol, strtoul, or
+# strtod insome versions of SunOS
+# - some versions of string.h don't declare procedures such
+# as strstr
+# Do this early, otherwise an autoconf bug throws errors on configure
+#--------------------------------------------------------------------
-SC_ENABLE_THREADS
+SC_MISSING_POSIX_HEADERS
#------------------------------------------------------------------------
# If we're using GCC, see if the compiler understands -pipe. If so, use it.
@@ -66,6 +74,12 @@ if test -n "$GCC"; then
fi
fi
+#------------------------------------------------------------------------
+# Threads support
+#------------------------------------------------------------------------
+
+SC_ENABLE_THREADS
+
#--------------------------------------------------------------------
# Look for libraries that we will need when compiling the Tcl shell
#--------------------------------------------------------------------
@@ -114,26 +128,13 @@ AC_CHECK_FUNCS(getcwd, , [AC_DEFINE(USEGETWD)])
# Nb: if getcwd uses popen and pwd(1) (like SunOS 4) we should really
# define USEGETWD even if the posix getcwd exists. Add a test ?
-AC_REPLACE_FUNCS(opendir strstr)
-
-AC_REPLACE_FUNCS(strtol strtoll strtoull tmpnam waitpid)
+AC_REPLACE_FUNCS(opendir strstr strtol strtoll strtoull tmpnam waitpid)
AC_CHECK_FUNC(strerror, , [AC_DEFINE(NO_STRERROR)])
AC_CHECK_FUNC(getwd, , [AC_DEFINE(NO_GETWD)])
AC_CHECK_FUNC(wait3, , [AC_DEFINE(NO_WAIT3)])
AC_CHECK_FUNC(uname, , [AC_DEFINE(NO_UNAME)])
AC_CHECK_FUNC(realpath, , [AC_DEFINE(NO_REALPATH)])
-#--------------------------------------------------------------------
-# Supply substitutes for missing POSIX header files. Special
-# notes:
-# - stdlib.h doesn't define strtol, strtoul, or
-# strtod insome versions of SunOS
-# - some versions of string.h don't declare procedures such
-# as strstr
-#--------------------------------------------------------------------
-
-SC_MISSING_POSIX_HEADERS
-
#---------------------------------------------------------------------------
# Determine which interface to use to talk to the serial port.
# Note that #include lines must begin in leftmost column for
@@ -157,19 +158,19 @@ AC_CACHE_VAL(tcl_cv_type_fd_set,
AC_TRY_COMPILE([#include <sys/types.h>],[fd_set readMask, writeMask;],
tcl_cv_type_fd_set=yes, tcl_cv_type_fd_set=no))
AC_MSG_RESULT($tcl_cv_type_fd_set)
-tk_ok=$tcl_cv_type_fd_set
+tcl_ok=$tcl_cv_type_fd_set
if test $tcl_cv_type_fd_set = no; then
AC_MSG_CHECKING([for fd_mask in sys/select])
AC_CACHE_VAL(tcl_cv_grep_fd_mask,
- AC_HEADER_EGREP(fd_mask, sys/select.h,
+ AC_EGREP_HEADER(fd_mask, sys/select.h,
tcl_cv_grep_fd_mask=present, tcl_cv_grep_fd_mask=missing))
AC_MSG_RESULT($tcl_cv_grep_fd_mask)
if test $tcl_cv_grep_fd_mask = present; then
AC_DEFINE(HAVE_SYS_SELECT_H)
- tk_ok=yes
+ tcl_ok=yes
fi
fi
-if test $tk_ok = no; then
+if test $tcl_ok = no; then
AC_DEFINE(NO_FD_SET)
fi