TrinityCore
GitRevision.cpp
Go to the documentation of this file.
1/*
2 * This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License as published by the
6 * Free Software Foundation; either version 2 of the License, or (at your
7 * option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#include "GitRevision.h"
19#include "revision_data.h"
20
22{
23 return _HASH;
24}
25
27{
28 return _DATE;
29}
30
32{
33 return _BRANCH;
34}
35
37{
38 return _CMAKE_COMMAND;
39}
40
42{
43 return _CMAKE_VERSION;
44}
45
47{
48 return _CMAKE_HOST_SYSTEM;
49}
50
52{
53 return _BUILD_DIRECTORY;
54}
55
57{
58 return _SOURCE_DIRECTORY;
59}
60
62{
63 return _MYSQL_EXECUTABLE;
64}
65
67{
68 return _FULL_DATABASE;
69}
70
72{
73 return _HOTFIXES_DATABASE;
74}
75
76#if TRINITY_PLATFORM == TRINITY_PLATFORM_WINDOWS
77# ifdef _WIN64
78# define TRINITY_PLATFORM_STR "Win64"
79# else
80# define TRINITY_PLATFORM_STR "Win32"
81# endif
82#elif TRINITY_PLATFORM == TRINITY_PLATFORM_APPLE
83# define TRINITY_PLATFORM_STR "MacOSX"
84#elif TRINITY_PLATFORM == TRINITY_PLATFORM_INTEL
85# define TRINITY_PLATFORM_STR "Intel"
86#else // TRINITY_PLATFORM_UNIX
87# define TRINITY_PLATFORM_STR "Unix"
88#endif
89
90#ifndef TRINITY_API_USE_DYNAMIC_LINKING
91# define TRINITY_LINKAGE_TYPE_STR "Static"
92#else
93# define TRINITY_LINKAGE_TYPE_STR "Dynamic"
94#endif
95
97{
98 return "TrinityCore rev. " VER_PRODUCTVERSION_STR
99 " (" TRINITY_PLATFORM_STR ", " _BUILD_DIRECTIVE ", " TRINITY_LINKAGE_TYPE_STR ")";
100}
101
103{
104 return VER_COMPANYNAME_STR;
105}
106
108{
109 return VER_LEGALCOPYRIGHT_STR;
110}
111
113{
114 return VER_FILEVERSION_STR;
115}
116
118{
119 return VER_PRODUCTVERSION_STR;
120}
#define TRINITY_LINKAGE_TYPE_STR
Definition: GitRevision.cpp:91
#define TRINITY_PLATFORM_STR
Definition: GitRevision.cpp:87
TC_COMMON_API char const * GetBranch()
Definition: GitRevision.cpp:31
TC_COMMON_API char const * GetSourceDirectory()
Definition: GitRevision.cpp:56
TC_COMMON_API char const * GetDate()
Definition: GitRevision.cpp:26
TC_COMMON_API char const * GetMySQLExecutable()
Definition: GitRevision.cpp:61
TC_COMMON_API char const * GetBuildDirectory()
Definition: GitRevision.cpp:51
TC_COMMON_API char const * GetHotfixesDatabase()
Definition: GitRevision.cpp:71
TC_COMMON_API char const * GetFileVersionStr()
TC_COMMON_API char const * GetCompanyNameStr()
TC_COMMON_API char const * GetCMakeVersion()
Definition: GitRevision.cpp:41
TC_COMMON_API char const * GetCMakeCommand()
Definition: GitRevision.cpp:36
TC_COMMON_API char const * GetProductVersionStr()
TC_COMMON_API char const * GetLegalCopyrightStr()
TC_COMMON_API char const * GetHostOSVersion()
Definition: GitRevision.cpp:46
TC_COMMON_API char const * GetFullVersion()
Definition: GitRevision.cpp:96
TC_COMMON_API char const * GetFullDatabase()
Definition: GitRevision.cpp:66
TC_COMMON_API char const * GetHash()
Definition: GitRevision.cpp:21