diff options
author | apnadkarni <apnmbx-wits@yahoo.com> | 2017-10-03 08:06:30 (GMT) |
---|---|---|
committer | apnadkarni <apnmbx-wits@yahoo.com> | 2017-10-03 08:06:30 (GMT) |
commit | f5c6b072469892af03a919e8c941e0426baead1f (patch) | |
tree | 9173711655b36f89c5c41d8e879fef582c92b159 /win/rules-ext.vc | |
parent | 35256f809ed60c7d2fe088246d90c8841686dc76 (diff) | |
download | tcl-f5c6b072469892af03a919e8c941e0426baead1f.zip tcl-f5c6b072469892af03a919e8c941e0426baead1f.tar.gz tcl-f5c6b072469892af03a919e8c941e0426baead1f.tar.bz2 |
Remove use of any macros used in rules.vc from rules-ext.vc
Added USE_WIDECHAR_API to control usage of Windows wide API's.
Diffstat (limited to 'win/rules-ext.vc')
-rw-r--r-- | win/rules-ext.vc | 36 |
1 files changed, 19 insertions, 17 deletions
diff --git a/win/rules-ext.vc b/win/rules-ext.vc index 2a8943b..094bc32 100644 --- a/win/rules-ext.vc +++ b/win/rules-ext.vc @@ -1,38 +1,40 @@ # This file should only be included in makefiles for Tcl extensions, # NOT in the makefile for Tcl itself. + +!ifndef _RULES_EXT_VC + !if "$(PROJECT)" == "tcl" !error The rules-ext.vc file is not intended for Tcl itself. !endif # First locate the Tcl directory that we are working with. -!ifndef TCLDIR +!ifdef TCLDIR + +_RULESDIR = $(TCLDIR:/=\) + +!else # If an installation path is specified, that is also the Tcl directory. # Also, tk never builds against an installed Tcl, it needs Tcl sources !if defined(INSTALLDIR) && "$(PROJECT)" != "tk" -TCLDIR=$(INSTALLDIR) +_RULESDIR=$(INSTALLDIR:/=\) !else -TCLDIR = ../../tcl +_RULESDIR = ..\..\tcl !endif !endif # ifndef TCLDIR -# _TCLDIR = Windows native path format of TCLDIR -_TCLDIR = $(TCLDIR:/=\) - # Now look for the rules.vc file under the Tcl root -!if exist("$(_TCLDIR)\lib\nmake\rules.vc") # Building against installed Tcl -_RULESDIR = $(_TCLDIR)\lib\nmake -!elseif exist("$(_TCLDIR)\win\rules.vc") # Building against Tcl sources -_RULESDIR = $(_TCLDIR)\win +!if exist("$(_RULESDIR)\lib\nmake\rules.vc") # Building against installed Tcl +_RULESDIR = $(_RULESDIR)\lib\nmake +!elseif exist("$(_RULESDIR)\win\rules.vc") # Building against Tcl sources +_RULESDIR = $(_RULESDIR)\win !else # If we have not located Tcl's rules file, most likely we are compiling # against an older version of Tcl and so must use our own support files. _RULESDIR = . !endif -_RULES_VC = $(_RULESDIR)\rules.vc - !if "$(_RULESDIR)" != "." # Potentially using Tcl's support files. Need to compare the versions. # We extract version numbers using the nmakehlp program. For this @@ -41,10 +43,10 @@ _RULES_VC = $(_RULESDIR)\rules.vc !endif !if [echo TCL_RULES_MAJOR = \> versions.vc] \ - && [nmakehlp -V "$(_RULES_VC)" RULES_VERSION_MAJOR >> versions.vc] + && [nmakehlp -V "$(_RULESDIR)\rules.vc" RULES_VERSION_MAJOR >> versions.vc] !endif !if [echo TCL_RULES_MINOR = \>> versions.vc] \ - && [nmakehlp -V "$(_RULES_VC)" RULES_VERSION_MINOR >> versions.vc] + && [nmakehlp -V "$(_RULESDIR)\rules.vc" RULES_VERSION_MINOR >> versions.vc] !endif !if [echo OUR_RULES_MAJOR = \>> versions.vc] \ @@ -55,7 +57,6 @@ _RULES_VC = $(_RULESDIR)\rules.vc !endif !include versions.vc # We have a newer version of the support files, use them -!message V $(TCL_RULES_MAJOR) $(TCL_RULES_MINOR) $(OUR_RULES_MAJOR) $(OUR_RULES_MINOR) !if ($(TCL_RULES_MAJOR) != $(OUR_RULES_MAJOR)) || ($(TCL_RULES_MINOR) < $(OUR_RULES_MINOR)) _RULESDIR = . !endif @@ -64,11 +65,12 @@ _RULESDIR = . # Get rid of our internal defines before calling rules.vc -!undef _TCLDIR !undef TCL_RULES_MAJOR !undef TCL_RULES_MINOR !undef OUR_RULES_MAJOR !undef OUR_RULES_MINOR !message *** Using $(_RULESDIR)\rules.vc -#!include "$(_RULESDIR)\rules.vc" +!include "$(_RULESDIR)\rules.vc" + +!endif # _RULES_EXT_VC
\ No newline at end of file |