diff --git a/src/util.cpp b/src/util.cpp index 45831df..bc19f6b 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -44,7 +44,13 @@ LOG_CATEGORY(Util) namespace p2pool { -const char* VERSION = "v" STR2(P2POOL_VERSION_MAJOR) "." STR2(P2POOL_VERSION_MINOR) " (built" +#if defined(P2POOL_VERSION_PATCH) && (P2POOL_VERSION_PATCH > 0) +#define P2POOL_VERSION_PATCH_STR "." STR2(P2POOL_VERSION_PATCH) +#else +#define P2POOL_VERSION_PATCH_STR "" +#endif + +const char* VERSION = "v" STR2(P2POOL_VERSION_MAJOR) "." STR2(P2POOL_VERSION_MINOR) P2POOL_VERSION_PATCH_STR " (built" #if defined(__clang__) " with clang/" __clang_version__ #elif defined(__GNUC__) diff --git a/src/util.h b/src/util.h index 56ddf20..ffde826 100644 --- a/src/util.h +++ b/src/util.h @@ -36,6 +36,7 @@ namespace p2pool { #define P2POOL_VERSION_MAJOR 3 #define P2POOL_VERSION_MINOR 6 +#define P2POOL_VERSION_PATCH 1 extern const char* VERSION;