summaryrefslogtreecommitdiffstats
path: root/win/rules.vc
diff options
context:
space:
mode:
authorapnadkarni <apnmbx-wits@yahoo.com>2017-10-08 13:18:15 (GMT)
committerapnadkarni <apnmbx-wits@yahoo.com>2017-10-08 13:18:15 (GMT)
commit9845cc7c9ceedb5f71e3f0223391fb952156b7d1 (patch)
treed91c6391f8f4a317b8119098a9722c108d6bfcab /win/rules.vc
parentfdc29e53d31d86bad4fd5489197ec23e34369052 (diff)
downloadtcl-9845cc7c9ceedb5f71e3f0223391fb952156b7d1.zip
tcl-9845cc7c9ceedb5f71e3f0223391fb952156b7d1.tar.gz
tcl-9845cc7c9ceedb5f71e3f0223391fb952156b7d1.tar.bz2
Add default rc template so extensions do not have to write their own
Diffstat (limited to 'win/rules.vc')
-rw-r--r--win/rules.vc46
1 files changed, 42 insertions, 4 deletions
diff --git a/win/rules.vc b/win/rules.vc
index 702e313..d5952fd 100644
--- a/win/rules.vc
+++ b/win/rules.vc
@@ -398,8 +398,6 @@ _VC_MANIFEST_EMBED_DLL=if exist $@.manifest mt -nologo -manifest $@.manifest -ou
CFG_ENCODING = \"cp1252\"
!endif
-!message =====================================================================
-
################################################################
# 4. Build the nmakehlp program
# This is a helper app we need to overcome nmake's limiting
@@ -1337,12 +1335,12 @@ MAKEGUICMD = $(link32) $(guilflags) -out:$@ $(baselibs) $(tcllibs)
MAKERESCMD = $(rc32) -fo $@ -r -i "$(GENERICDIR)" -i "$(TMP_DIR)" \
$(TCL_INCLUDES) \
-DDEBUG=$(DEBUG) -d UNCHECKED=$(UNCHECKED) \
- -DTCL_THREADS=$(TCL_THREADS) \
- -DSTATIC_BUILD=$(STATIC_BUILD) \
-DCOMMAVERSION=$(DOTVERSION:.=,),0 \
-DDOTVERSION=\"$(DOTVERSION)\" \
-DVERSION=\"$(VERSION)\" \
-DSUFX=\"$(SUFX)\" \
+ -DPROJECT=\"$(PROJECT)\" \
+ -DPRJLIBNAME=\"$(PRJLIBNAME)\" \
$<
@@ -1404,6 +1402,43 @@ default-setup:
@if not exist $(OUT_DIR)\nul mkdir $(OUT_DIR)
@if not exist $(TMP_DIR)\nul mkdir $(TMP_DIR)
+default-rc:
+ @$(COPY) << $(TMP_DIR)\$(PROJECT).rc
+#include <winver.h>
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION COMMAVERSION
+ PRODUCTVERSION COMMAVERSION
+ FILEFLAGSMASK 0x3fL
+#ifdef DEBUG
+ FILEFLAGS VS_FF_DEBUG
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS VOS_NT_WINDOWS32
+ FILETYPE VFT_DLL
+ FILESUBTYPE 0x0L
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "040904b0"
+ BEGIN
+ VALUE "FileDescription", "Tcl extension " PROJECT
+ VALUE "OriginalFilename", PRJLIBNAME
+ VALUE "FileVersion", DOTVERSION
+ VALUE "ProductName", "Package " PROJECT " for Tcl"
+ VALUE "ProductVersion", DOTVERSION
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 0x409, 1200
+ END
+END
+
+<<
+
+
!ifndef DISABLE_IMPLICIT_RULES
# Implicit rule definitions - only for building library objects. For stubs and
# main application, the master makefile should define explicit rules.
@@ -1429,6 +1464,9 @@ $<
{$(WINDIR)}.rc{$(TMP_DIR)}.res:
$(MAKERESCMD)
+{$(TMP_DIR)}.rc{$(TMP_DIR)}.res:
+ $(MAKERESCMD)
+
.SUFFIXES:
.SUFFIXES:.c .rc