From b49f9845984f4727716ab682193a4897d3932bba Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Wed, 17 Jun 2026 22:52:14 +0100 Subject: [PATCH] Improve support for versioning builds. - Don't increment the build id when doing reproducible builds. - Generate the build date in build.h so it always gets updated. --- include/anope.h | 4 ---- include/version.cpp | 19 +++++++++++++++++-- src/misc.cpp | 4 ++-- 3 files changed, 19 insertions(+), 8 deletions(-) diff --git a/include/anope.h b/include/anope.h index c268f9599..8a14db5ab 100644 --- a/include/anope.h +++ b/include/anope.h @@ -362,10 +362,6 @@ namespace Anope template using unordered_map = std::unordered_map; -#if !REPRODUCIBLE_BUILD - static const char *const compiled = __TIME__ " " __DATE__; -#endif - /** The time Anope started. */ extern CoreExport time_t StartTime; diff --git a/include/version.cpp b/include/version.cpp index 1c5c28d02..9aeaf121c 100644 --- a/include/version.cpp +++ b/include/version.cpp @@ -18,6 +18,8 @@ #include #include +#include "sysconf.h" + static std::string get_git_hash(const std::string &git_dir) { std::fstream fd; @@ -78,14 +80,18 @@ static bool read_version_sh(const std::string &version_sh, std::map