Skip to content

Commit

Permalink
Add git commit, original filename to DLL PE header
Browse files Browse the repository at this point in the history
Windows only
  • Loading branch information
RichardTea committed Aug 21, 2019
1 parent bdf6612 commit b8d4ae5
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/res/assimp.rc
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ BEGIN
VALUE "FileDescription", "Open Asset Import Library"
VALUE "FileVersion", VER_FILEVERSION
VALUE "InternalName", "assimp "
VALUE "LegalCopyright", "Copyright (C) 2006-2010"
VALUE "OriginalFilename", "assimpNN.dll"
VALUE "LegalCopyright", "Copyright (C) 2006-2019"
VALUE "OriginalFilename", VER_ORIGINAL_FILENAME_STR
VALUE "ProductName", "Open Asset Import Library"
VALUE "ProductVersion", VER_FILEVERSION_STR
,0
Expand Down
10 changes: 10 additions & 0 deletions revision.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,16 @@
#define STR(x) STR_HELP(x)

#define VER_FILEVERSION VER_MAJOR,VER_MINOR,VER_PATCH,VER_BUILD
#if (GitVersion == 0)
#define VER_FILEVERSION_STR STR(VER_MAJOR) "." STR(VER_MINOR) "." STR(VER_PATCH) "." STR(VER_BUILD)
#else
#define VER_FILEVERSION_STR STR(VER_MAJOR) "." STR(VER_MINOR) "." STR(VER_PATCH) "." STR(VER_BUILD) " (Commit 0x@GIT_COMMIT_HASH@)"
#endif

#ifdef NDEBUG
#define VER_ORIGINAL_FILENAME_STR "assimp@[email protected]"
#else
#define VER_ORIGINAL_FILENAME_STR "assimp@LIBRARY_SUFFIX@@[email protected]"
#endif // NDEBUG

#endif // ASSIMP_REVISION_H_INC

0 comments on commit b8d4ae5

Please sign in to comment.