Skip to content

Commit dd0649d

Browse files
ZehMattAaronVanGeffen
authored andcommittedJun 3, 2019
Add version info resource to avoid/reduce false positive virus detection (OpenRCT2#9335)
1 parent cf9e5e1 commit dd0649d

File tree

3 files changed

+45
-1
lines changed

3 files changed

+45
-1
lines changed
 

‎appveyor.yml

+3
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ platform:
1717
- Win32
1818
- x64
1919
configuration: Release
20+
before_build:
21+
- ps: Set-Content -Path '.\resources\version.h' -Value "#define OPENRCT2_FILE_VERSION $($env:APPVEYOR_BUILD_VERSION -replace "\.", ",")"
22+
- ps: Add-Content -Path '.\resources\version.h' -Value "#define OPENRCT2_PRODUCT_VERSION `"$($env:APPVEYOR_BUILD_VERSION)-$($env:APPVEYOR_REPO_COMMIT.Substring(0,10))`""
2023
build:
2124
parallel: true
2225
project: openrct2.proj

‎resources/OpenRCT2.rc

+40-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// Microsoft Visual C++ generated resource script.
22
//
33
#include "resource.h"
4+
#include "version.h"
45

56
#define APSTUDIO_READONLY_SYMBOLS
67
/////////////////////////////////////////////////////////////////////////////
@@ -15,8 +16,45 @@
1516
/////////////////////////////////////////////////////////////////////////////
1617
// English (United Kingdom) resources
1718

18-
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENG)
19+
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) || defined(AFX_TARG_ENG)
1920
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_UK
21+
#pragma code_page(65001)
22+
23+
/////////////////////////////////////////////////////////////////////////////
24+
//
25+
// Version
26+
//
27+
28+
VS_VERSION_INFO VERSIONINFO
29+
FILEVERSION OPENRCT2_FILE_VERSION
30+
PRODUCTVERSION OPENRCT2_FILE_VERSION
31+
FILEFLAGSMASK 0x3fL
32+
#ifdef _DEBUG
33+
FILEFLAGS 0x1L
34+
#else
35+
FILEFLAGS 0x0L
36+
#endif
37+
FILEOS 0x40004L
38+
FILETYPE 0x1L
39+
FILESUBTYPE 0x0L
40+
BEGIN
41+
BLOCK "StringFileInfo"
42+
BEGIN
43+
BLOCK "080904b0"
44+
BEGIN
45+
VALUE "CompanyName", "OpenRCT2 Team"
46+
VALUE "FileDescription", "Main executable for OpenRCT2"
47+
VALUE "FileVersion", OPENRCT2_PRODUCT_VERSION
48+
VALUE "LegalCopyright", "Copyright (c) 2014-2019 OpenRCT2 developers"
49+
VALUE "ProductName", "OpenRCT2"
50+
VALUE "ProductVersion", OPENRCT2_PRODUCT_VERSION
51+
END
52+
END
53+
BLOCK "VarFileInfo"
54+
BEGIN
55+
VALUE "Translation", 0x809, 1200
56+
END
57+
END
2058

2159
#ifdef APSTUDIO_INVOKED
2260
/////////////////////////////////////////////////////////////////////////////
@@ -67,3 +105,4 @@ IDI_ICON ICON "logo\\icon.ico"
67105

68106
/////////////////////////////////////////////////////////////////////////////
69107
#endif // not APSTUDIO_INVOKED
108+

‎resources/version.h

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#define OPENRCT2_FILE_VERSION 0, 0, 0, 0
2+
#define OPENRCT2_PRODUCT_VERSION "0.0.0.0-00000000"

0 commit comments

Comments
 (0)
Please sign in to comment.