ICU-661 Add version information to the data DLL

X-SVN-Rev: 4650
This commit is contained in:
George Rhoten 2001-05-10 23:16:00 +00:00
parent e84355aaf7
commit 35f531cbb0
5 changed files with 153 additions and 6 deletions

65
icu4c/data/icudata.rc Normal file
View File

@ -0,0 +1,65 @@
//Do not edit with Microsoft Developer Studio because it will modify this
//script in the wrong way.
//
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
#pragma code_page(1252)
#include "unicode\utypes.h"
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
#define STR(s) #s
#define CommaVersionString(a, b, c, d) STR(a) ", " STR(b) ", " STR(c) ", " STR(d) "\0"
VS_VERSION_INFO VERSIONINFO
FILEVERSION U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0
PRODUCTVERSION U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS VOS__WINDOWS32
FILETYPE VFT_DLL
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "00000000"
BEGIN
VALUE "Comments", "http://oss.software.ibm.com/icu\0"
VALUE "CompanyName", "IBM Corporation and others\0"
VALUE "FileDescription", "ICU Data DLL\0"
VALUE "FileVersion", CommaVersionString(U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0)
VALUE "LegalCopyright", U_COPYRIGHT_STRING "\0"
VALUE "OriginalFilename", U_ICUDATA_NAME ".dll\0"
VALUE "PrivateBuild", "\0"
VALUE "ProductName", "International Components for Unicode\0"
VALUE "ProductVersion", CommaVersionString(U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0)
VALUE "SpecialBuild", "\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x000, 0000
END
END
/////////////////////////////////////////////////////////////////////////////

View File

@ -130,14 +130,14 @@ ALL : GODATA testdata "$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" $(DLL_OUTPUT)\test1
testdata: ucadata.dat $(RB_FILES) {"$(ICUTOOLS)\genrb\$(CFG)"}genrb.exe
@cd "$(TESTDATA)"
nmake /f $(TESTDATA)\testdata.mk TESTDATA=$(TESTDATA) ICUTOOLS=$(ICUTOOLS) PKGOPT=$(PKGOPT) CFG=$(CFG) DLL_OUTPUT=$(DLL_OUTPUT) TESTDATAOUT=$(TESTDATAOUT)
nmake /nologo /f $(TESTDATA)\testdata.mk TESTDATA=$(TESTDATA) ICUTOOLS=$(ICUTOOLS) PKGOPT=$(PKGOPT) CFG=$(CFG) DLL_OUTPUT=$(DLL_OUTPUT) TESTDATAOUT=$(TESTDATAOUT)
@cd "$(ICUDBLD)"
BRK_FILES = "$(ICUDBLD)\sent.brk" "$(ICUDBLD)\char.brk" "$(ICUDBLD)\line.brk" "$(ICUDBLD)\word.brk" "$(ICUDBLD)\line_th.brk" "$(ICUDBLD)\word_th.brk"
#invoke pkgdata
"$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" : $(CNV_FILES) $(BRK_FILES) qchk.dat fchk.dat uprops.dat unames.dat cnvalias.dat tz.dat ucadata.dat invuca.dat $(ALL_RES)
"$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" : $(CNV_FILES) $(BRK_FILES) qchk.dat fchk.dat uprops.dat unames.dat cnvalias.dat tz.dat ucadata.dat invuca.dat $(ALL_RES) icudata.res
@echo Building icu data
@cd "$(ICUDBLD)"
"$(ICUTOOLS)\pkgdata\$(CFG)\pkgdata" -e icudata -v -T . -m dll -c -p $(U_ICUDATA_NAME) -O "$(PKGOPT)" -d "$(DLL_OUTPUT)" -s . <<pkgdatain.txt
@ -245,6 +245,11 @@ $(DLL_OUTPUT)\test4.cnv: "$(TESTDATA)\test4.ucm"
@set ICU_DATA=$(DLL_OUTPUT)
@"$(ICUTOOLS)\makeconv\$(CFG)\makeconv" $**
# DLL version information
icudata.res: "$(ICUDATA)\icudata.rc"
@echo Creating data DLL version information from $**
@rc.exe /i ..\..\..\include\ /r /fo "$@" $**
# Targets for qchk.dat
qchk.dat: "$(ICUDATA)\unidata\QuickCheck.txt" "$(ICUTOOLS)\genqchk\$(CFG)\genqchk.exe"
@echo Creating data file for Quick Check Properties

View File

