diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-11-28 12:53:38 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-11-28 12:53:38 (GMT) |
commit | 122bb72a66973fecc8939b5bb376d2b65334738b (patch) | |
tree | 39167800b1a305c79f29ee648f9f308b714c6c2e /win | |
parent | 7c405f2e81b0eb2fbc2eae23dfaab798dcf44411 (diff) | |
download | tcl-122bb72a66973fecc8939b5bb376d2b65334738b.zip tcl-122bb72a66973fecc8939b5bb376d2b65334738b.tar.gz tcl-122bb72a66973fecc8939b5bb376d2b65334738b.tar.bz2 |
Enhance rules.vc like already done in other configure scripts: Determine HAVE_STDINT_H/HAVE_INTTYPES_H/HAVE_STDBOOL_H/MP_NO_STDINT the simple way, just by compiler version.
Diffstat (limited to 'win')
-rw-r--r-- | win/makefile.vc | 2 | ||||
-rw-r--r-- | win/rules.vc | 13 | ||||
-rw-r--r-- | win/tclWinPort.h | 2 |
3 files changed, 14 insertions, 3 deletions
diff --git a/win/makefile.vc b/win/makefile.vc index fe9b790..26f7da3 100644 --- a/win/makefile.vc +++ b/win/makefile.vc @@ -418,7 +418,7 @@ PKGSDIR = $(ROOT)\pkgs # Additional include and C macro definitions for the implicit rules
# defined in rules.vc
PRJ_INCLUDES = -I"$(TOMMATHDIR)"
-PRJ_DEFINES = /DTCL_TOMMATH /DMP_PREC=4 /Dinline=__inline /DHAVE_ZLIB=1 /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE /DMP_FIXED_CUTOFFS /DMP_NO_STDINT
+PRJ_DEFINES = /DTCL_TOMMATH /DMP_PREC=4 /Dinline=__inline /DHAVE_ZLIB=1 /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE /DMP_FIXED_CUTOFFS
# Additional Link libraries needed beyond those in rules.vc
PRJ_LIBS = netapi32.lib user32.lib userenv.lib ws2_32.lib
diff --git a/win/rules.vc b/win/rules.vc index 2061e9b..8050ed3 100644 --- a/win/rules.vc +++ b/win/rules.vc @@ -24,7 +24,7 @@ _RULES_VC = 1 # For modifications that are not backward-compatible, you *must* change
# the major version.
RULES_VERSION_MAJOR = 1
-RULES_VERSION_MINOR = 5
+RULES_VERSION_MINOR = 6
# The PROJECT macro must be defined by parent makefile.
!if "$(PROJECT)" == ""
@@ -1291,6 +1291,17 @@ INCLUDE_INSTALL_DIR = $(_INSTALLDIR)\..\include # define PRJ_LIBS before including rules.rc if additional libs are needed
OPTDEFINES = /DTCL_CFGVAL_ENCODING=$(CFG_ENCODING) /DSTDC_HEADERS
+!if $(VCVERSION) >= 1600
+OPTDEFINES = $(OPTDEFINES) /DHAVE_STDINT_H=1
+!else
+OPTDEFINES = $(OPTDEFINES) /DMP_NO_STDINT=1
+!endif
+!if $(VCVERSION) >= 1700
+OPTDEFINES = $(OPTDEFINES) /DHAVE_INTTYPES_H=1
+!endif
+!if $(VCVERSION) >= 1800
+OPTDEFINES = $(OPTDEFINES) /DHAVE_STDBOOL_H=1
+!endif
!if $(TCL_MEM_DEBUG)
OPTDEFINES = $(OPTDEFINES) /DTCL_MEM_DEBUG
diff --git a/win/tclWinPort.h b/win/tclWinPort.h index 5e63c02..e2eae56 100644 --- a/win/tclWinPort.h +++ b/win/tclWinPort.h @@ -92,7 +92,7 @@ typedef DWORD_PTR * PDWORD_PTR; #include <malloc.h> #include <process.h> #include <signal.h> -#if HAVE_INTTYPES_H +#ifdef HAVE_INTTYPES_H # include <inttypes.h> #endif #include <limits.h> |