summaryrefslogtreecommitdiffstats
path: root/win/rules.vc
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2019-12-04 13:30:22 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2019-12-04 13:30:22 (GMT)
commit8ed389c37a4e2b151412b9b3b7b5308cb73a6a66 (patch)
tree6c87f6ceea8cb7ed79608db9c93fdd28a0a2d02c /win/rules.vc
parent3fc1c2a1729ed34996f1f447f93aadd6b0b6416f (diff)
parent7d17ab9a13b2917659e8ced2ba0ae79f05a2ba09 (diff)
downloadtcl-8ed389c37a4e2b151412b9b3b7b5308cb73a6a66.zip
tcl-8ed389c37a4e2b151412b9b3b7b5308cb73a6a66.tar.gz
tcl-8ed389c37a4e2b151412b9b3b7b5308cb73a6a66.tar.bz2
Merge 8.7
Diffstat (limited to 'win/rules.vc')
-rw-r--r--win/rules.vc35
1 files changed, 31 insertions, 4 deletions
diff --git a/win/rules.vc b/win/rules.vc
index 33d80b7..c05f43b 100644
--- a/win/rules.vc
+++ b/win/rules.vc
@@ -744,6 +744,15 @@ TCL_USE_STATIC_PACKAGES = 1
TCL_USE_STATIC_PACKAGES = 0
!endif
+!if [nmakehlp -f $(OPTS) "nothreads"]
+!message *** Compile explicitly for non-threaded tcl
+TCL_THREADS = 0
+USE_THREAD_ALLOC= 0
+!else
+TCL_THREADS = 1
+USE_THREAD_ALLOC= 1
+!endif
+
!if [nmakehlp -f $(OPTS) "utfmax"]
!message *** Force 32-bit Tcl_UniChar
TCL_UTF_MAX = 6
@@ -786,6 +795,12 @@ PGO = 0
!message *** Warning: ignoring option "loimpact" - deprecated on modern Windows.
!endif
+# TBD - should get rid of this option
+!if [nmakehlp -f $(OPTS) "thrdalloc"]
+!message *** Doing thrdalloc
+USE_THREAD_ALLOC = 1
+!endif
+
!if [nmakehlp -f $(OPTS) "tclalloc"]
USE_THREAD_ALLOC = 0
!endif
@@ -1196,8 +1211,8 @@ tklibs = "$(TKSTUBLIB)" "$(TKIMPLIB)"
!endif # $(DOING_TK) || $(NEED_TK)
# Various output paths
-PRJIMPLIB = $(OUT_DIR)\$(PROJECT)$(VERSION)$(SUFX:t=).lib
-PRJLIBNAME = $(PROJECT)$(VERSION)$(SUFX:t=).$(EXT)
+PRJIMPLIB = $(OUT_DIR)\$(PROJECT)$(VERSION)$(SUFX).lib
+PRJLIBNAME = $(PROJECT)$(VERSION)$(SUFX).$(EXT)
PRJLIB = $(OUT_DIR)\$(PRJLIBNAME)
PRJSTUBLIBNAME = $(STUBPREFIX)$(VERSION).lib
@@ -1330,7 +1345,7 @@ OPTDEFINES = $(OPTDEFINES) /DTCL_CFG_PROFILED
OPTDEFINES = $(OPTDEFINES) /DTCL_CFG_DO64BIT
!endif
!if $(VCVERSION) < 1300
-OPTDEFINES = $(OPTDEFINES) /DNO_STRTOI64
+OPTDEFINES = $(OPTDEFINES) /DNO_STRTOI64=1
!endif
!if "$(TCL_UTF_MAX)" == "6"
@@ -1463,6 +1478,18 @@ lflags = -nologo -machine:$(MACHINE) $(LINKERFLAGS) $(ldebug)
lflags = $(lflags) -nodefaultlib:libucrt.lib
!endif
+# Old linkers (Visual C++ 6 in particular) will link for fast loading
+# on Win98. Since we do not support Win98 any more, we specify nowin98
+# as recommended for NT and later. However, this is only required by
+# IX86 on older compilers and only needed if we are not doing a static build.
+
+!if "$(MACHINE)" == "IX86" && !$(STATIC_BUILD)
+!if [nmakehlp -l -opt:nowin98 $(LINKER_TESTFLAGS)]
+# Align sections for PE size savings.
+lflags = $(lflags) -opt:nowin98
+!endif
+!endif
+
dlllflags = $(lflags) -dll
conlflags = $(lflags) -subsystem:console
guilflags = $(lflags) -subsystem:windows
@@ -1507,7 +1534,7 @@ RESCMD = $(rc32) -fo $@ -r -i "$(GENERICDIR)" -i "$(TMP_DIR)" \
/DCOMMAVERSION=$(RCCOMMAVERSION) \
/DDOTVERSION=\"$(DOTVERSION)\" \
/DVERSION=\"$(VERSION)\" \
- /DSUFX=\"$(SUFX:t=)\" \
+ /DSUFX=\"$(SUFX)\" \
/DPROJECT=\"$(PROJECT)\" \
/DPRJLIBNAME=\"$(PRJLIBNAME)\"