add a version number header for release management.

add build number to creport.
This commit is contained in:
Enno Rehling 2014-06-11 07:01:06 -07:00
parent 42a86fc910
commit 9605fe27ae
4 changed files with 8 additions and 6 deletions

View File

@ -322,10 +322,6 @@ static int tolua_faction_create(lua_State * L)
struct locale *loc = find_locale(lang);
faction *f = NULL;
const struct race *frace = rc_find(racename);
if (frace == NULL)
frace = findrace(racename, find_locale("de"));
if (frace == NULL)
frace = findrace(racename, find_locale("en"));
if (frace != NULL) {
f = addfaction(email, NULL, frace, loc, 0);
}

3
src/build.h Normal file
View File

@ -0,0 +1,3 @@
#define VERSION_MAJOR 3
#define VERSION_MINOR 0
#define VERSION_BUILD 675

View File

@ -9,6 +9,7 @@ without prior permission by the authors of Eressea.
#include <platform.h>
#include <kernel/config.h>
#include "build.h"
#include "creport.h"
/* tweakable features */
@ -1496,6 +1497,7 @@ report_computer(const char *filename, report_context * ctx, const char *charset)
fprintf(F, "%d;Basis\n", 36);
fprintf(F, "%d;Runde\n", turn);
fprintf(F, "%d;Zeitalter\n", era);
fprintf(F, "%d;Build\n", VERSION_BUILD);
if (mailto != NULL) {
fprintf(F, "\"%s\";mailto\n", mailto);
fprintf(F, "\"%s\";mailcmd\n", locale_string(f->locale, "mailcmd"));

View File

@ -27,6 +27,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#include "eressea.h"
#include "gmtool.h"
#include "build.h"
#include "bindings.h"
#include "races/races.h"
#include "spells/spells.h"
@ -102,8 +103,8 @@ static int parse_args(int argc, char **argv, int *exitcode)
if (strcmp(argv[i] + 2, "version") == 0) {
printf("\n%s PBEM host\n"
"Copyright (C) 1996-2005 C. Schlittchen, K. Zedel, E. Rehling, H. Peters.\n\n"
"Compilation: " __DATE__ " at " __TIME__ "\nVersion: %d\n\n",
global.gamename, RELEASE_VERSION);
"Compilation: " __DATE__ " at " __TIME__ "\nVersion: %d.%d.%d\n\n",
global.gamename, VERSION_MAJOR, VERSION_MINOR, VERSION_BUILD);
} else if (strcmp(argv[i] + 2, "color") == 0) {
/* force the editor to have colors */
force_color = 1;