@ -130,14 +130,14 @@ ALL : GODATA testdata "$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" $(DLL_OUTPUT)\test1
testdata: ucadata.dat $(RB_FILES) {"$(ICUTOOLS)\genrb\$(CFG)"}genrb.exe
@cd "$(TESTDATA)"
nmake /f $(TESTDATA)\testdata.mk TESTDATA=$(TESTDATA) ICUTOOLS=$(ICUTOOLS) PKGOPT=$(PKGOPT) CFG=$(CFG) DLL_OUTPUT=$(DLL_OUTPUT) TESTDATAOUT=$(TESTDATAOUT)
nmake /nologo /f $(TESTDATA)\testdata.mk TESTDATA=$(TESTDATA) ICUTOOLS=$(ICUTOOLS) PKGOPT=$(PKGOPT) CFG=$(CFG) DLL_OUTPUT=$(DLL_OUTPUT) TESTDATAOUT=$(TESTDATAOUT)
@cd "$(ICUDBLD)"
BRK_FILES = "$(ICUDBLD)\sent.brk" "$(ICUDBLD)\char.brk" "$(ICUDBLD)\line.brk" "$(ICUDBLD)\word.brk" "$(ICUDBLD)\line_th.brk" "$(ICUDBLD)\word_th.brk"
#invoke pkgdata
"$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" : $(CNV_FILES) $(BRK_FILES) qchk.dat fchk.dat uprops.dat unames.dat cnvalias.dat tz.dat ucadata.dat invuca.dat $(ALL_RES)
"$(DLL_OUTPUT)\$(U_ICUDATA_NAME).dll" : $(CNV_FILES) $(BRK_FILES) qchk.dat fchk.dat uprops.dat unames.dat cnvalias.dat tz.dat ucadata.dat invuca.dat $(ALL_RES) icudata.res
@echo Building icu data
@cd "$(ICUDBLD)"
"$(ICUTOOLS)\pkgdata\$(CFG)\pkgdata" -e icudata -v -T . -m dll -c -p $(U_ICUDATA_NAME) -O "$(PKGOPT)" -d "$(DLL_OUTPUT)" -s . <<pkgdatain.txt
@ -245,6 +245,11 @@ $(DLL_OUTPUT)\test4.cnv: "$(TESTDATA)\test4.ucm"
@set ICU_DATA=$(DLL_OUTPUT)
@"$(ICUTOOLS)\makeconv\$(CFG)\makeconv" $**
# DLL version information
icudata.res: "$(ICUDATA)\icudata.rc"
@echo Creating data DLL version information from $**
@rc.exe /i ..\..\..\include\ /r /fo "$@" $**
# Targets for qchk.dat
qchk.dat: "$(ICUDATA)\unidata\QuickCheck.txt" "$(ICUTOOLS)\genqchk\$(CFG)\genqchk.exe"
@echo Creating data file for Quick Check Properties

View File

@ -0,0 +1,65 @@
//Do not edit with Microsoft Developer Studio because it will modify this
//script in the wrong way.
//
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
#pragma code_page(1252)
#include "unicode\utypes.h"
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
#define STR(s) #s
#define CommaVersionString(a, b, c, d) STR(a) ", " STR(b) ", " STR(c) ", " STR(d) "\0"
VS_VERSION_INFO VERSIONINFO
FILEVERSION U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0
PRODUCTVERSION U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS VOS__WINDOWS32
FILETYPE VFT_DLL
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "00000000"
BEGIN
VALUE "Comments", "http://oss.software.ibm.com/icu\0"
VALUE "CompanyName", "IBM Corporation and others\0"
VALUE "FileDescription", "ICU Data DLL\0"
VALUE "FileVersion", CommaVersionString(U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0)
VALUE "LegalCopyright", U_COPYRIGHT_STRING "\0"
VALUE "OriginalFilename", U_ICUDATA_NAME ".dll\0"
VALUE "PrivateBuild", "\0"
VALUE "ProductName", "International Components for Unicode\0"
VALUE "ProductVersion", CommaVersionString(U_ICU_VERSION_MAJOR_NUM, U_ICU_VERSION_MINOR_NUM, U_ICU_VERSION_PATCHLEVEL_NUM, 0)
VALUE "SpecialBuild", "\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x000, 0000
END
END
/////////////////////////////////////////////////////////////////////////////

View File

@ -96,7 +96,7 @@ void pkg_mode_windows(UPKGOptions *o, FileStream *makefile, UErrorCode *status)
sprintf(tmp2,
"LINK32 = link.exe\n"
"LINK32_FLAGS = /out:\"$(TARGETDIR)\\$(DLLTARGET)\" /DLL /NOENTRY /base:\"0x4ad00000\" /implib:\"$(TARGETDIR)\\$(ENTRYPOINT).lib\" /comment:\"%s\"\n",
"LINK32_FLAGS = /nologo /out:\"$(TARGETDIR)\\$(DLLTARGET)\" /DLL /NOENTRY /base:\"0x4ad00000\" /implib:\"$(TARGETDIR)\\$(ENTRYPOINT).lib\" /comment:\"%s\"\n",
o->comment
);
T_FileStream_writeLine(makefile, tmp2);
@ -106,6 +106,13 @@ void pkg_mode_windows(UPKGOptions *o, FileStream *makefile, UErrorCode *status)
separator, WINBUILDMODE);
T_FileStream_writeLine(makefile, tmp2);
T_FileStream_writeLine(makefile, "\n"
"# Windows specific DLL version information.\n"
"!IF EXISTS(\".\\icudata.res\")\n"
"DATA_VER_INFO=\".\\icudata.res\"\n"
"!ELSE\n"
"DATA_VER_INFO=\n"
"!ENDIF\n\n");
uprv_strcpy(tmp, UDATA_CMN_PREFIX);
@ -140,7 +147,7 @@ void pkg_mode_windows(UPKGOptions *o, FileStream *makefile, UErrorCode *status)
T_FileStream_writeLine(makefile, tmp);
sprintf(tmp, "\"$(TARGETDIR)\\$(DLLTARGET)\": \"$(TARGETDIR)\\$(CMNOBJTARGET)\"\n"
"\t@$(LINK32) $(LINK32_FLAGS) \"$(TARGETDIR)\\$(CMNOBJTARGET)\"\n\n");
"\t@$(LINK32) $(LINK32_FLAGS) \"$(TARGETDIR)\\$(CMNOBJTARGET)\" $(DATA_VER_INFO)\n\n");
T_FileStream_writeLine(makefile, tmp);
sprintf(tmp, "\"$(TARGETDIR)\\$(CMNOBJTARGET)\": \"$(TARGETDIR)\\$(CMNTARGET)\"\n"
"\t@\"$(GENCCODE)\" $(GENCOPTIONS) -e $(ENTRYPOINT) -o -d \"$(TARGETDIR)\" \"$(TARGETDIR)\\$(CMNTARGET)\"\n\n");