summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhobbs2 <hobbs2>2005-12-02 22:35:36 (GMT)
committerhobbs2 <hobbs2>2005-12-02 22:35:36 (GMT)
commitdfb972345d43ffac4ebd5779a9dbd35aa74a72af (patch)
treeb81d64f214d55e886858e6cead82097752b3f100
parentf7721e1a276fa31e0f6443c3ba5c33607e9bc8f0 (diff)
downloadtktreectrl-dfb972345d43ffac4ebd5779a9dbd35aa74a72af.zip
tktreectrl-dfb972345d43ffac4ebd5779a9dbd35aa74a72af.tar.gz
tktreectrl-dfb972345d43ffac4ebd5779a9dbd35aa74a72af.tar.bz2
update to TEA 3.4
-rw-r--r--ChangeLog4
-rw-r--r--configure722
-rw-r--r--configure.ac4
-rw-r--r--tclconfig/tcl.m4457
4 files changed, 508 insertions, 679 deletions
diff --git a/ChangeLog b/ChangeLog
index f9955ee..6fe5c1e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2005-12-02 Jeff Hobbs <jeffh@ActiveState.com>
+
+ * tclconfig/tcl.m4, configure.ac, configure: update to TEA 3.4
+
2005-09-27 Jeff Hobbs <jeffh@ActiveState.com>
* generic/tkTreeCtrl.c (LoupeCmd): don't capture display (it
diff --git a/configure b/configure
index ccb5bfe..385ff45 100644
--- a/configure
+++ b/configure
@@ -308,7 +308,7 @@ ac_includes_default="\
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE_PATCHLEVEL CYGPATH EXEEXT PKG_LIB_FILE PKG_STUB_LIB_FILE PKG_STUB_SOURCES PKG_STUB_OBJECTS PKG_TCL_SOURCES PKG_HEADERS PKG_INCLUDES PKG_LIBS PKG_CFLAGS TCL_VERSION TCL_BIN_DIR TCL_SRC_DIR TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC TCL_LIBS TCL_DEFS TCL_EXTRA_CFLAGS TCL_LD_FLAGS TCL_SHLIB_LD_LIBS TK_VERSION TK_BIN_DIR TK_SRC_DIR TK_LIB_FILE TK_LIB_FLAG TK_LIB_SPEC TK_STUB_LIB_FILE TK_STUB_LIB_FLAG TK_STUB_LIB_SPEC TK_LIBS TK_XINCLUDES CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC OBJEXT CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA SET_MAKE RANLIB ac_ct_RANLIB EGREP MATH_LIBS PKG_SOURCES PKG_OBJECTS TCL_TOP_DIR_NATIVE TCL_GENERIC_DIR_NATIVE TCL_UNIX_DIR_NATIVE TCL_WIN_DIR_NATIVE TCL_BMAP_DIR_NATIVE TCL_TOOL_DIR_NATIVE TCL_PLATFORM_DIR_NATIVE TCL_INCLUDES TK_TOP_DIR_NATIVE TK_UNIX_DIR_NATIVE TK_WIN_DIR_NATIVE TK_GENERIC_DIR_NATIVE TK_XLIB_DIR_NATIVE TK_PLATFORM_DIR_NATIVE TK_INCLUDES CLEANFILES TCL_THREADS SHARED_BUILD AR TCLSH_PROG CELIB_DIR LIBOBJS DL_LIBS CFLAGS_DEBUG CFLAGS_OPTIMIZE CFLAGS_WARNING STLIB_LD SHLIB_LD SHLIB_CFLAGS SHLIB_LD_LIBS LDFLAGS_DEBUG LDFLAGS_OPTIMIZE LD_LIBRARY_PATH_VAR TCL_DBGX CFLAGS_DEFAULT LDFLAGS_DEFAULT MAKE_LIB MAKE_SHARED_LIB MAKE_STATIC_LIB MAKE_STUB_LIB RANLIB_STUB WISH_PROG LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS PACKAGE_PATCHLEVEL CYGPATH EXEEXT PKG_LIB_FILE PKG_STUB_LIB_FILE PKG_STUB_SOURCES PKG_STUB_OBJECTS PKG_TCL_SOURCES PKG_HEADERS PKG_INCLUDES PKG_LIBS PKG_CFLAGS TCL_VERSION TCL_BIN_DIR TCL_SRC_DIR TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC TCL_LIBS TCL_DEFS TCL_EXTRA_CFLAGS TCL_LD_FLAGS TCL_SHLIB_LD_LIBS TK_VERSION TK_BIN_DIR TK_SRC_DIR TK_LIB_FILE TK_LIB_FLAG TK_LIB_SPEC TK_STUB_LIB_FILE TK_STUB_LIB_FLAG TK_STUB_LIB_SPEC TK_LIBS TK_XINCLUDES CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC OBJEXT CPP INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA SET_MAKE RANLIB ac_ct_RANLIB EGREP MATH_LIBS PKG_SOURCES PKG_OBJECTS TCL_TOP_DIR_NATIVE TCL_GENERIC_DIR_NATIVE TCL_UNIX_DIR_NATIVE TCL_WIN_DIR_NATIVE TCL_BMAP_DIR_NATIVE TCL_TOOL_DIR_NATIVE TCL_PLATFORM_DIR_NATIVE TCL_INCLUDES TK_TOP_DIR_NATIVE TK_UNIX_DIR_NATIVE TK_WIN_DIR_NATIVE TK_GENERIC_DIR_NATIVE TK_XLIB_DIR_NATIVE TK_PLATFORM_DIR_NATIVE TK_INCLUDES CLEANFILES TCL_THREADS SHARED_BUILD AR CELIB_DIR LIBOBJS DL_LIBS CFLAGS_DEBUG CFLAGS_OPTIMIZE CFLAGS_WARNING STLIB_LD SHLIB_LD SHLIB_CFLAGS SHLIB_LD_LIBS LDFLAGS_DEBUG LDFLAGS_OPTIMIZE LD_LIBRARY_PATH_VAR TCL_DBGX CFLAGS_DEFAULT LDFLAGS_DEFAULT MAKE_LIB MAKE_SHARED_LIB MAKE_STATIC_LIB MAKE_STUB_LIB RANLIB_STUB TCLSH_PROG WISH_PROG LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@@ -1328,7 +1328,7 @@ _ACEOF
# TEA extensions pass this us the version of TEA they think they
# are compatible with.
- TEA_VERSION="3.2"
+ TEA_VERSION="3.4"
echo "$as_me:$LINENO: checking for correct TEA configuration" >&5
echo $ECHO_N "checking for correct TEA configuration... $ECHO_C" >&6
@@ -1339,15 +1339,15 @@ echo "$as_me: error:
The PACKAGE_NAME variable must be defined by your TEA configure.in" >&2;}
{ (exit 1); exit 1; }; }
fi
- if test x"3.2" = x ; then
+ if test x"3.4" = x ; then
{ { echo "$as_me:$LINENO: error:
TEA version not specified." >&5
echo "$as_me: error:
TEA version not specified." >&2;}
{ (exit 1); exit 1; }; }
- elif test "3.2" != "${TEA_VERSION}" ; then
- echo "$as_me:$LINENO: result: warning: requested TEA version \"3.2\", have \"${TEA_VERSION}\"" >&5
-echo "${ECHO_T}warning: requested TEA version \"3.2\", have \"${TEA_VERSION}\"" >&6
+ elif test "3.4" != "${TEA_VERSION}" ; then
+ echo "$as_me:$LINENO: result: warning: requested TEA version \"3.4\", have \"${TEA_VERSION}\"" >&5
+echo "${ECHO_T}warning: requested TEA version \"3.4\", have \"${TEA_VERSION}\"" >&6
else
echo "$as_me:$LINENO: result: ok (TEA ${TEA_VERSION})" >&5
echo "${ECHO_T}ok (TEA ${TEA_VERSION})" >&6
@@ -1523,6 +1523,20 @@ echo "$as_me: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" >
done
fi
+ # on Darwin, check in Framework installation locations
+ if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
+ for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
+ `ls -d /Library/Frameworks 2>/dev/null` \
+ `ls -d /Network/Library/Frameworks 2>/dev/null` \
+ `ls -d /System/Library/Frameworks 2>/dev/null` \
+ ; do
+ if test -f "$i/Tcl.framework/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
+ break
+ fi
+ done
+ fi
+
# check in a few common install locations
if test x"${ac_cv_c_tclconfig}" = x ; then
for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
@@ -1696,6 +1710,21 @@ echo "$as_me: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" >&2
fi
done
fi
+
+ # on Darwin, check in Framework installation locations
+ if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
+ for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
+ `ls -d /Library/Frameworks 2>/dev/null` \
+ `ls -d /Network/Library/Frameworks 2>/dev/null` \
+ `ls -d /System/Library/Frameworks 2>/dev/null` \
+ ; do
+ if test -f "$i/Tk.framework/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
+ break
+ fi
+ done
+ fi
+
# check in a few common install locations
if test x"${ac_cv_c_tkconfig}" = x ; then
for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
@@ -1726,6 +1755,7 @@ echo "$as_me: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" >&2
fi
+
if test x"${ac_cv_c_tkconfig}" = x ; then
TK_BIN_DIR="# no Tk configs found"
{ echo "$as_me:$LINENO: WARNING: \"Cannot find Tk configuration definitions\"" >&5
@@ -1740,7 +1770,6 @@ echo "${ECHO_T}found $TK_BIN_DIR/tkConfig.sh" >&6
fi
-
echo "$as_me:$LINENO: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
echo $ECHO_N "checking for existence of ${TK_BIN_DIR}/tkConfig.sh... $ECHO_C" >&6
@@ -1784,7 +1813,7 @@ _ACEOF
;;
esac
elif test "${TEA_PLATFORM}" = "windows" ; then
- TEA_WINDOWINGSYSTEM="windows"
+ TEA_WINDOWINGSYSTEM="win32"
fi
#
@@ -6384,9 +6413,20 @@ echo $ECHO_N "checking for Tcl private include files... $ECHO_C" >&6
else
TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
fi
- # We want to ensure these are substitured so as not to require
+ # We want to ensure these are substituted so as not to require
# any *_NATIVE vars be defined in the Makefile
TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
+ if test "`uname -s`" = "Darwin"; then
+ # If Tcl was built as a framework, attempt to use
+ # the framework's Headers and PrivateHeaders directories
+ case ${TCL_DEFS} in
+ *TCL_FRAMEWORK*)
+ if test -d "${TCL_BIN_DIR}/Headers" -a -d "${TCL_BIN_DIR}/PrivateHeaders"; then
+ TCL_INCLUDES="-I\"${TCL_BIN_DIR}/Headers\" -I\"${TCL_BIN_DIR}/PrivateHeaders\" ${TCL_INCLUDES}"; else
+ TCL_INCLUDES="${TCL_INCLUDES} ${TCL_INCLUDE_SPEC} `echo "${TCL_INCLUDE_SPEC}" | sed -e 's/Headers/PrivateHeaders/'`"; fi
+ ;;
+ esac
+ fi
@@ -6417,16 +6457,26 @@ echo $ECHO_N "checking for Tk private include files... $ECHO_C" >&6
else
TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
fi
- # We want to ensure these are substitured so as not to require
+ # We want to ensure these are substituted so as not to require
# any *_NATIVE vars be defined in the Makefile
TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
- if test "${TEA_WINDOWINGSYSTEM}" = "windows" \
+ if test "${TEA_WINDOWINGSYSTEM}" = "win32" \
-o "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
TK_INCLUDES="${TK_INCLUDES} -I${TK_XLIB_DIR_NATIVE}"
fi
if test "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
TK_INCLUDES="${TK_INCLUDES} -I${TK_SRC_DIR_NATIVE}/macosx"
fi
+ if test "`uname -s`" = "Darwin"; then
+ # If Tk was built as a framework, attempt to use
+ # the framework's Headers and PrivateHeaders directories
+ case ${TK_DEFS} in
+ *TK_FRAMEWORK*)
+ if test -d "${TK_BIN_DIR}/Headers" -a -d "${TK_BIN_DIR}/PrivateHeaders"; then
+ TK_INCLUDES="-I\"${TK_BIN_DIR}/Headers\" -I\"${TK_BIN_DIR}/PrivateHeaders\" ${TK_INCLUDES}"; fi
+ ;;
+ esac
+ fi
@@ -6445,7 +6495,7 @@ echo "${ECHO_T}Using srcdir found in tkConfig.sh: ${TK_SRC_DIR}" >&6
#--------------------------------------------------------------------
- if test "${TEA_PLATFORM}" = "unix" ; then
+ if test "${TEA_WINDOWINGSYSTEM}" = "x11" ; then
echo "$as_me:$LINENO: checking for X" >&5
echo $ECHO_N "checking for X... $ECHO_C" >&6
@@ -6951,9 +7001,16 @@ if test "${enable_threads+set}" = set; then
enableval="$enable_threads"
tcl_ok=$enableval
else
- tcl_ok=
+ tcl_ok=yes
fi;
+ if test "${enable_threads+set}" = set; then
+ enableval="$enable_threads"
+ tcl_ok=$enableval
+ else
+ tcl_ok=yes
+ fi
+
if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
TCL_THREADS=1
@@ -7354,216 +7411,6 @@ echo "$as_me: WARNING: \"Don t know how to find pthread lib on your system - thr
fi
fi
- # Does the pthread-implementation provide
- # 'pthread_attr_setstacksize' ?
-
- ac_saved_libs=$LIBS
- LIBS="$LIBS $THREADS_LIBS"
-
-for ac_func in pthread_attr_setstacksize
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-char (*f) () = $ac_func;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
-int
-main ()
-{
-return f != $ac_func;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- eval "$as_ac_var=yes"
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-eval "$as_ac_var=no"
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
- LIBS=$ac_saved_libs
-
-for ac_func in readdir_r
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h. */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h. */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* Override any gcc2 internal prototype to avoid an error. */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-char (*f) () = $ac_func;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
-int
-main ()
-{
-return f != $ac_func;
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
- (eval $ac_link) 2>conftest.er1
- ac_status=$?
- grep -v '^ *+' conftest.er1 >conftest.err
- rm -f conftest.er1
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } &&
- { ac_try='test -z "$ac_c_werror_flag"
- || test ! -s conftest.err'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; } &&
- { ac_try='test -s conftest$ac_exeext'
- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
- (eval $ac_try) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; }; then
- eval "$as_ac_var=yes"
-else
- echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-eval "$as_ac_var=no"
-fi
-rm -f conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
- cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
fi
else
TCL_THREADS=0
@@ -7578,11 +7425,11 @@ cat >>confdefs.h <<\_ACEOF
_ACEOF
#LIBS="$LIBS $THREADS_LIBS"
- echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
+ echo "$as_me:$LINENO: result: yes (default)" >&5
+echo "${ECHO_T}yes (default)" >&6
else
- echo "$as_me:$LINENO: result: no (default)" >&5
-echo "${ECHO_T}no (default)" >&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
# TCL_THREADS sanity checking. See if our request for building with
# threads is the same as the way Tcl was built. If not, warn the user.
@@ -7590,21 +7437,23 @@ echo "${ECHO_T}no (default)" >&6
*THREADS=1*)
if test "${TCL_THREADS}" = "0"; then
{ echo "$as_me:$LINENO: WARNING:
- Building ${PACKAGE_NAME} without threads enabled, but building against a Tcl
- that IS thread-enabled." >&5
+ Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
+ that IS thread-enabled. It is recommended to use --enable-threads." >&5
echo "$as_me: WARNING:
- Building ${PACKAGE_NAME} without threads enabled, but building against a Tcl
- that IS thread-enabled." >&2;}
+ Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
+ that IS thread-enabled. It is recommended to use --enable-threads." >&2;}
fi
;;
*)
if test "${TCL_THREADS}" = "1"; then
{ echo "$as_me:$LINENO: WARNING:
- --enable-threads requested, but attempting building against a Tcl
- that is NOT thread-enabled." >&5
+ --enable-threads requested, but building against a Tcl that is NOT
+ thread-enabled. This is an OK configuration that will also run in
+ a thread-enabled core." >&5
echo "$as_me: WARNING:
- --enable-threads requested, but attempting building against a Tcl
- that is NOT thread-enabled." >&2;}
+ --enable-threads requested, but building against a Tcl that is NOT
+ thread-enabled. This is an OK configuration that will also run in
+ a thread-enabled core." >&2;}
fi
;;
esac
@@ -7658,50 +7507,6 @@ _ACEOF
#--------------------------------------------------------------------
- # Allow the user to provide this setting in the env
- if test "x${TCLSH_PROG}" = "x" ; then
- echo "$as_me:$LINENO: checking for tclsh" >&5
-echo $ECHO_N "checking for tclsh... $ECHO_C" >&6
-
- if test "${ac_cv_path_tclsh+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- search_path=`echo ${PATH} | sed -e 's/:/ /g'`
- if test "${TEA_PLATFORM}" != "windows" -o \
- \( "$do64bit_ok" = "no" -a "$doWince" = "no" \) ; then
- # Do not allow target tclsh in known cross-compile builds,
- # as we need one we can run on this system
- search_path="${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin ${exec_prefix}/bin ${prefix}/bin ${search_path}"
- fi
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- echo "$as_me:$LINENO: result: $TCLSH_PROG" >&5
-echo "${ECHO_T}$TCLSH_PROG" >&6
- else
- { { echo "$as_me:$LINENO: error: No tclsh found in PATH: $search_path" >&5
-echo "$as_me: error: No tclsh found in PATH: $search_path" >&2;}
- { (exit 1); exit 1; }; }
- fi
- fi
-
-
-
# Step 0: Enable 64 bit support?
@@ -7923,47 +7728,41 @@ fi
windows)
# This is a 2-stage check to make sure we have the 64-bit SDK
# We have to know where the SDK is installed.
- if test "$do64bit" = "yes" ; then
+ # This magic is based on MS Platform SDK for Win2003 SP1 - hobbs
+ # MACHINE is IX86 for LINK, but this is used by the manifest,
+ # which requires x86|amd64|ia64.
+ MACHINE="X86"
+ if test "$do64bit" != "no" ; then
if test "x${MSSDK}x" = "xx" ; then
- MSSDK="C:/Progra~1/Microsoft SDK"
+ MSSDK="C:/Progra~1/Microsoft Platform SDK"
fi
- # Ensure that this path has no spaces to work in autoconf
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- # we need TCLSH_PROG defined to get Windows short pathnames
-
-
- echo "$as_me:$LINENO: checking short pathname for MSSDK (${MSSDK})" >&5
-echo $ECHO_N "checking short pathname for MSSDK (${MSSDK})... $ECHO_C" >&6
-
- shortpath=
- case "${MSSDK}" in
- *\ *)
- # Only do this if we need to.
- shortpath=`echo "puts [file attributes {${MSSDK}} -shortname] ; exit" | ${TCLSH_PROG} 2>/dev/null`
- ;;
- esac
- if test "x${shortpath}" = "x" ; then
- echo "$as_me:$LINENO: result: not changed" >&5
-echo "${ECHO_T}not changed" >&6
- else
- MSSDK=$shortpath
- echo "$as_me:$LINENO: result: ${MSSDK}" >&5
-echo "${ECHO_T}${MSSDK}" >&6
- fi
- fi
-
- if test ! -d "${MSSDK}/bin/win64" ; then
- { echo "$as_me:$LINENO: WARNING: could not find 64-bit SDK to enable 64bit mode" >&5
-echo "$as_me: WARNING: could not find 64-bit SDK to enable 64bit mode" >&2;}
+ MSSDK=`echo "$MSSDK" | sed -e 's!\\\!/!g'`
+ PATH64=""
+ case "$do64bit" in
+ amd64|x64|yes)
+ MACHINE="AMD64" ; # default to AMD64 64-bit build
+ PATH64="${MSSDK}/Bin/Win64/x86/AMD64"
+ ;;
+ ia64)
+ MACHINE="IA64"
+ PATH64="${MSSDK}/Bin/Win64"
+ ;;
+ esac
+ if test ! -d "${PATH64}" ; then
+ { echo "$as_me:$LINENO: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&5
+echo "$as_me: WARNING: Could not find 64-bit $MACHINE SDK to enable 64bit mode" >&2;}
+ { echo "$as_me:$LINENO: WARNING: Ensure latest Platform SDK is installed" >&5
+echo "$as_me: WARNING: Ensure latest Platform SDK is installed" >&2;}
do64bit="no"
else
+ echo "$as_me:$LINENO: result: Using 64-bit $MACHINE mode" >&5
+echo "${ECHO_T} Using 64-bit $MACHINE mode" >&6
do64bit_ok="yes"
fi
fi
if test "$doWince" != "no" ; then
- if test "$do64bit" = "yes" ; then
+ if test "$do64bit" != "no" ; then
{ { echo "$as_me:$LINENO: error: Windows/CE and 64-bit builds incompatible" >&5
echo "$as_me: error: Windows/CE and 64-bit builds incompatible" >&2;}
{ (exit 1); exit 1; }; }
@@ -8031,33 +7830,9 @@ echo "$as_me: error: Cannot find celib support library directory" >&2;}
else
no_celib=
CELIB_DIR=${ac_cv_c_celibconfig}
+ CELIB_DIR=`echo "$CELIB_DIR" | sed -e 's!\\\!/!g'`
echo "$as_me:$LINENO: result: found $CELIB_DIR" >&5
echo "${ECHO_T}found $CELIB_DIR" >&6
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- # we need TCLSH_PROG defined to get Windows short pathnames
-
-
- echo "$as_me:$LINENO: checking short pathname for CELIB_DIR (${ac_cv_c_celibconfig})" >&5
-echo $ECHO_N "checking short pathname for CELIB_DIR (${ac_cv_c_celibconfig})... $ECHO_C" >&6
-
- shortpath=
- case "${ac_cv_c_celibconfig}" in
- *\ *)
- # Only do this if we need to.
- shortpath=`echo "puts [file attributes {${ac_cv_c_celibconfig}} -shortname] ; exit" | ${TCLSH_PROG} 2>/dev/null`
- ;;
- esac
- if test "x${shortpath}" = "x" ; then
- echo "$as_me:$LINENO: result: not changed" >&5
-echo "${ECHO_T}not changed" >&6
- else
- CELIB_DIR=$shortpath
- echo "$as_me:$LINENO: result: ${CELIB_DIR}" >&5
-echo "${ECHO_T}${CELIB_DIR}" >&6
- fi
- fi
-
fi
fi
@@ -8095,57 +7870,8 @@ echo "${ECHO_T}${CELIB_DIR}" >&6
SDKROOT="C:/Windows CE Tools"
fi
fi
- # Ensure that this path has no spaces to work in autoconf
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- # we need TCLSH_PROG defined to get Windows short pathnames
-
-
- echo "$as_me:$LINENO: checking short pathname for WCEROOT (${WCEROOT})" >&5
-echo $ECHO_N "checking short pathname for WCEROOT (${WCEROOT})... $ECHO_C" >&6
-
- shortpath=
- case "${WCEROOT}" in
- *\ *)
- # Only do this if we need to.
- shortpath=`echo "puts [file attributes {${WCEROOT}} -shortname] ; exit" | ${TCLSH_PROG} 2>/dev/null`
- ;;
- esac
- if test "x${shortpath}" = "x" ; then
- echo "$as_me:$LINENO: result: not changed" >&5
-echo "${ECHO_T}not changed" >&6
- else
- WCEROOT=$shortpath
- echo "$as_me:$LINENO: result: ${WCEROOT}" >&5
-echo "${ECHO_T}${WCEROOT}" >&6
- fi
- fi
-
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- # we need TCLSH_PROG defined to get Windows short pathnames
-
-
- echo "$as_me:$LINENO: checking short pathname for SDKROOT (${SDKROOT})" >&5
-echo $ECHO_N "checking short pathname for SDKROOT (${SDKROOT})... $ECHO_C" >&6
-
- shortpath=
- case "${SDKROOT}" in
- *\ *)
- # Only do this if we need to.
- shortpath=`echo "puts [file attributes {${SDKROOT}} -shortname] ; exit" | ${TCLSH_PROG} 2>/dev/null`
- ;;
- esac
- if test "x${shortpath}" = "x" ; then
- echo "$as_me:$LINENO: result: not changed" >&5
-echo "${ECHO_T}not changed" >&6
- else
- SDKROOT=$shortpath
- echo "$as_me:$LINENO: result: ${SDKROOT}" >&5
-echo "${ECHO_T}${SDKROOT}" >&6
- fi
- fi
-
+ WCEROOT=`echo "$WCEROOT" | sed -e 's!\\\!/!g'`
+ SDKROOT=`echo "$SDKROOT" | sed -e 's!\\\!/!g'`
if test ! -d "${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}" \
-o ! -d "${WCEROOT}/EVC/${OSVERSION}/bin"; then
{ { echo "$as_me:$LINENO: error: could not find PocketPC SDK or target compiler to enable WinCE mode $CEVERSION,$TARGETCPU,$ARCH,$PLATFORM" >&5
@@ -8170,27 +7896,37 @@ echo "$as_me: error: could not find PocketPC SDK or target compiler to enable Wi
runtime=-MD
fi
- if test "$do64bit" = "yes" ; then
+ if test "$do64bit" != "no" ; then
# All this magic is necessary for the Win64 SDK RC1 - hobbs
- CC="${MSSDK}/Bin/Win64/cl.exe"
- CFLAGS="${CFLAGS} -I${MSSDK}/Include/prerelease \
- -I${MSSDK}/Include/Win64/crt \
- -I${MSSDK}/Include"
- RC="${MSSDK}/bin/rc.exe"
- lflags="-MACHINE:IA64 -LIBPATH:${MSSDK}/Lib/IA64 \
- -LIBPATH:${MSSDK}/Lib/Prerelease/IA64 -nologo"
- LINKBIN="${MSSDK}/bin/win64/link.exe"
+ CC="\"${PATH64}/cl.exe\""
+ CFLAGS="${CFLAGS} -I\"${MSSDK}/Include\" -I\"${MSSDK}/Include/crt\" -I\"${MSSDK}/Include/crt/sys\""
+ RC="\"${MSSDK}/bin/rc.exe\""
+ lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
+ LINKBIN="\"${PATH64}/link.exe\""
CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
+ # Avoid 'unresolved external symbol __security_cookie'
+ # errors, c.f. http://support.microsoft.com/?id=894573
+
+ vars="bufferoverflowU.lib"
+ for i in $vars; do
+ if test "${TEA_PLATFORM}" = "windows" -a "$GCC" = "yes" ; then
+ # Convert foo.lib to -lfoo for GCC. No-op if not *.lib
+ i=`echo "$i" | sed -e 's/^\([^-].*\)\.lib$/-l\1/i'`
+ fi
+ PKG_LIBS="$PKG_LIBS $i"
+ done
+
+
elif test "$doWince" != "no" ; then
CEBINROOT="${WCEROOT}/EVC/${OSVERSION}/bin"
if test "${TARGETCPU}" = "X86"; then
- CC="${CEBINROOT}/cl.exe"
+ CC="\"${CEBINROOT}/cl.exe\""
else
- CC="${CEBINROOT}/cl${ARCH}.exe"
+ CC="\"${CEBINROOT}/cl${ARCH}.exe\""
fi
CFLAGS="$CFLAGS -I\"${CELIB_DIR}/inc\" -I\"${CEINCLUDE}\""
- RC="${WCEROOT}/Common/EVC/bin/rc.exe"
+ RC="\"${WCEROOT}/Common/EVC/bin/rc.exe\""
arch=`echo ${ARCH} | awk '{print tolower($0)}'`
defs="${ARCH} _${ARCH}_ ${arch} PALM_SIZE _MT _WINDOWS"
if test "${SHARED_BUILD}" = "1" ; then
@@ -8218,7 +7954,7 @@ _ACEOF
CFLAGS_OPTIMIZE="-nologo -Ox"
lversion=`echo ${CEVERSION} | sed -e 's/\(.\)\(..\)/\1\.\2/'`
lflags="-MACHINE:${ARCH} -LIBPATH:\"${CELIBPATH}\" -subsystem:windowsce,${lversion} -nologo"
- LINKBIN="${CEBINROOT}/link.exe"
+ LINKBIN="\"${CEBINROOT}/link.exe\""
else
RC="rc"
@@ -8269,9 +8005,14 @@ _ACEOF
AIX-*)
if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
# AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
+ case "${CC}" in
+ *_r)
+ # ok ...
+ ;;
+ *)
+ CC=${CC}_r
+ ;;
+ esac
echo "$as_me:$LINENO: result: Using $CC for compiling with threads" >&5
echo "${ECHO_T}Using $CC for compiling with threads" >&6
fi
@@ -9361,7 +9102,11 @@ rm -f conftest*
Darwin-*)
CFLAGS_OPTIMIZE="-Os"
SHLIB_CFLAGS="-fno-common"
- SHLIB_LD="cc -dynamiclib \${LDFLAGS}"
+ if test $do64bit = yes; then
+ do64bit_ok=yes
+ CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
+ fi
+ SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS}'
echo "$as_me:$LINENO: checking if ld accepts -single_module flag" >&5
echo $ECHO_N "checking if ld accepts -single_module flag... $ECHO_C" >&6
if test "${tcl_cv_ld_single_module+set}" = set; then
@@ -9427,7 +9172,11 @@ echo "${ECHO_T}$tcl_cv_ld_single_module" >&6
SHLIB_SUFFIX=".dylib"
DL_OBJS="tclLoadDyld.o"
DL_LIBS=""
- LDFLAGS="$LDFLAGS -prebind"
+ # Don't use -prebind when building for Mac OS X 10.4 or later only:
+ test -z "${MACOSX_DEPLOYMENT_TARGET}" || \
+ test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F. '{print $2}'`" -lt 4 && \
+ LDFLAGS="$LDFLAGS -prebind"
+ LDFLAGS="$LDFLAGS -headerpad_max_install_names"
echo "$as_me:$LINENO: checking if ld accepts -search_paths_first flag" >&5
echo $ECHO_N "checking if ld accepts -search_paths_first flag... $ECHO_C" >&6
if test "${tcl_cv_ld_search_paths_first+set}" = set; then
@@ -9633,7 +9382,8 @@ _ACEOF
UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
TCL_LIB_VERSIONS_OK=nodots
;;
- SunOS-5.[0-6]*)
+ SunOS-5.[0-6])
+ # Careful to not let 5.10+ fall into this case
# Note: If _REENTRANT isn't defined, then Solaris
# won't define thread-safe library routines.
@@ -9707,10 +9457,21 @@ echo "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;}
CFLAGS="$CFLAGS -xarch=v9"
LDFLAGS="$LDFLAGS -xarch=v9"
fi
+ # Solaris 64 uses this as well
+ #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
fi
+ elif test "$arch" = "amd64 i386" ; then
+ if test "$GCC" = "yes" ; then
+ { echo "$as_me:$LINENO: WARNING: 64bit mode not supported with GCC on $system" >&5
+echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;}
+ else
+ do64bit_ok=yes
+ CFLAGS="$CFLAGS -xarch=amd64"
+ LDFLAGS="$LDFLAGS -xarch=amd64"
+ fi
else
- { echo "$as_me:$LINENO: WARNING: \"64bit mode only supported sparcv9 system\"" >&5
-echo "$as_me: WARNING: \"64bit mode only supported sparcv9 system\"" >&2;}
+ { echo "$as_me:$LINENO: WARNING: 64bit mode not supported for $arch" >&5
+echo "$as_me: WARNING: 64bit mode not supported for $arch" >&2;}
fi
fi
@@ -9818,9 +9579,9 @@ echo "${ECHO_T}$found" >&6
;;
esac
- if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
- { echo "$as_me:$LINENO: WARNING: \"64bit support being disabled -- don\'t know magic for this platform\"" >&5
-echo "$as_me: WARNING: \"64bit support being disabled -- don\'t know magic for this platform\"" >&2;}
+ if test "$do64bit" != "no" -a "$do64bit_ok" = "no" ; then
+ { echo "$as_me:$LINENO: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5
+echo "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;}
fi
# Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
@@ -10838,91 +10599,65 @@ _ACEOF
#--------------------------------------------------------------------
- # Allow the user to provide this setting in the env
- if test "x${TCLSH_PROG}" = "x" ; then
- echo "$as_me:$LINENO: checking for tclsh" >&5
+ echo "$as_me:$LINENO: checking for tclsh" >&5
echo $ECHO_N "checking for tclsh... $ECHO_C" >&6
-
- if test "${ac_cv_path_tclsh+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- search_path=`echo ${PATH} | sed -e 's/:/ /g'`
- if test "${TEA_PLATFORM}" != "windows" -o \
- \( "$do64bit_ok" = "no" -a "$doWince" = "no" \) ; then
- # Do not allow target tclsh in known cross-compile builds,
- # as we need one we can run on this system
- search_path="${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin ${exec_prefix}/bin ${prefix}/bin ${search_path}"
- fi
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- echo "$as_me:$LINENO: result: $TCLSH_PROG" >&5
-echo "${ECHO_T}$TCLSH_PROG" >&6
- else
- { { echo "$as_me:$LINENO: error: No tclsh found in PATH: $search_path" >&5
-echo "$as_me: error: No tclsh found in PATH: $search_path" >&2;}
- { (exit 1); exit 1; }; }
- fi
+ if test -f "${TCL_BIN_DIR}/Makefile" ; then
+ # tclConfig.sh is in Tcl build directory
+ if test "${TEA_PLATFORM}" = "windows"; then
+ TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
+ else
+ TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
+ fi
+ else
+ # tclConfig.sh is in install location
+ if test "${TEA_PLATFORM}" = "windows"; then
+ TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
+ else
+ TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}${TCL_DBGX}"
+ fi
+ list="`ls -d ${TCL_PREFIX}/bin 2>/dev/null` \
+ `ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null`"
+ for i in $list ; do
+ if test -f "$i/${TCLSH_PROG}" ; then
+ REAL_TCL_BIN_DIR="`cd "$i"; pwd`"
+ break
+ fi
+ done
+ TCLSH_PROG="${REAL_TCL_BIN_DIR}/${TCLSH_PROG}"
fi
+ echo "$as_me:$LINENO: result: ${TCLSH_PROG}" >&5
+echo "${ECHO_T}${TCLSH_PROG}" >&6
- # Allow the user to provide this setting in the env
- if test "x${WISH_PROG}" = "x" ; then
- echo "$as_me:$LINENO: checking for wish" >&5
+ echo "$as_me:$LINENO: checking for wish" >&5
echo $ECHO_N "checking for wish... $ECHO_C" >&6
-
- if test "${ac_cv_path_wish+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
- search_path=`echo ${PATH} | sed -e 's/:/ /g'`
- if test "${TEA_PLATFORM}" != "windows" -o \
- \( "$do64bit_ok" = "no" -a "$doWince" = "no" \) ; then
- # Do not allow target wish in known cross-compile builds,
- # as we need one we can run on this system
- search_path="${TK_BIN_DIR} ${TK_BIN_DIR}/../bin ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin ${exec_prefix}/bin ${prefix}/bin ${search_path}"
- fi
- for dir in $search_path ; do
- for j in `ls -r $dir/wish[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/wish*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_wish" = x ; then
- if test -f "$j" ; then
- ac_cv_path_wish=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_wish" ; then
- WISH_PROG=$ac_cv_path_wish
- echo "$as_me:$LINENO: result: $WISH_PROG" >&5
-echo "${ECHO_T}$WISH_PROG" >&6
- else
- { { echo "$as_me:$LINENO: error: No wish found in PATH: $search_path" >&5
-echo "$as_me: error: No wish found in PATH: $search_path" >&2;}
- { (exit 1); exit 1; }; }
- fi
+ if test -f "${TK_BIN_DIR}/Makefile" ; then
+ # tkConfig.sh is in Tk build directory
+ if test "${TEA_PLATFORM}" = "windows"; then
+ WISH_PROG="${TK_BIN_DIR}/wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
+ else
+ WISH_PROG="${TK_BIN_DIR}/wish"
+ fi
+ else
+ # tkConfig.sh is in install location
+ if test "${TEA_PLATFORM}" = "windows"; then
+ WISH_PROG="wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
+ else
+ WISH_PROG="wish${TK_MAJOR_VERSION}.${TK_MINOR_VERSION}${TK_DBGX}"
+ fi
+ list="`ls -d ${TK_PREFIX}/bin 2>/dev/null` \
+ `ls -d ${TK_BIN_DIR}/../bin 2>/dev/null`"
+ for i in $list ; do
+ if test -f "$i/${WISH_PROG}" ; then
+ REAL_TK_BIN_DIR="`cd "$i"; pwd`"
+ break
+ fi
+ done
+ WISH_PROG="${REAL_TK_BIN_DIR}/${WISH_PROG}"
fi
+ echo "$as_me:$LINENO: result: ${WISH_PROG}" >&5
+echo "${ECHO_T}${WISH_PROG}" >&6
@@ -11046,10 +10781,9 @@ for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
# 1. Remove the extension, and $U if already installed.
ac_i=`echo "$ac_i" |
sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
+ # 2. Add them.
+ ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
+ ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
done
LIBOBJS=$ac_libobjs
@@ -11642,7 +11376,6 @@ s,@CLEANFILES@,$CLEANFILES,;t t
s,@TCL_THREADS@,$TCL_THREADS,;t t
s,@SHARED_BUILD@,$SHARED_BUILD,;t t
s,@AR@,$AR,;t t
-s,@TCLSH_PROG@,$TCLSH_PROG,;t t
s,@CELIB_DIR@,$CELIB_DIR,;t t
s,@LIBOBJS@,$LIBOBJS,;t t
s,@DL_LIBS@,$DL_LIBS,;t t
@@ -11664,6 +11397,7 @@ s,@MAKE_SHARED_LIB@,$MAKE_SHARED_LIB,;t t
s,@MAKE_STATIC_LIB@,$MAKE_STATIC_LIB,;t t
s,@MAKE_STUB_LIB@,$MAKE_STUB_LIB,;t t
s,@RANLIB_STUB@,$RANLIB_STUB,;t t
+s,@TCLSH_PROG@,$TCLSH_PROG,;t t
s,@WISH_PROG@,$WISH_PROG,;t t
s,@LTLIBOBJS@,$LTLIBOBJS,;t t
CEOF
diff --git a/configure.ac b/configure.ac
index 59de4e7..0c65e0d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -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.ac,v 1.12 2005/08/22 21:24:08 hobbs2 Exp $
+# RCS: @(#) $Id: configure.ac,v 1.13 2005/12/02 22:35:36 hobbs2 Exp $
#-----------------------------------------------------------------------
# Sample configure.in for Tcl Extensions.
@@ -23,7 +23,7 @@ AC_INIT([treectrl], [2.1])
AC_SUBST([PACKAGE_PATCHLEVEL], [2.1])
AC_DEFINE_UNQUOTED(PACKAGE_PATCHLEVEL, "$PACKAGE_PATCHLEVEL")
-TEA_INIT([3.2])
+TEA_INIT([3.4])
AC_CONFIG_AUX_DIR(tclconfig)
diff --git a/tclconfig/tcl.m4 b/tclconfig/tcl.m4
index 66198f3..490b1d2 100644
--- a/tclconfig/tcl.m4
+++ b/tclconfig/tcl.m4
@@ -9,10 +9,16 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: tcl.m4,v 1.5 2005/08/22 21:24:08 hobbs2 Exp $
+# RCS: @(#) $Id: tcl.m4,v 1.6 2005/12/02 22:35:36 hobbs2 Exp $
AC_PREREQ(2.50)
+# Possible values for key variables defined:
+#
+# TEA_WINDOWINGSYSTEM - win32 aqua x11 (mirrors 'tk windowingsystem')
+# TEA_PLATFORM - windows unix
+#
+
#------------------------------------------------------------------------
# TEA_PATH_TCLCONFIG --
#
@@ -86,6 +92,20 @@ AC_DEFUN(TEA_PATH_TCLCONFIG, [
done
fi
+ # on Darwin, check in Framework installation locations
+ if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tclconfig}" = x ; then
+ for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
+ `ls -d /Library/Frameworks 2>/dev/null` \
+ `ls -d /Network/Library/Frameworks 2>/dev/null` \
+ `ls -d /System/Library/Frameworks 2>/dev/null` \
+ ; do
+ if test -f "$i/Tcl.framework/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd $i/Tcl.framework; pwd)`
+ break
+ fi
+ done
+ fi
+
# check in a few common install locations
if test x"${ac_cv_c_tclconfig}" = x ; then
for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
@@ -197,6 +217,21 @@ AC_DEFUN(TEA_PATH_TKCONFIG, [
fi
done
fi
+
+ # on Darwin, check in Framework installation locations
+ if test "`uname -s`" = "Darwin" -a x"${ac_cv_c_tkconfig}" = x ; then
+ for i in `ls -d ~/Library/Frameworks 2>/dev/null` \
+ `ls -d /Library/Frameworks 2>/dev/null` \
+ `ls -d /Network/Library/Frameworks 2>/dev/null` \
+ `ls -d /System/Library/Frameworks 2>/dev/null` \
+ ; do
+ if test -f "$i/Tk.framework/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd $i/Tk.framework; pwd)`
+ break
+ fi
+ done
+ fi
+
# check in a few common install locations
if test x"${ac_cv_c_tkconfig}" = x ; then
for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
@@ -225,6 +260,7 @@ AC_DEFUN(TEA_PATH_TKCONFIG, [
done
fi
])
+
if test x"${ac_cv_c_tkconfig}" = x ; then
TK_BIN_DIR="# no Tk configs found"
AC_MSG_WARN("Cannot find Tk configuration definitions")
@@ -235,7 +271,6 @@ AC_DEFUN(TEA_PATH_TKCONFIG, [
AC_MSG_RESULT([found $TK_BIN_DIR/tkConfig.sh])
fi
fi
-
])
#------------------------------------------------------------------------
@@ -368,7 +403,7 @@ AC_DEFUN(TEA_LOAD_TKCONFIG, [
;;
esac
elif test "${TEA_PLATFORM}" = "windows" ; then
- TEA_WINDOWINGSYSTEM="windows"
+ TEA_WINDOWINGSYSTEM="win32"
fi
#
@@ -447,12 +482,18 @@ AC_DEFUN(TEA_ENABLE_SHARED, [
#------------------------------------------------------------------------
# TEA_ENABLE_THREADS --
#
-# Specify if thread support should be enabled. If "yes" is
-# specified as an arg (optional), threads are enabled by default.
+# Specify if thread support should be enabled. If "yes" is specified
+# as an arg (optional), threads are enabled by default, "no" means
+# threads are disabled. "yes" is the default.
+#
# TCL_THREADS is checked so that if you are compiling an extension
# against a threaded core, your extension must be compiled threaded
# as well.
#
+# Note that it is legal to have a thread enabled extension run in a
+# threaded or non-threaded Tcl core, but a non-threaded extension may
+# only run in a non-threaded Tcl core.
+#
# Arguments:
# none
#
@@ -472,7 +513,14 @@ AC_DEFUN(TEA_ENABLE_SHARED, [
AC_DEFUN(TEA_ENABLE_THREADS, [
AC_ARG_ENABLE(threads, [ --enable-threads build with threads],
- [tcl_ok=$enableval], [tcl_ok=$1])
+ [tcl_ok=$enableval], [tcl_ok=yes])
+
+ if test "${enable_threads+set}" = set; then
+ enableval="$enable_threads"
+ tcl_ok=$enableval
+ else
+ tcl_ok=yes
+ fi
if test "$tcl_ok" = "yes" -o "${TCL_THREADS}" = 1; then
TCL_THREADS=1
@@ -521,14 +569,14 @@ AC_DEFUN(TEA_ENABLE_THREADS, [
fi
fi
- # Does the pthread-implementation provide
- # 'pthread_attr_setstacksize' ?
-
- ac_saved_libs=$LIBS
- LIBS="$LIBS $THREADS_LIBS"
- AC_CHECK_FUNCS(pthread_attr_setstacksize)
- LIBS=$ac_saved_libs
- AC_CHECK_FUNCS(readdir_r)
+dnl # Not needed in TEA
+dnl # Does the pthread-implementation provide
+dnl # 'pthread_attr_setstacksize' ?
+dnl
+dnl ac_saved_libs=$LIBS
+dnl LIBS="$LIBS $THREADS_LIBS"
+dnl AC_CHECK_FUNCS(pthread_attr_setstacksize)
+dnl LIBS=$ac_saved_libs
fi
else
TCL_THREADS=0
@@ -538,9 +586,9 @@ AC_DEFUN(TEA_ENABLE_THREADS, [
if test "${TCL_THREADS}" = "1"; then
AC_DEFINE(TCL_THREADS, 1, [Are we building with threads enabled?])
#LIBS="$LIBS $THREADS_LIBS"
- AC_MSG_RESULT([yes])
+ AC_MSG_RESULT([yes (default)])
else
- AC_MSG_RESULT([no (default)])
+ AC_MSG_RESULT([no])
fi
# TCL_THREADS sanity checking. See if our request for building with
# threads is the same as the way Tcl was built. If not, warn the user.
@@ -548,15 +596,16 @@ AC_DEFUN(TEA_ENABLE_THREADS, [
*THREADS=1*)
if test "${TCL_THREADS}" = "0"; then
AC_MSG_WARN([
- Building ${PACKAGE_NAME} without threads enabled, but building against a Tcl
- that IS thread-enabled.])
+ Building ${PACKAGE_NAME} without threads enabled, but building against Tcl
+ that IS thread-enabled. It is recommended to use --enable-threads.])
fi
;;
*)
if test "${TCL_THREADS}" = "1"; then
AC_MSG_WARN([
- --enable-threads requested, but attempting building against a Tcl
- that is NOT thread-enabled.])
+ --enable-threads requested, but building against a Tcl that is NOT
+ thread-enabled. This is an OK configuration that will also run in
+ a thread-enabled core.])
fi
;;
esac
@@ -660,22 +709,20 @@ AC_DEFUN(TEA_ENABLE_LANGINFO, [
HAVE_LANGINFO=0
if test "$langinfo_ok" = "yes"; then
- if test "$langinfo_ok" = "yes"; then
- AC_CHECK_HEADER(langinfo.h,[langinfo_ok=yes],[langinfo_ok=no])
- fi
+ AC_CHECK_HEADER(langinfo.h,[langinfo_ok=yes],[langinfo_ok=no])
fi
AC_MSG_CHECKING([whether to use nl_langinfo])
if test "$langinfo_ok" = "yes"; then
- AC_TRY_COMPILE([#include <langinfo.h>],
- [nl_langinfo(CODESET);],[langinfo_ok=yes],[langinfo_ok=no])
- if test "$langinfo_ok" = "no"; then
- langinfo_ok="no (could not compile with nl_langinfo)";
- fi
- if test "$langinfo_ok" = "yes"; then
+ AC_CACHE_VAL(tcl_cv_langinfo_h,
+ AC_TRY_COMPILE([#include <langinfo.h>], [nl_langinfo(CODESET);],
+ [tcl_cv_langinfo_h=yes],[tcl_cv_langinfo_h=no]))
+ AC_MSG_RESULT($tcl_cv_langinfo_h)
+ if test $tcl_cv_langinfo_h = yes; then
AC_DEFINE(HAVE_LANGINFO, 1, [Do we have nl_langinfo()?])
fi
+ else
+ AC_MSG_RESULT([$langinfo_ok])
fi
- AC_MSG_RESULT([$langinfo_ok])
])
#--------------------------------------------------------------------
@@ -859,22 +906,38 @@ dnl AC_CHECK_TOOL(AR, ar, :)
windows)
# This is a 2-stage check to make sure we have the 64-bit SDK
# We have to know where the SDK is installed.
- if test "$do64bit" = "yes" ; then
+ # This magic is based on MS Platform SDK for Win2003 SP1 - hobbs
+ # MACHINE is IX86 for LINK, but this is used by the manifest,
+ # which requires x86|amd64|ia64.
+ MACHINE="X86"
+ if test "$do64bit" != "no" ; then
if test "x${MSSDK}x" = "xx" ; then
- MSSDK="C:/Progra~1/Microsoft SDK"
+ MSSDK="C:/Progra~1/Microsoft Platform SDK"
fi
- # Ensure that this path has no spaces to work in autoconf
- TEA_PATH_NOSPACE(MSSDK, ${MSSDK})
- if test ! -d "${MSSDK}/bin/win64" ; then
- AC_MSG_WARN([could not find 64-bit SDK to enable 64bit mode])
+ MSSDK=`echo "$MSSDK" | sed -e 's!\\\!/!g'`
+ PATH64=""
+ case "$do64bit" in
+ amd64|x64|yes)
+ MACHINE="AMD64" ; # default to AMD64 64-bit build
+ PATH64="${MSSDK}/Bin/Win64/x86/AMD64"
+ ;;
+ ia64)
+ MACHINE="IA64"
+ PATH64="${MSSDK}/Bin/Win64"
+ ;;
+ esac
+ if test ! -d "${PATH64}" ; then
+ AC_MSG_WARN([Could not find 64-bit $MACHINE SDK to enable 64bit mode])
+ AC_MSG_WARN([Ensure latest Platform SDK is installed])
do64bit="no"
else
+ AC_MSG_RESULT([ Using 64-bit $MACHINE mode])
do64bit_ok="yes"
fi
fi
if test "$doWince" != "no" ; then
- if test "$do64bit" = "yes" ; then
+ if test "$do64bit" != "no" ; then
AC_MSG_ERROR([Windows/CE and 64-bit builds incompatible])
fi
if test "$GCC" = "yes" ; then
@@ -915,9 +978,8 @@ dnl AC_CHECK_TOOL(AR, ar, :)
SDKROOT="C:/Windows CE Tools"
fi
fi
- # Ensure that this path has no spaces to work in autoconf
- TEA_PATH_NOSPACE(WCEROOT, ${WCEROOT})
- TEA_PATH_NOSPACE(SDKROOT, ${SDKROOT})
+ WCEROOT=`echo "$WCEROOT" | sed -e 's!\\\!/!g'`
+ SDKROOT=`echo "$SDKROOT" | sed -e 's!\\\!/!g'`
if test ! -d "${SDKROOT}/${OSVERSION}/${PLATFORM}/Lib/${TARGETCPU}" \
-o ! -d "${WCEROOT}/EVC/${OSVERSION}/bin"; then
AC_MSG_ERROR([could not find PocketPC SDK or target compiler to enable WinCE mode [$CEVERSION,$TARGETCPU,$ARCH,$PLATFORM]])
@@ -940,27 +1002,27 @@ dnl AC_CHECK_TOOL(AR, ar, :)
runtime=-MD
fi
- if test "$do64bit" = "yes" ; then
+ if test "$do64bit" != "no" ; then
# All this magic is necessary for the Win64 SDK RC1 - hobbs
- CC="${MSSDK}/Bin/Win64/cl.exe"
- CFLAGS="${CFLAGS} -I${MSSDK}/Include/prerelease \
- -I${MSSDK}/Include/Win64/crt \
- -I${MSSDK}/Include"
- RC="${MSSDK}/bin/rc.exe"
- lflags="-MACHINE:IA64 -LIBPATH:${MSSDK}/Lib/IA64 \
- -LIBPATH:${MSSDK}/Lib/Prerelease/IA64 -nologo"
- LINKBIN="${MSSDK}/bin/win64/link.exe"
+ CC="\"${PATH64}/cl.exe\""
+ CFLAGS="${CFLAGS} -I\"${MSSDK}/Include\" -I\"${MSSDK}/Include/crt\" -I\"${MSSDK}/Include/crt/sys\""
+ RC="\"${MSSDK}/bin/rc.exe\""
+ lflags="-nologo -MACHINE:${MACHINE} -LIBPATH:\"${MSSDK}/Lib/${MACHINE}\""
+ LINKBIN="\"${PATH64}/link.exe\""
CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
CFLAGS_OPTIMIZE="-nologo -O2 -W2 ${runtime}"
+ # Avoid 'unresolved external symbol __security_cookie'
+ # errors, c.f. http://support.microsoft.com/?id=894573
+ TEA_ADD_LIBS([bufferoverflowU.lib])
elif test "$doWince" != "no" ; then
CEBINROOT="${WCEROOT}/EVC/${OSVERSION}/bin"
if test "${TARGETCPU}" = "X86"; then
- CC="${CEBINROOT}/cl.exe"
+ CC="\"${CEBINROOT}/cl.exe\""
else
- CC="${CEBINROOT}/cl${ARCH}.exe"
+ CC="\"${CEBINROOT}/cl${ARCH}.exe\""
fi
CFLAGS="$CFLAGS -I\"${CELIB_DIR}/inc\" -I\"${CEINCLUDE}\""
- RC="${WCEROOT}/Common/EVC/bin/rc.exe"
+ RC="\"${WCEROOT}/Common/EVC/bin/rc.exe\""
arch=`echo ${ARCH} | awk '{print tolower([$]0)}'`
defs="${ARCH} _${ARCH}_ ${arch} PALM_SIZE _MT _WINDOWS"
if test "${SHARED_BUILD}" = "1" ; then
@@ -976,7 +1038,7 @@ dnl AC_CHECK_TOOL(AR, ar, :)
CFLAGS_OPTIMIZE="-nologo -Ox"
lversion=`echo ${CEVERSION} | sed -e 's/\(.\)\(..\)/\1\.\2/'`
lflags="-MACHINE:${ARCH} -LIBPATH:\"${CELIBPATH}\" -subsystem:windowsce,${lversion} -nologo"
- LINKBIN="${CEBINROOT}/link.exe"
+ LINKBIN="\"${CEBINROOT}/link.exe\""
AC_SUBST(CELIB_DIR)
else
RC="rc"
@@ -1027,9 +1089,14 @@ dnl AC_CHECK_TOOL(AR, ar, :)
AIX-*)
if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
# AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
+ case "${CC}" in
+ *_r)
+ # ok ...
+ ;;
+ *)
+ CC=${CC}_r
+ ;;
+ esac
AC_MSG_RESULT([Using $CC for compiling with threads])
fi
LIBS="$LIBS -lc"
@@ -1436,7 +1503,11 @@ dnl AC_CHECK_TOOL(AR, ar, :)
Darwin-*)
CFLAGS_OPTIMIZE="-Os"
SHLIB_CFLAGS="-fno-common"
- SHLIB_LD="cc -dynamiclib \${LDFLAGS}"
+ if test $do64bit = yes; then
+ do64bit_ok=yes
+ CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5"
+ fi
+ SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS}'
AC_CACHE_CHECK([if ld accepts -single_module flag], tcl_cv_ld_single_module, [
hold_ldflags=$LDFLAGS
LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module"
@@ -1449,7 +1520,11 @@ dnl AC_CHECK_TOOL(AR, ar, :)
SHLIB_SUFFIX=".dylib"
DL_OBJS="tclLoadDyld.o"
DL_LIBS=""
- LDFLAGS="$LDFLAGS -prebind"
+ # Don't use -prebind when building for Mac OS X 10.4 or later only:
+ test -z "${MACOSX_DEPLOYMENT_TARGET}" || \
+ test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F. '{print [$]2}'`" -lt 4 && \
+ LDFLAGS="$LDFLAGS -prebind"
+ LDFLAGS="$LDFLAGS -headerpad_max_install_names"
AC_CACHE_CHECK([if ld accepts -search_paths_first flag], tcl_cv_ld_search_paths_first, [
hold_ldflags=$LDFLAGS
LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
@@ -1599,7 +1674,8 @@ dnl AC_CHECK_TOOL(AR, ar, :)
UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}.a'
TCL_LIB_VERSIONS_OK=nodots
;;
- SunOS-5.[[0-6]]*)
+ SunOS-5.[[0-6]])
+ # Careful to not let 5.10+ fall into this case
# Note: If _REENTRANT isn't defined, then Solaris
# won't define thread-safe library routines.
@@ -1658,9 +1734,19 @@ dnl AC_CHECK_TOOL(AR, ar, :)
CFLAGS="$CFLAGS -xarch=v9"
LDFLAGS="$LDFLAGS -xarch=v9"
fi
+ # Solaris 64 uses this as well
+ #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64"
fi
+ elif test "$arch" = "amd64 i386" ; then
+ if test "$GCC" = "yes" ; then
+ AC_MSG_WARN([64bit mode not supported with GCC on $system])
+ else
+ do64bit_ok=yes
+ CFLAGS="$CFLAGS -xarch=amd64"
+ LDFLAGS="$LDFLAGS -xarch=amd64"
+ fi
else
- AC_MSG_WARN("64bit mode only supported sparcv9 system")
+ AC_MSG_WARN([64bit mode not supported for $arch])
fi
fi
@@ -1722,8 +1808,8 @@ dnl AC_CHECK_TOOL(AR, ar, :)
;;
esac
- if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
- AC_MSG_WARN("64bit support being disabled -- don\'t know magic for this platform")
+ if test "$do64bit" != "no" -a "$do64bit_ok" = "no" ; then
+ AC_MSG_WARN([64bit support being disabled -- don't know magic for this platform])
fi
# Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
@@ -2127,7 +2213,7 @@ closedir(d);
#--------------------------------------------------------------------
AC_DEFUN(TEA_PATH_X, [
- if test "${TEA_PLATFORM}" = "unix" ; then
+ if test "${TEA_WINDOWINGSYSTEM}" = "x11" ; then
TEA_PATH_UNIX_X
fi
])
@@ -2317,7 +2403,7 @@ AC_DEFUN(TEA_TIME_HANDLER, [
# (like convex) have timezone functions, etc.
#
AC_MSG_CHECKING([long timezone variable])
- AC_CACHE_VAL(tcl_cv_var_timezone,
+ AC_CACHE_VAL(tcl_cv_timezone_long,
AC_TRY_COMPILE([#include <time.h>],
[extern long timezone;
timezone += 1;
@@ -2643,7 +2729,7 @@ AC_DEFUN(TEA_TCL_64BIT_FLAGS, [
AC_DEFUN(TEA_INIT, [
# TEA extensions pass this us the version of TEA they think they
# are compatible with.
- TEA_VERSION="3.2"
+ TEA_VERSION="3.4"
AC_MSG_CHECKING([for correct TEA configuration])
if test x"${PACKAGE_NAME}" = x ; then
@@ -3247,9 +3333,20 @@ AC_DEFUN(TEA_PRIVATE_TCL_HEADERS, [
else
TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
fi
- # We want to ensure these are substitured so as not to require
+ # We want to ensure these are substituted so as not to require
# any *_NATIVE vars be defined in the Makefile
TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
+ if test "`uname -s`" = "Darwin"; then
+ # If Tcl was built as a framework, attempt to use
+ # the framework's Headers and PrivateHeaders directories
+ case ${TCL_DEFS} in
+ *TCL_FRAMEWORK*)
+ if test -d "${TCL_BIN_DIR}/Headers" -a -d "${TCL_BIN_DIR}/PrivateHeaders"; then
+ TCL_INCLUDES="-I\"${TCL_BIN_DIR}/Headers\" -I\"${TCL_BIN_DIR}/PrivateHeaders\" ${TCL_INCLUDES}"; else
+ TCL_INCLUDES="${TCL_INCLUDES} ${TCL_INCLUDE_SPEC} `echo "${TCL_INCLUDE_SPEC}" | sed -e 's/Headers/PrivateHeaders/'`"; fi
+ ;;
+ esac
+ fi
AC_SUBST(TCL_TOP_DIR_NATIVE)
AC_SUBST(TCL_GENERIC_DIR_NATIVE)
@@ -3298,17 +3395,32 @@ AC_DEFUN(TEA_PUBLIC_TCL_HEADERS, [
AC_MSG_ERROR([${with_tclinclude} directory does not contain tcl.h])
fi
else
+ # If Tcl was built as a framework, attempt to use
+ # the framework's Headers directory
+ case ${TCL_DEFS} in
+ *TCL_FRAMEWORK*)
+ list="`ls -d ${TCL_BIN_DIR}/Headers 2>/dev/null`"
+ ;;
+ *)
+ list=""
+ ;;
+ esac
# Check order: pkg --prefix location, Tcl's --prefix location,
# directory of tclConfig.sh, and Tcl source directory.
# Looking in the source dir is not ideal, but OK.
eval "temp_includedir=${includedir}"
- list="`ls -d ${temp_includedir} 2>/dev/null` \
+ list="$list \
+ `ls -d ${temp_includedir} 2>/dev/null` \
`ls -d ${TCL_PREFIX}/include 2>/dev/null` \
`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
`ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
list="$list /usr/local/include /usr/include"
+ if test x"${TCL_INCLUDE_SPEC}" != x ; then
+ d=`echo "${TCL_INCLUDE_SPEC}" | sed -e 's/^-I//'`
+ list="$list `ls -d ${d} 2>/dev/null`"
+ fi
fi
for i in $list ; do
if test -f "$i/tcl.h" ; then
@@ -3367,16 +3479,26 @@ AC_DEFUN(TEA_PRIVATE_TK_HEADERS, [
else
TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
fi
- # We want to ensure these are substitured so as not to require
+ # We want to ensure these are substituted so as not to require
# any *_NATIVE vars be defined in the Makefile
TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
- if test "${TEA_WINDOWINGSYSTEM}" = "windows" \
+ if test "${TEA_WINDOWINGSYSTEM}" = "win32" \
-o "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
TK_INCLUDES="${TK_INCLUDES} -I${TK_XLIB_DIR_NATIVE}"
fi
if test "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
TK_INCLUDES="${TK_INCLUDES} -I${TK_SRC_DIR_NATIVE}/macosx"
fi
+ if test "`uname -s`" = "Darwin"; then
+ # If Tk was built as a framework, attempt to use
+ # the framework's Headers and PrivateHeaders directories
+ case ${TK_DEFS} in
+ *TK_FRAMEWORK*)
+ if test -d "${TK_BIN_DIR}/Headers" -a -d "${TK_BIN_DIR}/PrivateHeaders"; then
+ TK_INCLUDES="-I\"${TK_BIN_DIR}/Headers\" -I\"${TK_BIN_DIR}/PrivateHeaders\" ${TK_INCLUDES}"; fi
+ ;;
+ esac
+ fi
AC_SUBST(TK_TOP_DIR_NATIVE)
AC_SUBST(TK_UNIX_DIR_NATIVE)
@@ -3424,12 +3546,23 @@ AC_DEFUN(TEA_PUBLIC_TK_HEADERS, [
AC_MSG_ERROR([${with_tkinclude} directory does not contain tk.h])
fi
else
+ # If Tk was built as a framework, attempt to use
+ # the framework's Headers directory.
+ case ${TK_DEFS} in
+ *TK_FRAMEWORK*)
+ list="`ls -d ${TK_BIN_DIR}/Headers 2>/dev/null`"
+ ;;
+ *)
+ list=""
+ ;;
+ esac
# Check order: pkg --prefix location, Tcl's --prefix location,
# directory of tclConfig.sh, and Tcl source directory.
# Looking in the source dir is not ideal, but OK.
eval "temp_includedir=${includedir}"
- list="`ls -d ${temp_includedir} 2>/dev/null` \
+ list="$list \
+ `ls -d ${temp_includedir} 2>/dev/null` \
`ls -d ${TK_PREFIX}/include 2>/dev/null` \
`ls -d ${TCL_PREFIX}/include 2>/dev/null` \
`ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
@@ -3462,9 +3595,9 @@ AC_DEFUN(TEA_PUBLIC_TK_HEADERS, [
AC_SUBST(TK_INCLUDES)
- if test "${TEA_WINDOWINGSYSTEM}" = "windows" \
+ if test "${TEA_WINDOWINGSYSTEM}" = "win32" \
-o "${TEA_WINDOWINGSYSTEM}" = "aqua"; then
- # On Windows, we need the X compat headers
+ # On Windows and Aqua, we need the X compat headers
AC_MSG_CHECKING([for X11 header files])
if test ! -r "${INCLUDE_DIR_NATIVE}/X11/Xlib.h"; then
INCLUDE_DIR_NATIVE="`${CYGPATH} ${TK_SRC_DIR}/xlib`"
@@ -3477,10 +3610,14 @@ AC_DEFUN(TEA_PUBLIC_TK_HEADERS, [
#------------------------------------------------------------------------
# TEA_PROG_TCLSH
-# Locate a tclsh shell in the following directories:
-# ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin
-# ${exec_prefix}/bin ${prefix}/bin
-# ${PATH}
+# Determine the fully qualified path name of the tclsh executable
+# in the Tcl build directory or the tclsh installed in a bin
+# directory. This macro will correctly determine the name
+# of the tclsh executable even if tclsh has not yet been
+# built in the build directory. The tclsh found is always
+# associated with a tclConfig.sh file. This tclsh should be used
+# only for running extension test cases. It should never be
+# or generation of files (like pkgIndex.tcl) at build time.
#
# Arguments
# none
@@ -3491,48 +3628,45 @@ AC_DEFUN(TEA_PUBLIC_TK_HEADERS, [
#------------------------------------------------------------------------
AC_DEFUN(TEA_PROG_TCLSH, [
- # Allow the user to provide this setting in the env
- if test "x${TCLSH_PROG}" = "x" ; then
- AC_MSG_CHECKING([for tclsh])
-
- AC_CACHE_VAL(ac_cv_path_tclsh, [
- search_path=`echo ${PATH} | sed -e 's/:/ /g'`
- if test "${TEA_PLATFORM}" != "windows" -o \
- \( "$do64bit_ok" = "no" -a "$doWince" = "no" \) ; then
- # Do not allow target tclsh in known cross-compile builds,
- # as we need one we can run on this system
- search_path="${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin ${exec_prefix}/bin ${prefix}/bin ${search_path}"
- fi
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- AC_MSG_RESULT([$TCLSH_PROG])
- else
- AC_MSG_ERROR([No tclsh found in PATH: $search_path])
- fi
- fi
+ AC_MSG_CHECKING([for tclsh])
+ if test -f "${TCL_BIN_DIR}/Makefile" ; then
+ # tclConfig.sh is in Tcl build directory
+ if test "${TEA_PLATFORM}" = "windows"; then
+ TCLSH_PROG="${TCL_BIN_DIR}/tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
+ else
+ TCLSH_PROG="${TCL_BIN_DIR}/tclsh"
+ fi
+ else
+ # tclConfig.sh is in install location
+ if test "${TEA_PLATFORM}" = "windows"; then
+ TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}${TCL_MINOR_VERSION}${TCL_DBGX}${EXEEXT}"
+ else
+ TCLSH_PROG="tclsh${TCL_MAJOR_VERSION}.${TCL_MINOR_VERSION}${TCL_DBGX}"
+ fi
+ list="`ls -d ${TCL_PREFIX}/bin 2>/dev/null` \
+ `ls -d ${TCL_BIN_DIR}/../bin 2>/dev/null`"
+ for i in $list ; do
+ if test -f "$i/${TCLSH_PROG}" ; then
+ REAL_TCL_BIN_DIR="`cd "$i"; pwd`"
+ break
+ fi
+ done
+ TCLSH_PROG="${REAL_TCL_BIN_DIR}/${TCLSH_PROG}"
+ fi
+ AC_MSG_RESULT(${TCLSH_PROG})
AC_SUBST(TCLSH_PROG)
])
#------------------------------------------------------------------------
# TEA_PROG_WISH
-# Locate a wish shell in the following directories:
-# ${TK_BIN_DIR} ${TK_BIN_DIR}/../bin
-# ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin
-# ${exec_prefix}/bin ${prefix}/bin
-# ${PATH}
+# Determine the fully qualified path name of the wish executable
+# in the Tk build directory or the wish installed in a bin
+# directory. This macro will correctly determine the name
+# of the wish executable even if wish has not yet been
+# built in the build directory. The wish found is always
+# associated with a tkConfig.sh file. This wish should be used
+# only for running extension test cases. It should never be
+# or generation of files (like pkgIndex.tcl) at build time.
#
# Arguments
# none
@@ -3543,38 +3677,32 @@ AC_DEFUN(TEA_PROG_TCLSH, [
#------------------------------------------------------------------------
AC_DEFUN(TEA_PROG_WISH, [
- # Allow the user to provide this setting in the env
- if test "x${WISH_PROG}" = "x" ; then
- AC_MSG_CHECKING([for wish])
-
- AC_CACHE_VAL(ac_cv_path_wish, [
- search_path=`echo ${PATH} | sed -e 's/:/ /g'`
- if test "${TEA_PLATFORM}" != "windows" -o \
- \( "$do64bit_ok" = "no" -a "$doWince" = "no" \) ; then
- # Do not allow target wish in known cross-compile builds,
- # as we need one we can run on this system
- search_path="${TK_BIN_DIR} ${TK_BIN_DIR}/../bin ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin ${exec_prefix}/bin ${prefix}/bin ${search_path}"
- fi
- for dir in $search_path ; do
- for j in `ls -r $dir/wish[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/wish*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_wish" = x ; then
- if test -f "$j" ; then
- ac_cv_path_wish=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_wish" ; then
- WISH_PROG=$ac_cv_path_wish
- AC_MSG_RESULT([$WISH_PROG])
- else
- AC_MSG_ERROR([No wish found in PATH: $search_path])
- fi
- fi
+ AC_MSG_CHECKING([for wish])
+ if test -f "${TK_BIN_DIR}/Makefile" ; then
+ # tkConfig.sh is in Tk build directory
+ if test "${TEA_PLATFORM}" = "windows"; then
+ WISH_PROG="${TK_BIN_DIR}/wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
+ else
+ WISH_PROG="${TK_BIN_DIR}/wish"
+ fi
+ else
+ # tkConfig.sh is in install location
+ if test "${TEA_PLATFORM}" = "windows"; then
+ WISH_PROG="wish${TK_MAJOR_VERSION}${TK_MINOR_VERSION}${TK_DBGX}${EXEEXT}"
+ else
+ WISH_PROG="wish${TK_MAJOR_VERSION}.${TK_MINOR_VERSION}${TK_DBGX}"
+ fi
+ list="`ls -d ${TK_PREFIX}/bin 2>/dev/null` \
+ `ls -d ${TK_BIN_DIR}/../bin 2>/dev/null`"
+ for i in $list ; do
+ if test -f "$i/${WISH_PROG}" ; then
+ REAL_TK_BIN_DIR="`cd "$i"; pwd`"
+ break
+ fi
+ done
+ WISH_PROG="${REAL_TK_BIN_DIR}/${WISH_PROG}"
+ fi
+ AC_MSG_RESULT(${WISH_PROG})
AC_SUBST(WISH_PROG)
])
@@ -3809,45 +3937,8 @@ AC_DEFUN(TEA_PATH_CELIB, [
else
no_celib=
CELIB_DIR=${ac_cv_c_celibconfig}
+ CELIB_DIR=`echo "$CELIB_DIR" | sed -e 's!\\\!/!g'`
AC_MSG_RESULT([found $CELIB_DIR])
- TEA_PATH_NOSPACE(CELIB_DIR, ${ac_cv_c_celibconfig})
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_NOSPACE
-# Ensure that the given path has no spaces. This is necessary for
-# CC (and consitutuent vars that build it up) to work in the
-# tortured autoconf environment. Currently only for Windows use.
-#
-# Arguments
-# VAR - name of the variable to set
-# PATH - path to ensure no spaces in
-#
-# Results
-# Sets $VAR to short path of $PATH if it can be found.
-#------------------------------------------------------------------------
-
-AC_DEFUN([TEA_PATH_NOSPACE], [
- if test "${TEA_PLATFORM}" = "windows" ; then
- # we need TCLSH_PROG defined to get Windows short pathnames
- AC_REQUIRE([TEA_PROG_TCLSH])
-
- AC_MSG_CHECKING([short pathname for $1 ($2)])
-
- shortpath=
- case "$2" in
- *\ *)
- # Only do this if we need to.
- shortpath=`echo "puts [[file attributes {$2} -shortname]] ; exit" | ${TCLSH_PROG} 2>/dev/null`
- ;;
- esac
- if test "x${shortpath}" = "x" ; then
- AC_MSG_RESULT([not changed])
- else
- $1=$shortpath
- AC_MSG_RESULT([${$1}])
fi
fi
])