diff options
author | Naram Qashat <cyberbotx@cyberbotx.com> | 2010-06-28 01:28:51 -0400 |
---|---|---|
committer | Naram Qashat <cyberbotx@cyberbotx.com> | 2010-06-28 01:28:51 -0400 |
commit | 85b07a94d7d0c54e221dbbb8333870beb47bb3ac (patch) | |
tree | 7a3300c7fb0bb57e40f3f226b2c1d350384ab864 /src/main.cpp | |
parent | 2e4099e9f2bdcfab963c1e86a3f02d6b3c1b0048 (diff) |
Fix version system so it doesn't cause the entire build tree to get rebuilt just because version.h gets regenerated, thanks to Adam for initial patch.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index c00b3a8f0..e1b3c1ee3 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -26,6 +26,7 @@ #include "services.h" #include "timers.h" #include "modules.h" +#include "version.h" // getrlimit. #ifndef _WIN32 @@ -570,3 +571,13 @@ int main(int ac, char **av, char **envp) return 0; } + +inline std::string Anope::Version() +{ + return stringify(VERSION_MAJOR) + "." + stringify(VERSION_MINOR) + "." + stringify(VERSION_PATCH) + VERSION_EXTRA + " (" + stringify(VERSION_BUILD) + ")"; +} + +inline std::string Anope::Build() +{ + return std::string("build #") + stringify(BUILD) + ", compiled " + compiled; +} |