diff -Nru tdbcsqlite3-1.1.3/configure tdbcsqlite3-1.1.5/configure --- tdbcsqlite3-1.1.3/configure 2021-11-01 00:46:02.000000000 +0000 +++ tdbcsqlite3-1.1.5/configure 2022-11-04 13:46:37.000000000 +0000 @@ -1,9 +1,10 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.70 for tdbcsqlite3 1.1.3. +# Generated by GNU Autoconf 2.71 for tdbcsqlite3 1.1.5. # # -# Copyright (C) 1992-1996, 1998-2017, 2020 Free Software Foundation, Inc. +# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, +# Inc. # # # This configure script is free software; the Free Software Foundation @@ -606,8 +607,8 @@ # Identity of this package. PACKAGE_NAME='tdbcsqlite3' PACKAGE_TARNAME='tdbcsqlite3' -PACKAGE_VERSION='1.1.3' -PACKAGE_STRING='tdbcsqlite3 1.1.3' +PACKAGE_VERSION='1.1.5' +PACKAGE_STRING='tdbcsqlite3 1.1.5' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -759,6 +760,7 @@ ac_user_opts=' enable_option_checking with_tcl +with_tcl8 with_tdbc enable_threads enable_64bit @@ -1322,7 +1324,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures tdbcsqlite3 1.1.3 to adapt to many kinds of systems. +\`configure' configures tdbcsqlite3 1.1.5 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1384,7 +1386,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of tdbcsqlite3 1.1.3:";; + short | recursive ) echo "Configuration of tdbcsqlite3 1.1.5:";; esac cat <<\_ACEOF @@ -1403,6 +1405,7 @@ --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-tcl directory containing tcl configuration (tclConfig.sh) + --with-tcl8 Compile for Tcl8 in Tcl9 environment --with-tdbc directory containing tdbc configuration (tdbcConfig.sh) Some influential environment variables: @@ -1481,10 +1484,10 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -tdbcsqlite3 configure 1.1.3 -generated by GNU Autoconf 2.70 +tdbcsqlite3 configure 1.1.5 +generated by GNU Autoconf 2.71 -Copyright (C) 2020 Free Software Foundation, Inc. +Copyright (C) 2021 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1699,8 +1702,8 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by tdbcsqlite3 $as_me 1.1.3, which was -generated by GNU Autoconf 2.70. Invocation command line was +It was created by tdbcsqlite3 $as_me 1.1.5, which was +generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -2559,6 +2562,13 @@ withval=$with_tcl; with_tclconfig="${withval}" fi + +# Check whether --with-tcl8 was given. +if test ${with_tcl8+y} +then : + withval=$with_tcl8; with_tcl8="${withval}" +fi + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Tcl configuration" >&5 printf %s "checking for Tcl configuration... " >&6; } if test ${ac_cv_c_tclconfig+y} @@ -3546,7 +3556,10 @@ CFLAGS= fi fi -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 +ac_prog_cc_stdc=no +if test x$ac_prog_cc_stdc = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 printf %s "checking for $CC option to enable C11 features... " >&6; } if test ${ac_cv_prog_cc_c11+y} then : @@ -3570,28 +3583,28 @@ done rm -f conftest.$ac_ext CC=$ac_save_CC - fi -# AC_CACHE_VAL -ac_prog_cc_stdc_options= -case "x$ac_cv_prog_cc_c11" in #( - x) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } ;; #( - xno) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } ;; #( - *) : - ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c11" - CC="$CC$ac_prog_cc_stdc_options" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 -printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c11" != xno + +if test "x$ac_cv_prog_cc_c11" = xno then : - ac_prog_cc_stdc=c11 - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } else $as_nop + if test "x$ac_cv_prog_cc_c11" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } +else $as_nop + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 +printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } + CC="$CC $ac_cv_prog_cc_c11" +fi + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 + ac_prog_cc_stdc=c11 +fi +fi +if test x$ac_prog_cc_stdc = xno +then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 printf %s "checking for $CC option to enable C99 features... " >&6; } if test ${ac_cv_prog_cc_c99+y} @@ -3602,9 +3615,9 @@ ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_c_conftest_c89_program +$ac_c_conftest_c99_program _ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc1x -qlanglvl=extc99 +for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" @@ -3616,28 +3629,28 @@ done rm -f conftest.$ac_ext CC=$ac_save_CC - fi -# AC_CACHE_VAL -ac_prog_cc_stdc_options= -case "x$ac_cv_prog_cc_c99" in #( - x) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } ;; #( - xno) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } ;; #( - *) : - ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c99" - CC="$CC$ac_prog_cc_stdc_options" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c99" != xno + +if test "x$ac_cv_prog_cc_c99" = xno then : - ac_prog_cc_stdc=c99 - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } +else $as_nop + if test "x$ac_cv_prog_cc_c99" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } else $as_nop + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 +printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } + CC="$CC $ac_cv_prog_cc_c99" +fi + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 + ac_prog_cc_stdc=c99 +fi +fi +if test x$ac_prog_cc_stdc = xno +then : { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 printf %s "checking for $CC option to enable C89 features... " >&6; } if test ${ac_cv_prog_cc_c89+y} @@ -3650,8 +3663,7 @@ /* end confdefs.h. */ $ac_c_conftest_c89_program _ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO" @@ -3663,34 +3675,25 @@ done rm -f conftest.$ac_ext CC=$ac_save_CC - fi -# AC_CACHE_VAL -ac_prog_cc_stdc_options= -case "x$ac_cv_prog_cc_c89" in #( - x) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -printf "%s\n" "none needed" >&6; } ;; #( - xno) : - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -printf "%s\n" "unsupported" >&6; } ;; #( - *) : - ac_prog_cc_stdc_options=" $ac_cv_prog_cc_c89" - CC="$CC$ac_prog_cc_stdc_options" - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } ;; -esac -if test "x$ac_cv_prog_cc_c89" != xno + +if test "x$ac_cv_prog_cc_c89" = xno then : - ac_prog_cc_stdc=c89 - ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } +else $as_nop + if test "x$ac_cv_prog_cc_c89" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } else $as_nop - ac_prog_cc_stdc=no - ac_cv_prog_cc_stdc=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } + CC="$CC $ac_cv_prog_cc_c89" fi - + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 + ac_prog_cc_stdc=c89 fi - fi ac_ext=c @@ -4999,6 +5002,9 @@ amd64|x64|yes) MACHINE="AMD64" ; # default to AMD64 64-bit build ;; + arm64|aarch64) + MACHINE="ARM64" + ;; ia64) MACHINE="IA64" ;; @@ -5211,6 +5217,13 @@ RANLIB="x86_64-w64-mingw32-ranlib" RC="x86_64-w64-mingw32-windres" ;; + arm64|aarch64) + CC="aarch64-w64-mingw32-clang" + LD="aarch64-w64-mingw32-ld" + AR="aarch64-w64-mingw32-ar" + RANLIB="aarch64-w64-mingw32-ranlib" + RC="aarch64-w64-mingw32-windres" + ;; *) CC="i686-w64-mingw32-${CC}" LD="i686-w64-mingw32-ld" @@ -7838,8 +7851,8 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by tdbcsqlite3 $as_me 1.1.3, which was -generated by GNU Autoconf 2.70. Invocation command line was +This file was extended by tdbcsqlite3 $as_me 1.1.5, which was +generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -7893,11 +7906,11 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -tdbcsqlite3 config.status 1.1.3 -configured by $0, generated by GNU Autoconf 2.70, +tdbcsqlite3 config.status 1.1.5 +configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" -Copyright (C) 2020 Free Software Foundation, Inc. +Copyright (C) 2021 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." diff -Nru tdbcsqlite3-1.1.3/configure.ac tdbcsqlite3-1.1.5/configure.ac --- tdbcsqlite3-1.1.3/configure.ac 2021-11-01 00:46:02.000000000 +0000 +++ tdbcsqlite3-1.1.5/configure.ac 2022-11-04 13:46:37.000000000 +0000 @@ -19,7 +19,7 @@ # so that we create the export library with the dll. #----------------------------------------------------------------------- -AC_INIT([tdbcsqlite3],[1.1.3]) +AC_INIT([tdbcsqlite3],[1.1.5]) #-------------------------------------------------------------------- # Call TEA_INIT as the first TEA_ macro to set up initial vars. diff -Nru tdbcsqlite3-1.1.3/debian/changelog tdbcsqlite3-1.1.5/debian/changelog --- tdbcsqlite3-1.1.3/debian/changelog 2022-01-07 11:53:53.000000000 +0000 +++ tdbcsqlite3-1.1.5/debian/changelog 2022-11-16 13:38:18.000000000 +0000 @@ -1,3 +1,10 @@ +tdbcsqlite3 (1.1.5-1) unstable; urgency=medium + + * New upstream release + * Update standards compliance to version 4.6.1 + + -- Massimo Manghi Wed, 16 Nov 2022 13:38:18 +0000 + tdbcsqlite3 (1.1.3-2) unstable; urgency=medium * Removed unused licence GPL-2+ from debian/copyright, diff -Nru tdbcsqlite3-1.1.3/debian/control tdbcsqlite3-1.1.5/debian/control --- tdbcsqlite3-1.1.3/debian/control 2022-01-07 11:53:53.000000000 +0000 +++ tdbcsqlite3-1.1.5/debian/control 2022-11-16 13:38:10.000000000 +0000 @@ -3,7 +3,7 @@ Priority: optional Maintainer: Massimo Manghi Build-Depends: debhelper-compat (=13), tcl8.6-dev, tcl8.6-tdbc (>=1.1.1~) -Standards-Version: 4.6.0 +Standards-Version: 4.6.1 Rules-Requires-Root: binary-targets Homepage: http://core.tcl.tk/tdbcsqlite3 diff -Nru tdbcsqlite3-1.1.3/library/tdbcsqlite3.tcl tdbcsqlite3-1.1.5/library/tdbcsqlite3.tcl --- tdbcsqlite3-1.1.3/library/tdbcsqlite3.tcl 2021-11-01 00:46:02.000000000 +0000 +++ tdbcsqlite3-1.1.5/library/tdbcsqlite3.tcl 2022-11-04 13:46:37.000000000 +0000 @@ -13,7 +13,7 @@ package require tdbc package require sqlite3 -package provide tdbc::sqlite3 1.1.3 +package provide tdbc::sqlite3 1.1.5 namespace eval tdbc::sqlite3 { namespace export connection diff -Nru tdbcsqlite3-1.1.3/README tdbcsqlite3-1.1.5/README --- tdbcsqlite3-1.1.3/README 2021-11-01 00:46:02.000000000 +0000 +++ tdbcsqlite3-1.1.5/README 2022-11-04 13:46:37.000000000 +0000 @@ -1,6 +1,6 @@ README: tdbcsqlite3 - This is the 1.1.3 source distribution of the bridge between Tcl + This is the 1.1.5 source distribution of the bridge between Tcl Database Connectivity (TDBC) and SQLite3, an open-source SQL database with an in-process server. diff -Nru tdbcsqlite3-1.1.3/tclconfig/tcl.m4 tdbcsqlite3-1.1.5/tclconfig/tcl.m4 --- tdbcsqlite3-1.1.3/tclconfig/tcl.m4 2021-11-01 00:32:04.000000000 +0000 +++ tdbcsqlite3-1.1.5/tclconfig/tcl.m4 2022-11-04 13:46:50.000000000 +0000 @@ -53,6 +53,10 @@ AS_HELP_STRING([--with-tcl], [directory containing tcl configuration (tclConfig.sh)]), [with_tclconfig="${withval}"]) + AC_ARG_WITH(tcl8, + AS_HELP_STRING([--with-tcl8], + [Compile for Tcl8 in Tcl9 environment]), + [with_tcl8="${withval}"]) AC_MSG_CHECKING([for Tcl configuration]) AC_CACHE_VAL(ac_cv_c_tclconfig,[ @@ -1167,6 +1171,9 @@ amd64|x64|yes) MACHINE="AMD64" ; # default to AMD64 64-bit build ;; + arm64|aarch64) + MACHINE="ARM64" + ;; ia64) MACHINE="IA64" ;; @@ -1236,6 +1243,13 @@ RANLIB="x86_64-w64-mingw32-ranlib" RC="x86_64-w64-mingw32-windres" ;; + arm64|aarch64) + CC="aarch64-w64-mingw32-clang" + LD="aarch64-w64-mingw32-ld" + AR="aarch64-w64-mingw32-ar" + RANLIB="aarch64-w64-mingw32-ranlib" + RC="aarch64-w64-mingw32-windres" + ;; *) CC="i686-w64-mingw32-${CC}" LD="i686-w64-mingw32-ld" @@ -2353,7 +2367,8 @@ # (like convex) have timezone functions, etc. # AC_CACHE_CHECK([long timezone variable], tcl_cv_timezone_long, [ - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include +#include ]], [[extern long timezone; timezone += 1; exit (0);]])], @@ -2365,7 +2380,8 @@ # On some systems (eg IRIX 6.2), timezone is a time_t and not a long. # AC_CACHE_CHECK([time_t timezone variable], tcl_cv_timezone_time, [ - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include ]], + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include +#include ]], [[extern time_t timezone; timezone += 1; exit (0);]])], @@ -3162,10 +3178,11 @@ PACKAGE_LIB_PREFIX8="${PACKAGE_LIB_PREFIX}" PACKAGE_LIB_PREFIX9="${PACKAGE_LIB_PREFIX}tcl9" - if test "${TCL_MAJOR_VERSION}" -gt 8 ; then + if test "${TCL_MAJOR_VERSION}" -gt 8 -a x"${with_tcl8}" == x; then PACKAGE_LIB_PREFIX="${PACKAGE_LIB_PREFIX9}" else PACKAGE_LIB_PREFIX="${PACKAGE_LIB_PREFIX8}" + AC_DEFINE(TCL_MAJOR_VERSION, 8, [Compile for Tcl8?]) fi if test "${TEA_PLATFORM}" = "windows" ; then if test "${SHARED_BUILD}" = "1" ; then diff -Nru tdbcsqlite3-1.1.3/win/rules.vc tdbcsqlite3-1.1.5/win/rules.vc --- tdbcsqlite3-1.1.3/win/rules.vc 2021-11-01 00:46:02.000000000 +0000 +++ tdbcsqlite3-1.1.5/win/rules.vc 2022-11-04 13:46:37.000000000 +0000 @@ -24,7 +24,7 @@ # For modifications that are not backward-compatible, you *must* change # the major version. RULES_VERSION_MAJOR = 1 -RULES_VERSION_MINOR = 9 +RULES_VERSION_MINOR = 11 # The PROJECT macro must be defined by parent makefile. !if "$(PROJECT)" == "" @@ -411,8 +411,8 @@ # compiler version 1200. This is kept only for legacy reasons as it # does not make sense for recent Microsoft compilers. Only used for # output directory names. -# ARCH - set to IX86 or AMD64 depending on 32- or 64-bit target -# NATIVE_ARCH - set to IX86 or AMD64 for the host machine +# ARCH - set to IX86, ARM64 or AMD64 depending on 32- or 64-bit target +# NATIVE_ARCH - set to IX86, ARM64 or AMD64 for the host machine # MACHINE - same as $(ARCH) - legacy # _VC_MANIFEST_EMBED_{DLL,EXE} - commands for embedding a manifest if needed @@ -435,6 +435,8 @@ && ![echo ARCH=IX86 >> vercl.x] \ && ![echo $(_HASH)elif defined(_M_AMD64) >> vercl.x] \ && ![echo ARCH=AMD64 >> vercl.x] \ + && ![echo $(_HASH)elif defined(_M_ARM64) >> vercl.x] \ + && ![echo ARCH=ARM64 >> vercl.x] \ && ![echo $(_HASH)endif >> vercl.x] \ && ![$(cc32) -nologo -TC -P vercl.x 2>NUL] !include vercl.i @@ -459,6 +461,9 @@ !if "$(MACHINE)" == "x86" !undef MACHINE MACHINE = IX86 +!elseif "$(MACHINE)" == "arm64" +!undef MACHINE +MACHINE = ARM64 !elseif "$(MACHINE)" == "x64" !undef MACHINE MACHINE = AMD64 @@ -475,6 +480,8 @@ # the Tcl platform::identify command !if "$(MACHINE)" == "AMD64" PLATFORM_IDENTIFY = win32-x86_64 +!elseif "$(MACHINE)" == "ARM64" +PLATFORM_IDENTIFY = win32-arm !else PLATFORM_IDENTIFY = win32-ix86 !endif @@ -490,6 +497,8 @@ !if ![reg query HKLM\Hardware\Description\System\CentralProcessor\0 /v Identifier | findstr /i x86] NATIVE_ARCH=IX86 +!elseif ![reg query HKLM\Hardware\Description\System\CentralProcessor\0 /v Identifier | findstr /i ARM | findstr /i 64-bit] +NATIVE_ARCH=ARM64 !else NATIVE_ARCH=AMD64 !endif @@ -541,8 +550,13 @@ # We always build nmakehlp even if it exists since we do not know # what source it was built from. +!if "$(MACHINE)" == "IX86" || "$(MACHINE)" == "$(NATIVE_ARCH)" !if [$(cc32) -nologo "$(NMAKEHLPC)" -link -subsystem:console > nul] !endif +!else +!if [copy $(NMAKEHLPC:nmakehlp.c=x86_64-w64-mingw32-nmakehlp.exe) nmakehlp.exe >NUL] +!endif +!endif ################################################################ # 5. Test for compiler features @@ -679,7 +693,7 @@ !if [echo REM = This file is generated from rules.vc > versions.vc] !endif !if [echo TCL_MAJOR_VERSION = \>> versions.vc] \ - && [nmakehlp -V "$(_TCL_H)" TCL_MAJOR_VERSION >> versions.vc] + && [nmakehlp -V "$(_TCL_H)" "define TCL_MAJOR_VERSION" >> versions.vc] !endif !if [echo TCL_MINOR_VERSION = \>> versions.vc] \ && [nmakehlp -V "$(_TCL_H)" TCL_MINOR_VERSION >> versions.vc] @@ -693,7 +707,7 @@ !if defined(_TK_H) !if [echo TK_MAJOR_VERSION = \>> versions.vc] \ - && [nmakehlp -V $(_TK_H) TK_MAJOR_VERSION >> versions.vc] + && [nmakehlp -V $(_TK_H) "define TK_MAJOR_VERSION" >> versions.vc] !endif !if [echo TK_MINOR_VERSION = \>> versions.vc] \ && [nmakehlp -V $(_TK_H) TK_MINOR_VERSION >> versions.vc] @@ -802,8 +816,7 @@ # configuration (ignored for Tcl itself) # _USE_64BIT_TIME_T - forces a build using 64-bit time_t for 32-bit build # (CRT library should support this, not needed for Tcl 9.x) -# TCL_UTF_MAX=4 - forces a build allowing 4-byte UTF-8 sequences internally. -# (Not needed for Tcl 9.x) +# TCL_UTF_MAX=3 - forces a build using UTF-16 internally (not recommended). # Further, LINKERFLAGS are modified based on above. # Default values for all the above @@ -864,15 +877,20 @@ USE_THREAD_ALLOC= 0 !endif +!if [nmakehlp -f $(OPTS) "tcl8"] +!message *** Build for Tcl8 +TCL_BUILD_FOR = 8 +!endif + !if $(TCL_MAJOR_VERSION) == 8 !if [nmakehlp -f $(OPTS) "time64bit"] !message *** Force 64-bit time_t _USE_64BIT_TIME_T = 1 !endif -!if [nmakehlp -f $(OPTS) "utfmax"] -!message *** Force allowing 4-byte UTF-8 sequences internally -TCL_UTF_MAX = 4 +!if [nmakehlp -f $(OPTS) "utf16"] +!message *** Force UTF-16 internally +TCL_UTF_MAX = 3 !endif !endif @@ -1133,7 +1151,11 @@ TCLLIB = $(OUT_DIR)\$(TCLLIBNAME) TCLSCRIPTZIP = $(OUT_DIR)\$(TCLSCRIPTZIPNAME) +!if $(TCL_MAJOR_VERSION) == 8 TCLSTUBLIBNAME = $(STUBPREFIX)$(VERSION).lib +!else +TCLSTUBLIBNAME = $(STUBPREFIX).lib +!endif TCLSTUBLIB = $(OUT_DIR)\$(TCLSTUBLIBNAME) TCL_INCLUDES = -I"$(WIN_DIR)" -I"$(GENERICDIR)" @@ -1149,7 +1171,11 @@ TCLSH = $(_TCLDIR)\bin\tclsh$(TCL_VERSION)t$(SUFX:t=).exe !endif +!if $(TCL_MAJOR_VERSION) == 8 TCLSTUBLIB = $(_TCLDIR)\lib\tclstub$(TCL_VERSION).lib +!else +TCLSTUBLIB = $(_TCLDIR)\lib\tclstub.lib +!endif TCLIMPLIB = $(_TCLDIR)\lib\tcl$(TCL_VERSION)$(SUFX:t=).lib # When building extensions, may be linking against Tcl that does not add # "t" suffix (e.g. 8.5 or 8.7). If lib not found check for that possibility. @@ -1169,7 +1195,11 @@ !if !exist($(TCLSH)) TCLSH = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)t$(SUFX:t=).exe !endif +!if $(TCL_MAJOR_VERSION) == 8 TCLSTUBLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub$(TCL_VERSION).lib +!else +TCLSTUBLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub.lib +!endif TCLIMPLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX:t=).lib # When building extensions, may be linking against Tcl that does not add # "t" suffix (e.g. 8.5 or 8.7). If lib not found check for that possibility. @@ -1185,7 +1215,11 @@ !endif # TCLINSTALL +!if !$(STATIC_BUILD) && "$(TCL_BUILD_FOR)" == "8" +tcllibs = "$(TCLSTUBLIB)" +!else tcllibs = "$(TCLSTUBLIB)" "$(TCLIMPLIB)" +!endif !endif # $(DOING_TCL) @@ -1205,7 +1239,7 @@ WISHNAME = $(WISHNAMEPREFIX)$(TK_VERSION)$(SUFX).exe TKLIBNAME8 = tk$(TK_VERSION)$(SUFX).$(EXT) TKLIBNAME9 = tcl9tk$(TK_VERSION)$(SUFX).$(EXT) -!if $(TCL_MAJOR_VERSION) == 8 +!if $(TCL_MAJOR_VERSION) == 8 || "$(TCL_BUILD_FOR)" == "8" TKLIBNAME = tk$(TK_VERSION)$(SUFX).$(EXT) TKIMPLIBNAME = tk$(TK_VERSION)$(SUFX).lib !else @@ -1262,14 +1296,18 @@ PRJIMPLIB = $(OUT_DIR)\$(PROJECT)$(VERSION)$(SUFX).lib PRJLIBNAME8 = $(PROJECT)$(VERSION)$(SUFX).$(EXT) PRJLIBNAME9 = tcl9$(PROJECT)$(VERSION)$(SUFX).$(EXT) -!if $(TCL_MAJOR_VERSION) == 8 +!if $(TCL_MAJOR_VERSION) == 8 || "$(TCL_BUILD_FOR)" == "8" PRJLIBNAME = $(PRJLIBNAME8) !else PRJLIBNAME = $(PRJLIBNAME9) !endif PRJLIB = $(OUT_DIR)\$(PRJLIBNAME) +!if $(TCL_MAJOR_VERSION) == 8 PRJSTUBLIBNAME = $(STUBPREFIX)$(VERSION).lib +!else +PRJSTUBLIBNAME = $(STUBPREFIX).lib +!endif PRJSTUBLIB = $(OUT_DIR)\$(PRJSTUBLIBNAME) # If extension parent makefile has not defined a resource definition file, @@ -1344,7 +1382,7 @@ # baselibs - minimum Windows libraries required. Parent makefile can # define PRJ_LIBS before including rules.rc if additional libs are needed -OPTDEFINES = /DSTDC_HEADERS +OPTDEFINES = /DSTDC_HEADERS /DUSE_NMAKE=1 !if $(VCVERSION) > 1600 OPTDEFINES = $(OPTDEFINES) /DHAVE_STDINT_H=1 !else @@ -1370,7 +1408,7 @@ OPTDEFINES = $(OPTDEFINES) /DSTATIC_BUILD !elseif $(TCL_VERSION) > 86 OPTDEFINES = $(OPTDEFINES) /DTCL_WITH_EXTERNAL_TOMMATH -!if "$(MACHINE)" == "AMD64" +!if "$(MACHINE)" == "AMD64" || "$(MACHINE)" == "ARM64" OPTDEFINES = $(OPTDEFINES) /DMP_64BIT !endif !endif @@ -1398,24 +1436,27 @@ !if $(PROFILE) OPTDEFINES = $(OPTDEFINES) /DTCL_CFG_PROFILED !endif -!if "$(MACHINE)" == "AMD64" +!if "$(MACHINE)" == "AMD64" || "$(MACHINE)" == "ARM64" OPTDEFINES = $(OPTDEFINES) /DTCL_CFG_DO64BIT !endif !if $(VCVERSION) < 1300 OPTDEFINES = $(OPTDEFINES) /DNO_STRTOI64=1 !endif -!if "$(TCL_MAJOR_VERSION)" == "8" +!if $(TCL_MAJOR_VERSION) == 8 !if "$(_USE_64BIT_TIME_T)" == "1" OPTDEFINES = $(OPTDEFINES) /D_USE_64BIT_TIME_T=1 !endif -!if "$(TCL_UTF_MAX)" == "4" -OPTDEFINES = $(OPTDEFINES) /DTCL_UTF_MAX=4 -!endif # _ATL_XP_TARGETING - Newer SDK's need this to build for XP COMPILERFLAGS = /D_ATL_XP_TARGETING !endif +!if "$(TCL_UTF_MAX)" == "3" +OPTDEFINES = $(OPTDEFINES) /DTCL_UTF_MAX=3 +!endif +!if "$(TCL_BUILD_FOR)" == "8" +OPTDEFINES = $(OPTDEFINES) /DTCL_MAJOR_VERSION=8 +!endif # Like the TEA system only set this non empty for non-Tk extensions # Note: some extensions use PACKAGE_NAME and others use PACKAGE_TCLNAME @@ -1457,10 +1498,10 @@ !endif # $(DEBUG) -# cwarn includes default warning levels. -cwarn = $(WARNINGS) +# cwarn includes default warning levels, also C4090 (buggy) and C4146 is useless. +cwarn = $(WARNINGS) -wd4090 -wd4146 -!if "$(MACHINE)" == "AMD64" +!if "$(MACHINE)" == "AMD64" || "$(MACHINE)" == "ARM64" # Disable pointer<->int warnings related to cast between different sizes # There are a gadzillion of these due to use of ClientData and # clutter up compiler @@ -1476,6 +1517,11 @@ carch = !endif +# cpuid is only available on intel machines +!if "$(MACHINE)" == "IX86" || "$(MACHINE)" == "AMD64" +carch = $(carch) /DHAVE_CPUID=1 +!endif + !if $(DEBUG) # Turn warnings into errors cwarn = $(cwarn) -WX