https://git.reactos.org/?p=reactos.git;a=commitdiff;h=3551953c846a165029ff1…
commit 3551953c846a165029ff1ae85875d57f6b1f6744
Author: Mark Jansen <mark.jansen(a)reactos.org>
AuthorDate: Sat Feb 24 18:42:42 2018 +0100
Commit: Mark Jansen <mark.jansen(a)reactos.org>
CommitDate: Sun Apr 22 18:51:53 2018 +0200
[XML2SDB] Add support for TAG_LINK_DATE and TAG_LINKER_VERSION.
---
sdk/tools/xml2sdb/xml2sdb.cpp | 11 ++++-------
sdk/tools/xml2sdb/xml2sdb.h | 6 +++---
2 files changed, 7 insertions(+), 10 deletions(-)
diff --git a/sdk/tools/xml2sdb/xml2sdb.cpp b/sdk/tools/xml2sdb/xml2sdb.cpp
index 3478e0561b..bba0335bfe 100644
--- a/sdk/tools/xml2sdb/xml2sdb.cpp
+++ b/sdk/tools/xml2sdb/xml2sdb.cpp
@@ -503,12 +503,12 @@ bool MatchingFile::fromXml(XMLHandle dbNode)
ProductVersion = ReadStringNode(dbNode, "PRODUCT_VERSION");
FileVersion = ReadStringNode(dbNode, "FILE_VERSION");
BinFileVersion = ReadStringNode(dbNode, "BIN_FILE_VERSION");
- LinkDate = ReadStringNode(dbNode, "LINK_DATE");
+ LinkDate = ReadDWordNode(dbNode, "LINK_DATE");
VerLanguage = ReadStringNode(dbNode, "VER_LANGUAGE");
FileDescription = ReadStringNode(dbNode, "FILE_DESCRIPTION");
OriginalFilename = ReadStringNode(dbNode, "ORIGINAL_FILENAME");
UptoBinFileVersion = ReadStringNode(dbNode, "UPTO_BIN_FILE_VERSION");
- LinkerVersion = ReadStringNode(dbNode, "LINKER_VERSION");
+ LinkerVersion = ReadDWordNode(dbNode, "LINKER_VERSION");
return true;
}
@@ -526,17 +526,14 @@ bool MatchingFile::toSdb(PDB pdb, Database& db)
db.WriteString(pdb, TAG_FILE_VERSION, FileVersion);
if (!BinFileVersion.empty())
SHIM_ERR("TAG_BIN_FILE_VERSION Unimplemented\n"); //db.WriteQWord(pdb,
TAG_BIN_FILE_VERSION, BinFileVersion);
- if (!LinkDate.empty())
- SHIM_ERR("TAG_LINK_DATE Unimplemented\n"); //db.WriteDWord(pdb,
TAG_LINK_DATE, LinkDate);
+ db.WriteDWord(pdb, TAG_LINK_DATE, LinkDate);
if (!VerLanguage.empty())
SHIM_ERR("TAG_VER_LANGUAGE Unimplemented\n"); //db.WriteDWord(pdb,
TAG_VER_LANGUAGE, VerLanguage);
db.WriteString(pdb, TAG_FILE_DESCRIPTION, FileDescription);
db.WriteString(pdb, TAG_ORIGINAL_FILENAME, OriginalFilename);
if (!UptoBinFileVersion.empty())
SHIM_ERR("TAG_UPTO_BIN_FILE_VERSION Unimplemented\n");
//db.WriteQWord(pdb, TAG_UPTO_BIN_FILE_VERSION, UptoBinFileVersion);
- if (!LinkerVersion.empty())
- SHIM_ERR("TAG_LINKER_VERSION Unimplemented\n"); //db.WriteDWord(pdb,
TAG_LINKER_VERSION, LinkerVersion);
-
+ db.WriteDWord(pdb, TAG_LINKER_VERSION, LinkerVersion);
return !!db.EndWriteListTag(pdb, tagid);
}
diff --git a/sdk/tools/xml2sdb/xml2sdb.h b/sdk/tools/xml2sdb/xml2sdb.h
index df9e391b44..9958bc5155 100644
--- a/sdk/tools/xml2sdb/xml2sdb.h
+++ b/sdk/tools/xml2sdb/xml2sdb.h
@@ -123,7 +123,7 @@ struct Layer
struct MatchingFile
{
- MatchingFile() : Size(0), Checksum(0) {;}
+ MatchingFile() : Size(0), Checksum(0), LinkDate(0), LinkerVersion(0) {;}
bool fromXml(XMLHandle dbNode);
bool toSdb(PDB pdb, Database& db);
@@ -137,12 +137,12 @@ struct MatchingFile
std::string ProductVersion;
std::string FileVersion;
std::string BinFileVersion;
- std::string LinkDate;
+ DWORD LinkDate;
std::string VerLanguage;
std::string FileDescription;
std::string OriginalFilename;
std::string UptoBinFileVersion;
- std::string LinkerVersion;
+ DWORD LinkerVersion;
};
struct Exe