summaryrefslogtreecommitdiffstats
path: root/unix/tcl.m4
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tcl.m4')
-rw-r--r--unix/tcl.m497
1 files changed, 59 insertions, 38 deletions
diff --git a/unix/tcl.m4 b/unix/tcl.m4
index 672ac32..d7ca5a2 100644
--- a/unix/tcl.m4
+++ b/unix/tcl.m4
@@ -265,7 +265,7 @@ AC_DEFUN([SC_PATH_TKCONFIG], [
# Load the tclConfig.sh file
#
# Arguments:
-#
+#
# Requires the following vars to be set:
# TCL_BIN_DIR
#
@@ -351,7 +351,7 @@ AC_DEFUN([SC_LOAD_TCLCONFIG], [
# Load the tkConfig.sh file
#
# Arguments:
-#
+#
# Requires the following vars to be set:
# TK_BIN_DIR
#
@@ -506,7 +506,7 @@ AC_DEFUN([SC_BUILD_TCLSH], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Adds the following arguments to configure:
@@ -551,7 +551,7 @@ AC_DEFUN([SC_ENABLE_SHARED], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Adds the following arguments to configure:
@@ -599,7 +599,7 @@ AC_DEFUN([SC_ENABLE_FRAMEWORK], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Adds the following arguments to configure:
@@ -742,13 +742,13 @@ AC_DEFUN([SC_ENABLE_THREADS], [
#
# Arguments:
# none
-#
+#
# Requires the following vars to be set in the Makefile:
# CFLAGS_DEBUG
# CFLAGS_OPTIMIZE
# LDFLAGS_DEBUG
# LDFLAGS_OPTIMIZE
-#
+#
# Results:
#
# Adds the following arguments to configure:
@@ -816,7 +816,7 @@ AC_DEFUN([SC_ENABLE_SYMBOLS], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Adds the following arguments to configure:
@@ -846,14 +846,14 @@ AC_DEFUN([SC_ENABLE_LANGINFO], [
if test $tcl_cv_langinfo_h = yes; then
AC_DEFINE(HAVE_LANGINFO, 1, [Do we have nl_langinfo()?])
fi
- else
+ else
AC_MSG_RESULT([$langinfo_ok])
fi
])
#--------------------------------------------------------------------
# SC_CONFIG_MANPAGES
-#
+#
# Decide whether to use symlinks for linking the manpages,
# whether to compress the manpages after installation, and
# whether to add a package name suffix to the installed
@@ -1027,7 +1027,7 @@ AC_DEFUN([SC_CONFIG_SYSTEM], [
# TCL_SHLIB_LD_EXTRAS - Additional element which are added to SHLIB_LD_LIBS
# TK_SHLIB_LD_EXTRAS for the build of Tcl and Tk, but not recorded in the
# tclConfig.sh, since they are only used for the build
-# of Tcl and Tk.
+# of Tcl and Tk.
# Examples: MacOS X records the library version and
# compatibility version in the shared library. But
# of course the Tcl version of this is only used for Tcl.
@@ -1280,6 +1280,16 @@ dnl AC_CHECK_TOOL(AR, ar)
CC_SEARCH_FLAGS=""
LD_SEARCH_FLAGS=""
;;
+ CYGWIN_*)
+ SHLIB_CFLAGS=""
+ SHLIB_LD='${CC} -shared'
+ SHLIB_LD_LIBS='${LIBS}'
+ SHLIB_SUFFIX=".dll"
+ DL_OBJS="tclLoadDl.o"
+ DL_LIBS="-ldl"
+ CC_SEARCH_FLAGS=""
+ LD_SEARCH_FLAGS=""
+ ;;
dgux*)
SHLIB_CFLAGS="-K PIC"
SHLIB_LD='${CC} -G'
@@ -1290,6 +1300,16 @@ dnl AC_CHECK_TOOL(AR, ar)
CC_SEARCH_FLAGS=""
LD_SEARCH_FLAGS=""
;;
+ Haiku*)
+ LDFLAGS="$LDFLAGS -Wl,--export-dynamic"
+ SHLIB_CFLAGS="-fPIC"
+ SHLIB_LD_LIBS='${LIBS}'
+ SHLIB_SUFFIX=".so"
+ SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS}'
+ DL_OBJS="tclLoadDl.o"
+ DL_LIBS="-lroot"
+ AC_CHECK_LIB(network, inet_ntoa, [LIBS="$LIBS -lnetwork"])
+ ;;
HP-UX-*.11.*)
# Use updated header definitions where possible
AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [Do we want to use the XOPEN network library?])
@@ -1426,7 +1446,7 @@ dnl AC_CHECK_TOOL(AR, ar)
SHLIB_SUFFIX=".so"
CFLAGS_OPTIMIZE="-O2"
- # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
+ # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
# when you inline the string and math operations. Turn this off to
# get rid of the warnings.
#CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
@@ -1715,8 +1735,8 @@ dnl AC_CHECK_TOOL(AR, ar)
eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"'
done])
LIBS="$LIBS -framework CoreFoundation"
- AC_TRY_LINK([#include <CoreFoundation/CoreFoundation.h>],
- [CFBundleRef b = CFBundleGetMainBundle();],
+ AC_TRY_LINK([#include <CoreFoundation/CoreFoundation.h>],
+ [CFBundleRef b = CFBundleGetMainBundle();],
tcl_cv_lib_corefoundation=yes,
tcl_cv_lib_corefoundation=no)
AS_IF([test "$fat_32_64" = yes], [
@@ -1726,7 +1746,7 @@ dnl AC_CHECK_TOOL(AR, ar)
LIBS=$hold_libs])
AS_IF([test $tcl_cv_lib_corefoundation = yes], [
LIBS="$LIBS -framework CoreFoundation"
- AC_DEFINE(HAVE_COREFOUNDATION, 1,
+ AC_DEFINE(HAVE_COREFOUNDATION, 1,
[Do we have access to Darwin CoreFoundation.framework?])
], [tcl_corefoundation=no])
AS_IF([test "$fat_32_64" = yes -a $tcl_corefoundation = yes],[
@@ -1735,8 +1755,8 @@ dnl AC_CHECK_TOOL(AR, ar)
for v in CFLAGS CPPFLAGS LDFLAGS; do
eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"'
done
- AC_TRY_LINK([#include <CoreFoundation/CoreFoundation.h>],
- [CFBundleRef b = CFBundleGetMainBundle();],
+ AC_TRY_LINK([#include <CoreFoundation/CoreFoundation.h>],
+ [CFBundleRef b = CFBundleGetMainBundle();],
tcl_cv_lib_corefoundation_64=yes,
tcl_cv_lib_corefoundation_64=no)
for v in CFLAGS CPPFLAGS LDFLAGS; do
@@ -1764,7 +1784,7 @@ dnl AC_CHECK_TOOL(AR, ar)
CFLAGS_OPTIMIZE="" # Optimizer is buggy
AC_DEFINE(_OE_SOCKETS, 1, # needed in sys/socket.h
[Should OS/390 do the right thing with sockets?])
- ;;
+ ;;
OSF1-1.0|OSF1-1.1|OSF1-1.2)
# OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
SHLIB_CFLAGS=""
@@ -2089,6 +2109,7 @@ dnl # preprocessing tests use only CPPFLAGS.
case $system in
AIX-*) ;;
BSD/OS*) ;;
+ CYGWIN_*) ;;
IRIX*) ;;
NetBSD-*|FreeBSD-*) ;;
Darwin-*) ;;
@@ -2181,7 +2202,7 @@ dnl # preprocessing tests use only CPPFLAGS.
#
# Arguments:
# none
-#
+#
# Results:
#
# Defines only one of the following vars:
@@ -2300,7 +2321,7 @@ int main() {
#
# Arguments:
# none
-#
+#
# Results:
#
# Defines some of the following vars:
@@ -2386,7 +2407,7 @@ closedir(d);
#
# Arguments:
# none
-#
+#
# Results:
#
# Sets the the following vars:
@@ -2464,13 +2485,13 @@ AC_DEFUN([SC_PATH_X], [
# SC_BLOCKING_STYLE
#
# The statements below check for systems where POSIX-style
-# non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented.
+# non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented.
# On these systems (mostly older ones), use the old BSD-style
# FIONBIO approach instead.
#
# Arguments:
# none
-#
+#
# Results:
#
# Defines some of the following vars:
@@ -2514,7 +2535,7 @@ AC_DEFUN([SC_BLOCKING_STYLE], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Defines some of the following vars:
@@ -2585,7 +2606,7 @@ AC_DEFUN([SC_TIME_HANDLER], [
#
# Arguments:
# none
-#
+#
# Results:
#
# Might defines some of the following vars:
@@ -2635,7 +2656,7 @@ AC_DEFUN([SC_BUGGY_STRTOD], [
#
# Arguments:
# None.
-#
+#
# Results:
#
# Might append to the following vars:
@@ -2708,7 +2729,7 @@ AC_DEFUN([SC_TCL_LINK_LIBS], [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -2754,7 +2775,7 @@ AC_DEFUN([SC_TCL_EARLY_FLAGS],[
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -2776,8 +2797,8 @@ AC_DEFUN([SC_TCL_64BIT_FLAGS], [
# See if we should use long anyway Note that we substitute in the
# type that is our current guess for a 64-bit type inside this check
# program, so it should be modified only carefully...
- AC_TRY_COMPILE(,[switch (0) {
- case 1: case (sizeof(]${tcl_type_64bit}[)==sizeof(long)): ;
+ AC_TRY_COMPILE(,[switch (0) {
+ case 1: case (sizeof(]${tcl_type_64bit}[)==sizeof(long)): ;
}],tcl_cv_type_64bit=${tcl_type_64bit})])
if test "${tcl_cv_type_64bit}" = none ; then
AC_DEFINE(TCL_WIDE_INT_IS_LONG, 1, [Are wide integers to be implemented with C 'long's?])
@@ -2896,7 +2917,7 @@ AC_DEFUN([SC_TCL_CHECK_BROKEN_FUNC],[
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -2963,7 +2984,7 @@ AC_DEFUN([SC_TCL_GETHOSTBYADDR_R], [AC_CHECK_FUNC(gethostbyaddr_r, [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -3035,11 +3056,11 @@ AC_DEFUN([SC_TCL_GETHOSTBYNAME_R], [AC_CHECK_FUNC(gethostbyname_r, [
#--------------------------------------------------------------------
# SC_TCL_GETADDRINFO
#
-# Check if we have 'getaddrinfo' for hostname lookup and inet6/ipv6
+# Check if we have 'getaddrinfo'
#
# Arguments:
# None
-#
+#
# Results:
# Might define the following vars:
# HAVE_GETADDRINFO
@@ -3071,7 +3092,7 @@ AC_DEFUN([SC_TCL_GETADDRINFO], [AC_CHECK_FUNC(getaddrinfo, [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -3131,7 +3152,7 @@ AC_DEFUN([SC_TCL_GETPWUID_R], [AC_CHECK_FUNC(getpwuid_r, [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -3191,7 +3212,7 @@ AC_DEFUN([SC_TCL_GETPWNAM_R], [AC_CHECK_FUNC(getpwnam_r, [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars:
@@ -3251,7 +3272,7 @@ AC_DEFUN([SC_TCL_GETGRGID_R], [AC_CHECK_FUNC(getgrgid_r, [
#
# Arguments:
# None
-#
+#
# Results:
#
# Might define the following vars: