aboutsummaryrefslogtreecommitdiff
path: root/base
diff options
context:
space:
mode:
authorCameron Cawley2018-11-13 18:48:54 +0000
committerDavid Turner2018-11-16 09:14:37 +0000
commit8c6f9e5116dc6f46e166d8a32f9a9b905ea8634c (patch)
tree8212c47cd101e98fadbc1f17baa319bfaf81f5ee /base
parentcf1d0354fe399a21068a59d210becc0cbc162e8e (diff)
downloadscummvm-rg350-8c6f9e5116dc6f46e166d8a32f9a9b905ea8634c.tar.gz
scummvm-rg350-8c6f9e5116dc6f46e166d8a32f9a9b905ea8634c.tar.bz2
scummvm-rg350-8c6f9e5116dc6f46e166d8a32f9a9b905ea8634c.zip
WIN32: Retrieve the version information for the resource script from base/internal_version.h
Diffstat (limited to 'base')
-rw-r--r--base/internal_version.h10
-rw-r--r--base/internal_version.h.in10
-rw-r--r--base/version.cpp12
3 files changed, 20 insertions, 12 deletions
diff --git a/base/internal_version.h b/base/internal_version.h
index 5a4b8ad986..80f839f0e4 100644
--- a/base/internal_version.h
+++ b/base/internal_version.h
@@ -1,5 +1,5 @@
-#ifndef INCLUDED_FROM_BASE_VERSION_CPP
-#error This file may only be included by base/version.cpp
+#if !defined(INCLUDED_FROM_BASE_VERSION_CPP) && !defined(RC_INVOKED)
+#error This file may only be included by base/version.cpp or dists/scummvm.rc
#endif
// Reads revision number from file
@@ -16,4 +16,8 @@
#define SCUMMVM_REVISION
#endif
-#define SCUMMVM_VERSION "2.1.0git" SCUMMVM_REVISION
+#define SCUMMVM_VERSION "2.1.0git"
+
+#define SCUMMVM_VER_MAJOR 2
+#define SCUMMVM_VER_MINOR 1
+#define SCUMMVM_VER_PATCH 0
diff --git a/base/internal_version.h.in b/base/internal_version.h.in
index e2b46f54ce..01a62cd2d0 100644
--- a/base/internal_version.h.in
+++ b/base/internal_version.h.in
@@ -1,5 +1,5 @@
-#ifndef INCLUDED_FROM_BASE_VERSION_CPP
-#error This file may only be included by base/version.cpp
+#if !defined(INCLUDED_FROM_BASE_VERSION_CPP) && !defined(RC_INVOKED)
+#error This file may only be included by base/version.cpp or dists/scummvm.rc
#endif
// Reads revision number from file
@@ -16,4 +16,8 @@
#define SCUMMVM_REVISION
#endif
-#define SCUMMVM_VERSION "@VERSION@" SCUMMVM_REVISION
+#define SCUMMVM_VERSION "@VERSION@"
+
+#define SCUMMVM_VER_MAJOR @VER_MAJOR@
+#define SCUMMVM_VER_MINOR @VER_MINOR@
+#define SCUMMVM_VER_PATCH @VER_PATCH@
diff --git a/base/version.cpp b/base/version.cpp
index 43795294ba..1b9cfe4628 100644
--- a/base/version.cpp
+++ b/base/version.cpp
@@ -55,18 +55,18 @@
* I don't know VC enough to be sure). And of course it must be robust enough
* to properly work in exports (i.e. release tar balls etc.).
*/
-const char *gScummVMVersion = SCUMMVM_VERSION;
+const char *gScummVMVersion = SCUMMVM_VERSION SCUMMVM_REVISION;
#ifdef __amigaos4__
-static const char *version_cookie __attribute__((used)) = "$VER: ScummVM " SCUMMVM_VERSION " (" AMIGA_DATE ")";
+static const char *version_cookie __attribute__((used)) = "$VER: ScummVM " SCUMMVM_VERSION SCUMMVM_REVISION " (" AMIGA_DATE ")";
#endif
#ifdef __PLAYSTATION2__
const char *gScummVMBuildDate = "Git Master"; /* ScummVM Git Master */
-const char *gScummVMVersionDate = SCUMMVM_VERSION " - PlayStation2";
-const char *gScummVMFullVersion = "ScummVM " SCUMMVM_VERSION " - PlayStation2";
+const char *gScummVMVersionDate = SCUMMVM_VERSION SCUMMVM_REVISION " - PlayStation2";
+const char *gScummVMFullVersion = "ScummVM " SCUMMVM_VERSION SCUMMVM_REVISION " - PlayStation2";
#else
const char *gScummVMBuildDate = __DATE__ " " __TIME__;
-const char *gScummVMVersionDate = SCUMMVM_VERSION " (" __DATE__ " " __TIME__ ")";
-const char *gScummVMFullVersion = "ScummVM " SCUMMVM_VERSION " (" __DATE__ " " __TIME__ ")";
+const char *gScummVMVersionDate = SCUMMVM_VERSION SCUMMVM_REVISION " (" __DATE__ " " __TIME__ ")";
+const char *gScummVMFullVersion = "ScummVM " SCUMMVM_VERSION SCUMMVM_REVISION " (" __DATE__ " " __TIME__ ")";
#endif
const char *gScummVMFeatures = ""
#ifdef TAINTED_BUILD