summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorpatthoyts <patthoyts@users.sourceforge.net>2008-06-25 10:57:40 (GMT)
committerpatthoyts <patthoyts@users.sourceforge.net>2008-06-25 10:57:40 (GMT)
commita7b4211c86a0b013b89aa1e1065734d0144ade64 (patch)
tree581d8913fd6b65cd66403377ec3912f2ced5fe84 /win
parentc820615a4044a2e66526fddb735e239763ad368a (diff)
downloadtcl-a7b4211c86a0b013b89aa1e1065734d0144ade64.zip
tcl-a7b4211c86a0b013b89aa1e1065734d0144ade64.tar.gz
tcl-a7b4211c86a0b013b89aa1e1065734d0144ade64.tar.bz2
Backported fix for dde/registry versions and the staticpkg build option
Diffstat (limited to 'win')
-rw-r--r--win/makefile.vc28
-rw-r--r--win/rules.vc23
2 files changed, 40 insertions, 11 deletions
diff --git a/win/makefile.vc b/win/makefile.vc
index 43cd63e..aba5e68 100644
--- a/win/makefile.vc
+++ b/win/makefile.vc
@@ -1,4 +1,4 @@
-#------------------------------------------------------------------------------
+#------------------------------------------------------------- -*- makefile -*-
# makefile.vc --
#
# Microsoft Visual C++ makefile for use with nmake.exe v1.62+ (VC++ 5.0+)
@@ -10,9 +10,10 @@
# Copyright (c) 1998-2000 Ajuba Solutions.
# Copyright (c) 2001-2005 ActiveState Corporation.
# Copyright (c) 2001-2004 David Gravereaux.
+# Copyright (c) 2003-2008 Pat Thoyts.
#
#------------------------------------------------------------------------------
-# RCS: @(#) $Id: makefile.vc,v 1.175 2007/12/14 02:27:11 patthoyts Exp $
+# RCS: @(#) $Id: makefile.vc,v 1.175.2.1 2008/06/25 10:57:54 patthoyts Exp $
#------------------------------------------------------------------------------
# Check to see we are configured to build with MSVC (MSDEVDIR or MSVCDIR)
@@ -410,6 +411,9 @@ cdebug = -O2 $(OPTIMIZATIONS)
!else
cdebug =
!endif
+!if $(SYMBOLS)
+cdebug = $(cdebug) -Zi
+!endif
!else if "$(MACHINE)" == "IA64" || "$(MACHINE)" == "AMD64"
### Warnings are too many, can't support warnings into errors.
cdebug = -Zi -Od $(DEBUGFLAGS)
@@ -440,7 +444,8 @@ TCL_DEFINES = -DTCL_PIPE_DLL=\"$(TCLPIPEDLLNAME)\" -DTCL_TOMMATH -DMP_PREC=4 -Di
BASE_CFLAGS = $(cflags) $(cdebug) $(crt) $(TCL_INCLUDES) $(TCL_DEFINES)
CON_CFLAGS = $(cflags) $(cdebug) $(crt) -DCONSOLE
TCL_CFLAGS = $(BASE_CFLAGS) $(OPTDEFINES)
-STUB_CFLAGS = $(cflags) $(cdebug) $(OPTDEFINES)
+### Stubs files should not be compiled with -GL
+STUB_CFLAGS = $(cflags) $(cdebug:-GL=) $(OPTDEFINES)
#---------------------------------------------------------------------
@@ -451,6 +456,9 @@ STUB_CFLAGS = $(cflags) $(cdebug) $(OPTDEFINES)
ldebug = -debug:full -debugtype:cv
!else
ldebug = -release -opt:ref -opt:icf,3
+!if $(SYMBOLS)
+ldebug = $(ldebug) -debug:full -debugtype:cv
+!endif
!endif
### Declarations common to all linker options
@@ -525,7 +533,7 @@ test: setup $(TCLTEST) dlls $(CAT32)
runtest: setup $(TCLTEST) dlls $(CAT32)
set TCL_LIBRARY=$(ROOT)/library
- $(TCLTEST)
+ $(DEBUGGER) $(TCLTEST)
setup:
@if not exist $(OUT_DIR)\nul mkdir $(OUT_DIR)
@@ -566,7 +574,9 @@ $(TCLPIPEDLL): $(WINDIR)\stub16.c
$(_VC_MANIFEST_EMBED_DLL)
!if $(STATIC_BUILD)
-!if !$(TCL_USE_STATIC_PACKAGES)
+!if $(TCL_USE_STATIC_PACKAGES)
+$(TCLDDELIB):
+!else
$(TCLDDELIB): $(TMP_DIR)\tclWinDde.obj
$(lib32) -nologo -out:$@ $(TMP_DIR)\tclWinDde.obj
!endif
@@ -580,7 +590,9 @@ $(TCLDDELIB): $(TMP_DIR)\tclWinDde.obj $(TCLSTUBLIB)
!endif
!if $(STATIC_BUILD)
-!if !$(TCL_USE_STATIC_PACKAGES)
+!if $(TCL_USE_STATIC_PACKAGES)
+$(TCLREGLIB):
+!else
$(TCLREGLIB): $(TMP_DIR)\tclWinReg.obj
$(lib32) -nologo -out:$@ $(TMP_DIR)\tclWinReg.obj
!endif
@@ -985,7 +997,9 @@ install-libraries: tclConfig install-msgs install-tzdata
"$(SCRIPT_INSTALL_DIR)\..\tcl8\8.4\platform\shell-$(PKG_SHELL_VER).tm"
@echo Installing $(TCLDDELIBNAME)
!if $(STATIC_BUILD)
+!if !$(TCL_USE_STATIC_PACKAGES)
@$(CPY) "$(TCLDDELIB)" "$(LIB_INSTALL_DIR)\"
+!endif
!else
@$(CPY) "$(TCLDDELIB)" "$(LIB_INSTALL_DIR)\dde$(DDEDOTVERSION)\"
@$(CPY) "$(ROOT)\library\dde\pkgIndex.tcl" \
@@ -993,7 +1007,9 @@ install-libraries: tclConfig install-msgs install-tzdata
!endif
@echo Installing $(TCLREGLIBNAME)
!if $(STATIC_BUILD)
+!if !$(TCL_USE_STATIC_PACKAGES)
@$(CPY) "$(TCLREGLIB)" "$(LIB_INSTALL_DIR)\"
+!endif
!else
@$(CPY) "$(TCLREGLIB)" "$(LIB_INSTALL_DIR)\reg$(REGDOTVERSION)\"
@$(CPY) "$(ROOT)\library\reg\pkgIndex.tcl" \
diff --git a/win/rules.vc b/win/rules.vc
index 83a82b9..1eebd83 100644
--- a/win/rules.vc
+++ b/win/rules.vc
@@ -11,7 +11,7 @@
# Copyright (c) 2003-2007 Patrick Thoyts
#
#------------------------------------------------------------------------------
-# RCS: @(#) $Id: rules.vc,v 1.35 2007/12/13 15:28:43 dgp Exp $
+# RCS: @(#) $Id: rules.vc,v 1.35.2.1 2008/06/25 10:57:54 patthoyts Exp $
#------------------------------------------------------------------------------
!ifndef _RULES_VC
@@ -214,6 +214,7 @@ _VC_MANIFEST_EMBED_DLL=if exist $@.manifest mt -nologo -manifest $@.manifest -ou
STATIC_BUILD = 0
TCL_THREADS = 0
DEBUG = 0
+SYMBOLS = 0
PROFILE = 0
MSVCRT = 0
LOIMPACT = 0
@@ -251,6 +252,12 @@ DEBUG = 1
!else
DEBUG = 0
!endif
+!if [nmakehlp -f $(OPTS) "pdbs"]
+!message *** Doing pdbs
+SYMBOLS = 1
+!else
+SYMBOLS = 0
+!endif
!if [nmakehlp -f $(OPTS) "profile"]
!message *** Doing profile
PROFILE = 1
@@ -523,6 +530,12 @@ Failed to find tcl.h. The TCLDIR macro does not appear correct.
!if [echo PKG_SHELL_VER = \>> versions.vc] \
&& [nmakehlp -V ..\library\platform\pkgIndex.tcl "platform::shell" >> versions.vc]
!endif
+!if [echo PKG_DDE_VER = \>> versions.vc] \
+ && [nmakehlp -V ..\library\dde\pkgIndex.tcl "dde " >> versions.vc]
+!endif
+!if [echo PKG_REG_VER =\>> versions.vc] \
+ && [nmakehlp -V ..\library\reg\pkgIndex.tcl registry >> versions.vc]
+!endif
!endif
!include versions.vc
@@ -549,8 +562,8 @@ TCLSH = "$(_TCLDIR)\bin\tclsh$(TCL_VERSION)t$(SUFX).exe"
TCLSTUBLIB = "$(_TCLDIR)\lib\tclstub$(TCL_VERSION).lib"
TCLIMPLIB = "$(_TCLDIR)\lib\tcl$(TCL_VERSION)$(SUFX).lib"
TCL_LIBRARY = $(_TCLDIR)\lib
-TCLREGLIB = "$(_TCLDIR)\lib\tclreg11$(SUFX:t=).lib"
-TCLDDELIB = "$(_TCLDIR)\lib\tcldde12$(SUFX:t=).lib"
+TCLREGLIB = "$(_TCLDIR)\lib\tclreg12$(SUFX:t=).lib"
+TCLDDELIB = "$(_TCLDIR)\lib\tcldde13$(SUFX:t=).lib"
COFFBASE = \must\have\tcl\sources\to\build\this\target
TCLTOOLSDIR = \must\have\tcl\sources\to\build\this\target
TCL_INCLUDES = -I"$(_TCLDIR)\include"
@@ -562,8 +575,8 @@ TCLSH = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)t$(SUFX).exe"
TCLSTUBLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub$(TCL_VERSION).lib"
TCLIMPLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX).lib"
TCL_LIBRARY = $(_TCLDIR)\library
-TCLREGLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclreg11$(SUFX:t=).lib"
-TCLDDELIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcldde12$(SUFX:t=).lib"
+TCLREGLIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tclreg12$(SUFX:t=).lib"
+TCLDDELIB = "$(_TCLDIR)\win\$(BUILDDIRTOP)\tcldde13$(SUFX:t=).lib"
COFFBASE = "$(_TCLDIR)\win\coffbase.txt"
TCLTOOLSDIR = $(_TCLDIR)\tools
TCL_INCLUDES = -I"$(_TCLDIR)\generic" -I"$(_TCLDIR)\win"