root/CS/trunk/include/csver.h @ 33764

Revision 33764, 5.8 KB (checked in by crystal-manage, 6 months ago)

master header files: Automated master header file repair.
Visual-C++ project files: Automated Visual-C++ project file repair.
Texinfo files: Automated Texinfo @node and @menu repair.
Swig Python files: Automated Swig Python file repair.
Swig Perl5 files: Automated Swig Perl5 file repair.
User's Manual: Automated Texinfo to HTML conversion.
csver.h: Automated csver.h regeneration.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1/* ATTENTION: This file is generated from csver.h.template,
2   make changes _there_ instead */
3/*
4    Copyright (C) 1998-2007 by Jorrit Tyberghein
5 
6    This library is free software; you can redistribute it and/or
7    modify it under the terms of the GNU Library General Public
8    License as published by the Free Software Foundation; either
9    version 2 of the License, or (at your option) any later version.
10 
11    This library is distributed in the hope that it will be useful,
12    but WITHOUT ANY WARRANTY; without even the implied warranty of
13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14    Library General Public License for more details.
15 
16    You should have received a copy of the GNU Library General Public
17    License along with this library; if not, write to the Free
18    Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19*/
20
21#ifndef __CS_CSVER_H__
22#define __CS_CSVER_H__
23
24/**\file
25 * Crystal Space Version Information
26 */
27
28// *** NOTE ***
29// Also update CS/configure.ac, CS/docs/texinfo/version.txi, and
30// CS/mk/autoconf/crystal.m4 when updating the version number.
31
32/*
33 * Set if this is an unstable (development) CS version.
34 * Also affects the version number - unstable versions have the RCS revision
35 *  as the 'build' version component.
36 */
37#define CS_VERSION_UNSTABLE
38
39/**
40 * Build version based off SVN revision.
41 * This is not the straight SVN revision - instead it's the difference between
42 * the "last changed" SVN revision and the revision of csver.h.template.
43 * This is done to keep the number in a relatively small range (e.g. Win32
44 * version number components usually only hold 16 bit numbers).
45 * When a version bump happens, csver.h.template is edited to reflect the new
46 * major and minor versions. This will also 'reset' the relative SVN revision
47 * number.
48 *
49 * However, in case csver.h.template is edited for a reason other than a
50 * version bump, CS_RCSREV_OFFSET is provided to allow adjustment
51 * of the relative SVN revision to avoid having it go backwards.
52 * Set the offset to the value reported by `rcsrev print` (BEFORE committing).
53 *
54 * CS_RCSREV_OFFSET should be set to 0 again when bumping the version.
55 *
56 * The relative SVN revision is computed by the script `rcsrev`.
57 */
58//CS_RCSREV_OFFSET 513
59#ifndef CS_VERSION_RCSREV
60#define CS_VERSION_RCSREV       1149
61#endif
62
63/**\name Version number definitions (numeric)
64 * @{ */
65/// Major version
66#define CS_VERSION_NUM_MAJOR    1
67/// Minor version (even are stable versions, odd are development versions)
68#define CS_VERSION_NUM_MINOR    9
69/// Maintenance release
70// @@@ NOTE: set 77 in 1.9 for continuity reasons; reset to 0 on version bump
71#define CS_VERSION_NUM_RELEASE  77
72/**
73 * Build number.
74 * (Actually, a version number dependent on the SVN revision this version was
75 * built off.)
76 */
77#define CS_VERSION_NUM_BUILD    CS_VERSION_RCSREV
78
79/// Encode a version into a single number comparable using <, > etc.
80#define CS_VERSION_NUM_COMPARABLE(Major,Minor,Release,Build)  \
81  ((Major)*10000000 + (Minor)*100000 + (Release)*1000 + (Build))
82/// Current version, encode into a single number comparable using <, > etc.
83#define CS_VERSION_NUM_COMPARABLE_CURRENT                               \
84  CS_VERSION_NUM_COMPARABLE(CS_VERSION_NUM_MAJOR, CS_VERSION_NUM_MINOR, \
85    CS_VERSION_NUM_RELEASE, CS_VERSION_NUM_BUILD)
86/** @} */
87
88/**\name Version number definitions (strings)
89 * @{ */
90/// Major version
91#define CS_VERSION_MAJOR        CS_VER_QUOTE(CS_VERSION_NUM_MAJOR)
92/// Minor version (even are stable versions, odd are development versions)
93#define CS_VERSION_MINOR        CS_VER_QUOTE(CS_VERSION_NUM_MINOR)
94/// Maintenance release
95#define CS_VERSION_RELEASE      CS_VER_QUOTE(CS_VERSION_NUM_RELEASE)
96/// Build number
97#define CS_VERSION_BUILD        CS_VER_QUOTE(CS_VERSION_NUM_BUILD)
98/// Date of release
99#define CS_RELEASE_DATE         CS_VER_QUOTE_(Mon 9-Jun-2008)
100/** @} */
101
102#define CS_VER_QUOTE_(X) #X
103#define CS_VER_QUOTE(X) CS_VER_QUOTE_(X)
104
105#if !defined(CS_PLATFORM_NAME)
106/// Name of the platform CS is compiled for (i.e. Win32)
107define CS_PLATFORM_NAME "MysteryPlatform"
108if defined(CS_COMPILER_GCC)
109warning Unable to identify platform name using CS_PLATFORM_NAME.
110elif defined(CS_COMPILER_MSVC)
111pragma message("Unable to identify platform name using CS_PLATFORM_NAME.")
112endif
113#endif
114#if !defined(CS_PROCESSOR_NAME)
115/// Name of the processor CS is compiled for (i.e. X86)
116define CS_PROCESSOR_NAME "MysteryProcessor"
117if defined(CS_COMPILER_GCC)
118warning Unable to identify processor name using CS_PROCESSOR_NAME.
119elif defined(CS_COMPILER_MSVC)
120pragma message("Unable to identify processor name using CS_PROCESSOR_NAME.")
121endif
122#endif
123#if !defined(CS_COMPILER_NAME)
124/// Name of the compiler CS is compiled with (i.e. GCC)
125define CS_COMPILER_NAME "MysteryCompiler"
126if defined(CS_COMPILER_GCC)
127warning Unable to identify compiler name using CS_COMPILER_NAME.
128elif defined(CS_COMPILER_MSVC)
129pragma message("Unable to identify compiler name using CS_COMPILER_NAME.")
130endif
131#endif
132
133/// A complete version number
134#define CS_VERSION_NUMBER CS_VERSION_MAJOR "." CS_VERSION_MINOR "." \
135  CS_VERSION_RELEASE "." CS_VERSION_BUILD
136/**
137 * A string identifying mutually (binarily) compatible versions.
138 * Stable versions with the same major and minor version are binary compatible
139 * between each other.
140 * Unstable versions are generally not binary compatible, hence builds from
141 * different SVN revisions are treated as incompatible.
142 */
143#ifdef CS_VERSION_UNSTABLE
144  #define CS_VERSION_NUMBER_COMPATIBLE  CS_VERSION_NUMBER
145#else
146  #define CS_VERSION_NUMBER_COMPATIBLE  CS_VERSION_MAJOR "." CS_VERSION_MINOR
147#endif
148
149/// A complete version string, including platform, processor and compiler
150#define CS_VERSION CS_VERSION_NUMBER \
151  " [" CS_PLATFORM_NAME "-" \
152  CS_PROCESSOR_NAME "(" CS_VER_QUOTE(CS_PROCESSOR_SIZE) ")-" \
153  CS_COMPILER_NAME "]"
154
155#endif // __CS_CSVER_H__
Note: See TracBrowser for help on using the browser.