mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2025-01-30 20:10:41 +00:00
- Use gitinfo.h instead of svnrevision.h for versioning.
- Use functions in gitinfo.cpp to retrieve the strings from gitinfo.h so that changes to gitinfo.h only require recompiling one file instead of several.
This commit is contained in:
parent
fece189bdb
commit
98ac224e53
15 changed files with 139 additions and 72 deletions
|
@ -483,12 +483,12 @@ if( BACKPATCH )
|
||||||
add_definitions( -DBACKPATCH )
|
add_definitions( -DBACKPATCH )
|
||||||
endif( BACKPATCH )
|
endif( BACKPATCH )
|
||||||
|
|
||||||
# Update svnrevision.h
|
# Update gitinfo.h
|
||||||
|
|
||||||
get_target_property( UPDATEREVISION_EXE updaterevision LOCATION )
|
get_target_property( UPDATEREVISION_EXE updaterevision LOCATION )
|
||||||
|
|
||||||
add_custom_target( revision_check ALL
|
add_custom_target( revision_check ALL
|
||||||
COMMAND ${UPDATEREVISION_EXE} . src/svnrevision.h
|
COMMAND ${UPDATEREVISION_EXE} . src/gitinfo.h
|
||||||
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
|
||||||
DEPENDS updaterevision )
|
DEPENDS updaterevision )
|
||||||
|
|
||||||
|
|
|
@ -395,7 +395,7 @@ CCMD (take)
|
||||||
|
|
||||||
CCMD (gameversion)
|
CCMD (gameversion)
|
||||||
{
|
{
|
||||||
Printf ("%s : " __DATE__ "\n", DOTVERSIONSTR);
|
Printf ("%s @ %s\nCommit %s", GetVersionString(), GetGitTime(), GetGitHash());
|
||||||
}
|
}
|
||||||
|
|
||||||
CCMD (print)
|
CCMD (print)
|
||||||
|
|
|
@ -1167,9 +1167,9 @@ void C_DrawConsole (bool hw2d)
|
||||||
if (ConBottom >= 12)
|
if (ConBottom >= 12)
|
||||||
{
|
{
|
||||||
screen->DrawText (ConFont, CR_ORANGE, SCREENWIDTH - 8 -
|
screen->DrawText (ConFont, CR_ORANGE, SCREENWIDTH - 8 -
|
||||||
ConFont->StringWidth ("v" DOTVERSIONSTR),
|
ConFont->StringWidth (GetVersionString()),
|
||||||
ConBottom - ConFont->GetHeight() - 4,
|
ConBottom - ConFont->GetHeight() - 4,
|
||||||
"v" DOTVERSIONSTR, TAG_DONE);
|
GetVersionString(), TAG_DONE);
|
||||||
if (TickerMax)
|
if (TickerMax)
|
||||||
{
|
{
|
||||||
char tickstr[256];
|
char tickstr[256];
|
||||||
|
|
|
@ -2058,6 +2058,8 @@ static void PutSavePic (FILE *file, int width, int height)
|
||||||
|
|
||||||
void G_DoSaveGame (bool okForQuicksave, FString filename, const char *description)
|
void G_DoSaveGame (bool okForQuicksave, FString filename, const char *description)
|
||||||
{
|
{
|
||||||
|
char buf[100];
|
||||||
|
|
||||||
// Do not even try, if we're not in a level. (Can happen after
|
// Do not even try, if we're not in a level. (Can happen after
|
||||||
// a demo finishes playback.)
|
// a demo finishes playback.)
|
||||||
if (lines == NULL || sectors == NULL)
|
if (lines == NULL || sectors == NULL)
|
||||||
|
@ -2084,7 +2086,8 @@ void G_DoSaveGame (bool okForQuicksave, FString filename, const char *descriptio
|
||||||
|
|
||||||
SaveVersion = SAVEVER;
|
SaveVersion = SAVEVER;
|
||||||
PutSavePic (stdfile, SAVEPICWIDTH, SAVEPICHEIGHT);
|
PutSavePic (stdfile, SAVEPICWIDTH, SAVEPICHEIGHT);
|
||||||
M_AppendPNGText (stdfile, "Software", "ZDoom " DOTVERSIONSTR);
|
mysnprintf(buf, countof(buf), GAMENAME " %s", GetVersionString());
|
||||||
|
M_AppendPNGText (stdfile, "Software", buf);
|
||||||
M_AppendPNGText (stdfile, "Engine", GAMESIG);
|
M_AppendPNGText (stdfile, "Engine", GAMESIG);
|
||||||
M_AppendPNGText (stdfile, "ZDoom Save Version", SAVESIG);
|
M_AppendPNGText (stdfile, "ZDoom Save Version", SAVESIG);
|
||||||
M_AppendPNGText (stdfile, "Title", description);
|
M_AppendPNGText (stdfile, "Title", description);
|
||||||
|
|
|
@ -225,7 +225,7 @@ FGameConfigFile::~FGameConfigFile ()
|
||||||
|
|
||||||
void FGameConfigFile::WriteCommentHeader (FILE *file) const
|
void FGameConfigFile::WriteCommentHeader (FILE *file) const
|
||||||
{
|
{
|
||||||
fprintf (file, "# This file was generated by " GAMENAME " " DOTVERSIONSTR " on %s\n", myasctime());
|
fprintf (file, "# This file was generated by " GAMENAME " %s on %s\n", GetVersionString(), myasctime());
|
||||||
}
|
}
|
||||||
|
|
||||||
void FGameConfigFile::MigrateStub (const char *pathname, FConfigFile *config, void *userdata)
|
void FGameConfigFile::MigrateStub (const char *pathname, FConfigFile *config, void *userdata)
|
||||||
|
|
65
src/gitinfo.cpp
Normal file
65
src/gitinfo.cpp
Normal file
|
@ -0,0 +1,65 @@
|
||||||
|
/*
|
||||||
|
** gitinfo.cpp
|
||||||
|
** Returns strings from gitinfo.h.
|
||||||
|
**
|
||||||
|
**---------------------------------------------------------------------------
|
||||||
|
** Copyright 2013 Randy Heit
|
||||||
|
** All rights reserved.
|
||||||
|
**
|
||||||
|
** Redistribution and use in source and binary forms, with or without
|
||||||
|
** modification, are permitted provided that the following conditions
|
||||||
|
** are met:
|
||||||
|
**
|
||||||
|
** 1. Redistributions of source code must retain the above copyright
|
||||||
|
** notice, this list of conditions and the following disclaimer.
|
||||||
|
** 2. Redistributions in binary form must reproduce the above copyright
|
||||||
|
** notice, this list of conditions and the following disclaimer in the
|
||||||
|
** documentation and/or other materials provided with the distribution.
|
||||||
|
** 3. The name of the author may not be used to endorse or promote products
|
||||||
|
** derived from this software without specific prior written permission.
|
||||||
|
**
|
||||||
|
** THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
|
||||||
|
** IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
|
||||||
|
** OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
||||||
|
** IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||||
|
** INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
|
||||||
|
** NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||||
|
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||||
|
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||||
|
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||||
|
** THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
**---------------------------------------------------------------------------
|
||||||
|
**
|
||||||
|
** This file is just here so that when gitinfo.h changes, only one source
|
||||||
|
** file needs to be recompiled.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "gitinfo.h"
|
||||||
|
#include "version.h"
|
||||||
|
|
||||||
|
const char *GetGitDescription()
|
||||||
|
{
|
||||||
|
return GIT_DESCRIPTION;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *GetGitHash()
|
||||||
|
{
|
||||||
|
return GIT_HASH;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *GetGitTime()
|
||||||
|
{
|
||||||
|
return GIT_TIME;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *GetVersionString()
|
||||||
|
{
|
||||||
|
if (GetGitDescription()[0] == '\0')
|
||||||
|
{
|
||||||
|
return VERSIONSTR;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return GIT_DESCRIPTION;
|
||||||
|
}
|
||||||
|
}
|
|
@ -632,8 +632,10 @@ void WritePCXfile (FILE *file, const BYTE *buffer, const PalEntry *palette,
|
||||||
void WritePNGfile (FILE *file, const BYTE *buffer, const PalEntry *palette,
|
void WritePNGfile (FILE *file, const BYTE *buffer, const PalEntry *palette,
|
||||||
ESSType color_type, int width, int height, int pitch)
|
ESSType color_type, int width, int height, int pitch)
|
||||||
{
|
{
|
||||||
|
char software[100];
|
||||||
|
mysnprintf(software, countof(software), GAMENAME " %s", GetVersionString());
|
||||||
if (!M_CreatePNG (file, buffer, palette, color_type, width, height, pitch) ||
|
if (!M_CreatePNG (file, buffer, palette, color_type, width, height, pitch) ||
|
||||||
!M_AppendPNGText (file, "Software", GAMENAME DOTVERSIONSTR) ||
|
!M_AppendPNGText (file, "Software", software) ||
|
||||||
!M_FinishPNG (file))
|
!M_FinishPNG (file))
|
||||||
{
|
{
|
||||||
Printf ("Could not create screenshot.\n");
|
Printf ("Could not create screenshot.\n");
|
||||||
|
|
|
@ -150,7 +150,7 @@ static int DoomSpecificInfo (char *buffer, char *end)
|
||||||
int i, p;
|
int i, p;
|
||||||
|
|
||||||
p = 0;
|
p = 0;
|
||||||
p += snprintf (buffer+p, size-p, GAMENAME" version " DOTVERSIONSTR " (" __DATE__ ")\n");
|
p += snprintf (buffer+p, size-p, GAMENAME" version %s (%s)\n", GetVersionString(), GetGitHash());
|
||||||
#ifdef __VERSION__
|
#ifdef __VERSION__
|
||||||
p += snprintf (buffer+p, size-p, "Compiler version: %s\n", __VERSION__);
|
p += snprintf (buffer+p, size-p, "Compiler version: %s\n", __VERSION__);
|
||||||
#endif
|
#endif
|
||||||
|
@ -248,8 +248,8 @@ int main (int argc, char **argv)
|
||||||
}
|
}
|
||||||
#endif // !__APPLE__
|
#endif // !__APPLE__
|
||||||
|
|
||||||
printf(GAMENAME" v%s - SVN revision %s - SDL version\nCompiled on %s\n",
|
printf(GAMENAME" %s - %s - SDL version\nCompiled on %s\n",
|
||||||
DOTVERSIONSTR_NOREV,SVN_REVISION_STRING,__DATE__);
|
GetVersionString(), GetGitTime(), __DATE__);
|
||||||
|
|
||||||
seteuid (getuid ());
|
seteuid (getuid ());
|
||||||
std::set_new_handler (NewFailure);
|
std::set_new_handler (NewFailure);
|
||||||
|
@ -284,7 +284,9 @@ int main (int argc, char **argv)
|
||||||
printf("\n");
|
printf("\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_WM_SetCaption (GAMESIG " " DOTVERSIONSTR " (" __DATE__ ")", NULL);
|
char caption[100];
|
||||||
|
mysnprintf(caption, countof(caption), GAMESIG " %s (%s)", GetVersionString(), GetGitTime());
|
||||||
|
SDL_WM_SetCaption(caption);
|
||||||
|
|
||||||
#ifdef __APPLE__
|
#ifdef __APPLE__
|
||||||
|
|
||||||
|
|
|
@ -483,10 +483,12 @@ int I_PickIWad_Gtk (WadStuff *wads, int numwads, bool showwin, int defaultiwad)
|
||||||
GtkTreeIter iter, defiter;
|
GtkTreeIter iter, defiter;
|
||||||
int close_style = 0;
|
int close_style = 0;
|
||||||
int i;
|
int i;
|
||||||
|
char caption[100];
|
||||||
|
|
||||||
// Create the dialog window.
|
// Create the dialog window.
|
||||||
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
|
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
|
||||||
gtk_window_set_title (GTK_WINDOW(window), GAMESIG " " DOTVERSIONSTR ": Select an IWAD to use");
|
mysnprintf(caption, countof(caption), GAMESIG " %s: Select an IWAD to use", GetVersionString());
|
||||||
|
gtk_window_set_title (GTK_WINDOW(window), caption);
|
||||||
gtk_window_set_position (GTK_WINDOW(window), GTK_WIN_POS_CENTER);
|
gtk_window_set_position (GTK_WINDOW(window), GTK_WIN_POS_CENTER);
|
||||||
gtk_container_set_border_width (GTK_CONTAINER(window), 10);
|
gtk_container_set_border_width (GTK_CONTAINER(window), 10);
|
||||||
g_signal_connect (window, "delete_event", G_CALLBACK(gtk_main_quit), NULL);
|
g_signal_connect (window, "delete_event", G_CALLBACK(gtk_main_quit), NULL);
|
||||||
|
@ -614,7 +616,8 @@ int I_PickIWad (WadStuff *wads, int numwads, bool showwin, int defaultiwad)
|
||||||
const char *str;
|
const char *str;
|
||||||
if((str=getenv("KDE_FULL_SESSION")) && strcmp(str, "true") == 0)
|
if((str=getenv("KDE_FULL_SESSION")) && strcmp(str, "true") == 0)
|
||||||
{
|
{
|
||||||
FString cmd("kdialog --title \""GAMESIG" "DOTVERSIONSTR": Select an IWAD to use\""
|
FString cmd("kdialog --title \""GAMESIG" ");
|
||||||
|
cmd << GetVersionString() << ": Select an IWAD to use\""
|
||||||
" --menu \"ZDoom found more than one IWAD\n"
|
" --menu \"ZDoom found more than one IWAD\n"
|
||||||
"Select from the list below to determine which one to use:\"");
|
"Select from the list below to determine which one to use:\"");
|
||||||
|
|
||||||
|
|
|
@ -34,21 +34,18 @@
|
||||||
#ifndef __VERSION_H__
|
#ifndef __VERSION_H__
|
||||||
#define __VERSION_H__
|
#define __VERSION_H__
|
||||||
|
|
||||||
// The svnrevision.h is automatically updated to grab the revision of
|
const char *GetGitDescription();
|
||||||
// of the current source tree so that it can be included with version numbers.
|
const char *GetGitHash();
|
||||||
#include "svnrevision.h"
|
const char *GetGitTime();
|
||||||
|
const char *GetVersionString();
|
||||||
|
|
||||||
/** Lots of different version numbers **/
|
/** Lots of different version numbers **/
|
||||||
|
|
||||||
#define DOTVERSIONSTR_NOREV "2.7.0"
|
#define VERSIONSTR "2.7.0"
|
||||||
|
|
||||||
// The version string the user actually sees.
|
|
||||||
#define DOTVERSIONSTR DOTVERSIONSTR_NOREV " (r" SVN_REVISION_STRING ")"
|
|
||||||
|
|
||||||
// The version as seen in the Windows resource
|
// The version as seen in the Windows resource
|
||||||
#define RC_FILEVERSION 2,7,0,SVN_REVISION_NUMBER
|
#define RC_FILEVERSION 2,7,0,0
|
||||||
#define RC_PRODUCTVERSION 2,7,0,0
|
#define RC_PRODUCTVERSION 2,7,0,0
|
||||||
#define RC_FILEVERSION2 DOTVERSIONSTR
|
|
||||||
#define RC_PRODUCTVERSION2 "2.7"
|
#define RC_PRODUCTVERSION2 "2.7"
|
||||||
|
|
||||||
// Version identifier for network games.
|
// Version identifier for network games.
|
||||||
|
@ -75,36 +72,15 @@
|
||||||
// SAVESIG should match SAVEVER.
|
// SAVESIG should match SAVEVER.
|
||||||
|
|
||||||
// MINSAVEVER is the minimum level snapshot version that can be loaded.
|
// MINSAVEVER is the minimum level snapshot version that can be loaded.
|
||||||
#define MINSAVEVER 3100
|
#define MINSAVEVER 3100
|
||||||
|
|
||||||
#if SVN_REVISION_NUMBER < MINSAVEVER
|
// Use 4500 as the base git save version, since it's higher than the
|
||||||
// If we don't know the current revision write something very high to ensure that
|
// SVN revision ever got.
|
||||||
// the reesulting executable can read its own savegames but no regular engine can.
|
#define SAVEVER 4500
|
||||||
#define SAVEVER 999999
|
|
||||||
#define SAVESIG MakeSaveSig()
|
#define SAVEVERSTRINGIFY2(x) str(x)
|
||||||
static inline const char *MakeSaveSig()
|
#define SAVEVERSTRINGIFY(x) #x
|
||||||
{
|
#define SAVESIG "ZDOOMSAVE" SAVEVERSTRINGIFY(SAVEVER)
|
||||||
static char foo[] = { 'Z','D','O','O','M','S','A','V','E',
|
|
||||||
#if SAVEVER > 99999
|
|
||||||
'0' + (SAVEVER / 100000),
|
|
||||||
#endif
|
|
||||||
#if SAVEVER > 9999
|
|
||||||
'0' + ((SAVEVER / 10000) % 10),
|
|
||||||
#endif
|
|
||||||
#if SAVEVER > 999
|
|
||||||
'0' + ((SAVEVER / 1000) % 10),
|
|
||||||
#endif
|
|
||||||
'0' + ((SAVEVER / 100) % 10),
|
|
||||||
'0' + ((SAVEVER / 10) % 10),
|
|
||||||
'0' + (SAVEVER % 10),
|
|
||||||
'\0'
|
|
||||||
};
|
|
||||||
return foo;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
#define SAVEVER SVN_REVISION_NUMBER
|
|
||||||
#define SAVESIG "ZDOOMSAVE"SVN_REVISION_STRING
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// This is so that derivates can use the same savegame versions without worrying about engine compatibility
|
// This is so that derivates can use the same savegame versions without worrying about engine compatibility
|
||||||
#define GAMESIG "ZDOOM"
|
#define GAMESIG "ZDOOM"
|
||||||
|
|
|
@ -128,7 +128,7 @@ RtlVirtualUnwind (
|
||||||
// If you are working on your own modified version of ZDoom, change
|
// If you are working on your own modified version of ZDoom, change
|
||||||
// the last part of the UPLOAD_AGENT (between parentheses) to your
|
// the last part of the UPLOAD_AGENT (between parentheses) to your
|
||||||
// own program's name. e.g. (Skulltag) or (ZDaemon) or (ZDoomFu)
|
// own program's name. e.g. (Skulltag) or (ZDaemon) or (ZDoomFu)
|
||||||
#define UPLOAD_AGENT "ZDoom/" DOTVERSIONSTR " (" GAMESIG ")"
|
#define UPLOAD_AGENT "ZDoom/" VERSIONSTR " (" GAMESIG ")"
|
||||||
|
|
||||||
// Time, in milliseconds, to wait for a send() or recv() to complete.
|
// Time, in milliseconds, to wait for a send() or recv() to complete.
|
||||||
#define TIMEOUT 60000
|
#define TIMEOUT 60000
|
||||||
|
|
|
@ -95,8 +95,6 @@
|
||||||
#define X64 ""
|
#define X64 ""
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define WINDOW_TITLE GAMESIG " " DOTVERSIONSTR X64 " (" __DATE__ ")"
|
|
||||||
|
|
||||||
// The maximum number of functions that can be registered with atterm.
|
// The maximum number of functions that can be registered with atterm.
|
||||||
#define MAX_TERMS 64
|
#define MAX_TERMS 64
|
||||||
|
|
||||||
|
@ -714,7 +712,9 @@ void ShowErrorPane(const char *text)
|
||||||
}
|
}
|
||||||
if (text != NULL)
|
if (text != NULL)
|
||||||
{
|
{
|
||||||
SetWindowText (Window, "Fatal Error - " WINDOW_TITLE);
|
char caption[100];
|
||||||
|
mysnprintf(caption, countof(caption), "Fatal Error - "GAMESIG" %s "X64" (%s)", GetVersionString(), GetGitTime());
|
||||||
|
SetWindowText (Window, caption);
|
||||||
ErrorIcon = CreateWindowEx (WS_EX_NOPARENTNOTIFY, "STATIC", NULL, WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | SS_OWNERDRAW, 0, 0, 0, 0, Window, NULL, g_hInst, NULL);
|
ErrorIcon = CreateWindowEx (WS_EX_NOPARENTNOTIFY, "STATIC", NULL, WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS | SS_OWNERDRAW, 0, 0, 0, 0, Window, NULL, g_hInst, NULL);
|
||||||
if (ErrorIcon != NULL)
|
if (ErrorIcon != NULL)
|
||||||
{
|
{
|
||||||
|
@ -945,10 +945,12 @@ void DoMain (HINSTANCE hInstance)
|
||||||
I_FatalError ("Could not register window class");
|
I_FatalError ("Could not register window class");
|
||||||
|
|
||||||
/* create window */
|
/* create window */
|
||||||
|
char caption[100];
|
||||||
|
mysnprintf(caption, countof(caption), ""GAMESIG" %s "X64" (%s)", GetVersionString(), GetGitTime());
|
||||||
Window = CreateWindowEx(
|
Window = CreateWindowEx(
|
||||||
WS_EX_APPWINDOW,
|
WS_EX_APPWINDOW,
|
||||||
(LPCTSTR)WinClassName,
|
(LPCTSTR)WinClassName,
|
||||||
(LPCTSTR)WINDOW_TITLE,
|
(LPCTSTR)caption,
|
||||||
WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_CLIPCHILDREN,
|
WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_CLIPCHILDREN,
|
||||||
x, y, width, height,
|
x, y, width, height,
|
||||||
(HWND) NULL,
|
(HWND) NULL,
|
||||||
|
@ -1045,7 +1047,7 @@ void DoomSpecificInfo (char *buffer, size_t bufflen)
|
||||||
char *const buffend = buffer + bufflen - 2; // -2 for CRLF at end
|
char *const buffend = buffer + bufflen - 2; // -2 for CRLF at end
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
buffer += mysnprintf (buffer, buffend - buffer, "ZDoom version " DOTVERSIONSTR " (" __DATE__ ")\r\n");
|
buffer += mysnprintf (buffer, buffend - buffer, GAMENAME " version %s (%s)", GetVersionString(), GetGitHash());
|
||||||
buffer += mysnprintf (buffer, buffend - buffer, "\r\nCommand line: %s\r\n", GetCommandLine());
|
buffer += mysnprintf (buffer, buffend - buffer, "\r\nCommand line: %s\r\n", GetCommandLine());
|
||||||
|
|
||||||
for (i = 0; (arg = Wads.GetWadName (i)) != NULL; ++i)
|
for (i = 0; (arg = Wads.GetWadName (i)) != NULL; ++i)
|
||||||
|
|
|
@ -1095,7 +1095,7 @@ BOOL CALLBACK IWADBoxCallback(HWND hDlg, UINT message, WPARAM wParam, LPARAM lPa
|
||||||
FString newlabel;
|
FString newlabel;
|
||||||
|
|
||||||
GetWindowText(hDlg, label, countof(label));
|
GetWindowText(hDlg, label, countof(label));
|
||||||
newlabel.Format(GAMESIG " " DOTVERSIONSTR_NOREV ": %s", label);
|
newlabel.Format(GAMESIG " %s: %s", GetVersionString(), label);
|
||||||
SetWindowText(hDlg, newlabel.GetChars());
|
SetWindowText(hDlg, newlabel.GetChars());
|
||||||
}
|
}
|
||||||
// Populate the list with all the IWADs found
|
// Populate the list with all the IWADs found
|
||||||
|
|
|
@ -8,7 +8,8 @@
|
||||||
// Generated from the TEXTINCLUDE 2 resource.
|
// Generated from the TEXTINCLUDE 2 resource.
|
||||||
//
|
//
|
||||||
#include "afxres.h"
|
#include "afxres.h"
|
||||||
#include "../version.h"
|
#include "../version.h"
|
||||||
|
#include "../gitinfo.h"
|
||||||
|
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
#undef APSTUDIO_READONLY_SYMBOLS
|
#undef APSTUDIO_READONLY_SYMBOLS
|
||||||
|
@ -36,7 +37,8 @@ END
|
||||||
2 TEXTINCLUDE
|
2 TEXTINCLUDE
|
||||||
BEGIN
|
BEGIN
|
||||||
"#include ""afxres.h""\r\n"
|
"#include ""afxres.h""\r\n"
|
||||||
"#include ""../version.h""\r\0"
|
"#include ""../version.h""\r\r\n"
|
||||||
|
"#include ""../gitinfo.h""\r\0"
|
||||||
END
|
END
|
||||||
|
|
||||||
3 TEXTINCLUDE
|
3 TEXTINCLUDE
|
||||||
|
@ -49,6 +51,7 @@ BEGIN
|
||||||
"//\r\n"
|
"//\r\n"
|
||||||
"// Version\r\n"
|
"// Version\r\n"
|
||||||
"//\r\n"
|
"//\r\n"
|
||||||
|
"#define RC_FILEVERSION2 GIT_DESCRIPTION\r\n"
|
||||||
"\r\n"
|
"\r\n"
|
||||||
"VS_VERSION_INFO VERSIONINFO\r\n"
|
"VS_VERSION_INFO VERSIONINFO\r\n"
|
||||||
" FILEVERSION RC_FILEVERSION\r\n"
|
" FILEVERSION RC_FILEVERSION\r\n"
|
||||||
|
@ -72,8 +75,8 @@ BEGIN
|
||||||
" VALUE ""FileDescription"", ""ZDoom""\r\n"
|
" VALUE ""FileDescription"", ""ZDoom""\r\n"
|
||||||
" VALUE ""FileVersion"", RC_FILEVERSION2\r\n"
|
" VALUE ""FileVersion"", RC_FILEVERSION2\r\n"
|
||||||
" VALUE ""InternalName"", ""ZDoom""\r\n"
|
" VALUE ""InternalName"", ""ZDoom""\r\n"
|
||||||
" VALUE ""LegalCopyright"", ""Copyright \u00A9 1993-1996 id Software, 1998-2010 Randy Heit, 2002-2010 Christoph Oelckers, et al.""\r\n"
|
" VALUE ""LegalCopyright"", ""Copyright \\u00A9 1993-1996 id Software, 1998-2010 Randy Heit, 2002-2010 Christoph Oelckers, et al.""\r\n"
|
||||||
" VALUE ""LegalTrademarks"", ""Doom® is a Registered Trademark of id Software, Inc.""\r\n"
|
" VALUE ""LegalTrademarks"", ""DoomR is a Registered Trademark of id Software, Inc.""\r\n"
|
||||||
" VALUE ""OriginalFilename"", ""zdoom.exe""\r\n"
|
" VALUE ""OriginalFilename"", ""zdoom.exe""\r\n"
|
||||||
" VALUE ""ProductName"", ""ZDoom""\r\n"
|
" VALUE ""ProductName"", ""ZDoom""\r\n"
|
||||||
" VALUE ""ProductVersion"", RC_PRODUCTVERSION2\r\n"
|
" VALUE ""ProductVersion"", RC_PRODUCTVERSION2\r\n"
|
||||||
|
@ -83,7 +86,7 @@ BEGIN
|
||||||
" BEGIN\r\n"
|
" BEGIN\r\n"
|
||||||
" VALUE ""Translation"", 0x409, 1200\r\n"
|
" VALUE ""Translation"", 0x409, 1200\r\n"
|
||||||
" END\r\n"
|
" END\r\n"
|
||||||
"END\0"
|
"EN\0"
|
||||||
END
|
END
|
||||||
|
|
||||||
#endif // APSTUDIO_INVOKED
|
#endif // APSTUDIO_INVOKED
|
||||||
|
@ -468,6 +471,7 @@ IDB_DEADGUY BITMAP "deadguy.bmp"
|
||||||
//
|
//
|
||||||
// Version
|
// Version
|
||||||
//
|
//
|
||||||
|
#define RC_FILEVERSION2 GIT_DESCRIPTION
|
||||||
|
|
||||||
VS_VERSION_INFO VERSIONINFO
|
VS_VERSION_INFO VERSIONINFO
|
||||||
FILEVERSION RC_FILEVERSION
|
FILEVERSION RC_FILEVERSION
|
||||||
|
@ -491,8 +495,8 @@ BEGIN
|
||||||
VALUE "FileDescription", "ZDoom"
|
VALUE "FileDescription", "ZDoom"
|
||||||
VALUE "FileVersion", RC_FILEVERSION2
|
VALUE "FileVersion", RC_FILEVERSION2
|
||||||
VALUE "InternalName", "ZDoom"
|
VALUE "InternalName", "ZDoom"
|
||||||
VALUE "LegalCopyright", "Copyright © 1993-1996 id Software, 1998-2013 Randy Heit, Christoph Oelckers, Braden Obrzut, et al."
|
VALUE "LegalCopyright", "Copyright \u00A9 1993-1996 id Software, 1998-2010 Randy Heit, 2002-2010 Christoph Oelckers, et al."
|
||||||
VALUE "LegalTrademarks", "Doom® is a Registered Trademark of id Software, Inc."
|
VALUE "LegalTrademarks", "DoomR is a Registered Trademark of id Software, Inc."
|
||||||
VALUE "OriginalFilename", "zdoom.exe"
|
VALUE "OriginalFilename", "zdoom.exe"
|
||||||
VALUE "ProductName", "ZDoom"
|
VALUE "ProductName", "ZDoom"
|
||||||
VALUE "ProductVersion", RC_PRODUCTVERSION2
|
VALUE "ProductVersion", RC_PRODUCTVERSION2
|
||||||
|
|
22
zdoom.vcproj
22
zdoom.vcproj
|
@ -28,8 +28,8 @@
|
||||||
>
|
>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking svnrevision.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine=""$(OutDir)\updaterevision.exe" src src/svnrevision.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -151,7 +151,8 @@
|
||||||
>
|
>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
CommandLine="$(OutDir)\updaterevision.exe src src/svnrevision.h"
|
Description="Checking gitinfo.h..."
|
||||||
|
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -263,8 +264,8 @@
|
||||||
>
|
>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
Description="Checking svnrevision.h..."
|
Description="Checking gitinfo.h..."
|
||||||
CommandLine="$(OutDir)\updaterevision.exe src src/svnrevision.h"
|
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -370,7 +371,8 @@
|
||||||
>
|
>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCPreBuildEventTool"
|
Name="VCPreBuildEventTool"
|
||||||
CommandLine="$(OutDir)\updaterevision.exe src src/svnrevision.h"
|
Description="Checking gitinfo.h..."
|
||||||
|
CommandLine=""$(OutDir)\updaterevision.exe" src src/gitinfo.h"
|
||||||
/>
|
/>
|
||||||
<Tool
|
<Tool
|
||||||
Name="VCCustomBuildTool"
|
Name="VCCustomBuildTool"
|
||||||
|
@ -652,6 +654,10 @@
|
||||||
RelativePath=".\src\gi.cpp"
|
RelativePath=".\src\gi.cpp"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\gitinfo.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath=".\src\hu_scores.cpp"
|
RelativePath=".\src\hu_scores.cpp"
|
||||||
>
|
>
|
||||||
|
@ -2417,6 +2423,10 @@
|
||||||
<Filter
|
<Filter
|
||||||
Name="Versioning"
|
Name="Versioning"
|
||||||
>
|
>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\baseversion.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath=".\src\version.h"
|
RelativePath=".\src\version.h"
|
||||||
>
|
>
|
||||||
|
|
Loading…
Reference in a new issue