diff options
author | Peter Powell <petpow@saberuk.com> | 2019-05-13 15:22:14 +0100 |
---|---|---|
committer | Peter Powell <petpow@saberuk.com> | 2019-05-13 15:22:14 +0100 |
commit | 510f747854b17f64c2f597a4bd5743763fb518f4 (patch) | |
tree | 5ce63a147f5ca8afde667b97a438cb3b3a68d51e /make/template | |
parent | 319218db85de50df01f0310f241a336e472d68fd (diff) |
Clean up and document the config header file.
Diffstat (limited to 'make/template')
-rw-r--r-- | make/template/config.h | 31 |
1 files changed, 27 insertions, 4 deletions
diff --git a/make/template/config.h b/make/template/config.h index 2fbf5c564..a28f5e878 100644 --- a/make/template/config.h +++ b/make/template/config.h @@ -19,17 +19,40 @@ #pragma once -#define INSPIRCD_BRANCH "InspIRCd-@VERSION_MAJOR@" -#define INSPIRCD_VERSION "InspIRCd-@VERSION_FULL@" +/*** The branch version that is shown to unprivileged users. */ +#define INSPIRCD_BRANCH "InspIRCd-@VERSION_MAJOR@" +/*** The full version that is shown to privileged users. */ +#define INSPIRCD_VERSION "InspIRCd-@VERSION_FULL@" + +/*** Determines whether this version of InspIRCd is older than the requested version. */ +#define INSPIRCD_VERSION_BEFORE(MAJOR, MINOR) (((@VERSION_MAJOR@ << 8) | @VERSION_MINOR@) < ((MAJOR << 8) | (MINOR))) + +/*** Determines whether this version of InspIRCd is equal to or newer than the requested version. */ +#define INSPIRCD_VERSION_SINCE(MAJOR, MINOR) (((@VERSION_MAJOR@ << 16) | @VERSION_MINOR@) >= ((MAJOR << 8) | (MINOR))) + +/*** The default location that config files are stored in. */ #define INSPIRCD_CONFIG_PATH "@CONFIG_DIR@" -#define INSPIRCD_DATA_PATH "@DATA_DIR@" -#define INSPIRCD_LOG_PATH "@LOG_DIR@" + +/*** The default location that data files are stored in. */ +#define INSPIRCD_DATA_PATH "@DATA_DIR@" + +/*** The default location that log files are stored in. */ +#define INSPIRCD_LOG_PATH "@LOG_DIR@" + +/*** The default location that module files are stored in. */ #define INSPIRCD_MODULE_PATH "@MODULE_DIR@" #ifndef _WIN32 %target include/config.h + +/*** Whether the arc4random_buf() function was available at compile time. */ %define HAS_ARC4RANDOM_BUF + +/*** Whether the clock_gettime() function was available at compile time. */ %define HAS_CLOCK_GETTIME + +/*** Whether the eventfd() function was available at compile time. */ %define HAS_EVENTFD + #endif |