diff options
Diffstat (limited to 'win/configure')
-rwxr-xr-x | win/configure | 75 |
1 files changed, 73 insertions, 2 deletions
diff --git a/win/configure b/win/configure index 2597646..2a31e26 100755 --- a/win/configure +++ b/win/configure @@ -844,6 +844,11 @@ Optional Features: --enable-64bit enable 64bit support (where applicable) --enable-symbols build with debugging symbols --disable-symbols +Optional Packages: + --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] + --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-encoding encoding for configuration values + Some influential environment variables: CC C compiler command CFLAGS C compiler flags @@ -2076,12 +2081,12 @@ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (exit $ac_status); }; }; then for ac_declaration in \ ''\ - '#include <stdlib.h>' \ 'extern "C" void std::exit (int) throw (); using std::exit;' \ 'extern "C" void std::exit (int); using std::exit;' \ 'extern "C" void exit (int) throw ();' \ 'extern "C" void exit (int);' \ - 'void exit (int);' + 'void exit (int);' \ + '#include <stdlib.h>' do cat >conftest.$ac_ext <<_ACEOF #line $LINENO "configure" @@ -2908,6 +2913,32 @@ echo "${ECHO_T}no (default)" >&6 +#------------------------------------------------------------------------ +# Embedded configuration information, encoding to use for the values, TIP #59 +#------------------------------------------------------------------------ + + + +# Check whether --with-encoding or --without-encoding was given. +if test "${with_encoding+set}" = set; then + withval="$with_encoding" + with_tcencoding=${withval} +fi; + + if test x"${with_tcencoding}" != x ; then + cat >>confdefs.h <<_ACEOF +#define TCL_CFGVAL_ENCODING "${with_tcencoding}" +_ACEOF + + else + # Default encoding on windows is not "iso8859-1" + cat >>confdefs.h <<\_ACEOF +#define TCL_CFGVAL_ENCODING "cp1252" +_ACEOF + + fi + + #-------------------------------------------------------------------- # The statements below define a collection of symbols related to # building libtcl as a shared library instead of a static library. @@ -3236,6 +3267,25 @@ echo "$as_me: WARNING: \"could not find 64-bit SDK to enable 64bit mode\"" >&2;} CFLAGS_OPTIMIZE="-nologo -Oti -Gs -GD ${runtime}" STLIB_LD="lib -nologo" LINKBIN="link -link50compat" + + # TIP #59 + # A check borrowed from 'rules.vc' to determine if the + # compiler actually supports optimization. If not we do + # not try to use this feature. + + lines=`$(CC) -nologo -Ox -c -Zs -TC -Fdtemp nul 2>&1 | grep "D4002" | wc -l` + + for f in temp.idb temp.pdb ; do + if -f $f ; then + rm -f $f + fi + done + if $lines -gt 0 ; then + OPTIMIZING=1 + else + OPTIMIZING=0 + CFLAGS_OPTIMIZE="-nologo -Oti -Gs -GD ${runtime}" + fi fi SHLIB_LD="${LINKBIN} -dll -nologo -incremental:no" @@ -3266,6 +3316,13 @@ echo "$as_me: WARNING: \"could not find 64-bit SDK to enable 64bit mode\"" >&2;} LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}" fi + if test "$do64bit" = "yes" ; then + cat >>confdefs.h <<\_ACEOF +#define TCL_CFG_DO64BIT 1 +_ACEOF + + fi + # DL_LIBS is empty, but then we match the Unix version @@ -3296,6 +3353,16 @@ fi; DBGX="" echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 + + # Use result from SC_CONFIG_CFLAGS to determine if + # optimization is truly active. + + if $OPTIMIZING -eq 1 ; then + cat >>confdefs.h <<\_ACEOF +#define TCL_CFG_OPTIMIZED 1 +_ACEOF + + fi else CFLAGS_DEFAULT='$(CFLAGS_DEBUG)' LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)' @@ -3307,6 +3374,10 @@ echo "${ECHO_T}yes (standard debugging)" >&6 fi + cat >>confdefs.h <<\_ACEOF +#define TCL_CFG_DEBUG 1 +_ACEOF + if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then cat >>confdefs.h <<\_ACEOF |