Special build string is printed when --version is specified. This is handy when building a snapshot or if not git repository.
Signed-off-by: Alon Bar-Lev <alon.bar...@gmail.com> --- configure.ac | 6 ++++++ src/openvpn/options.c | 3 +++ 2 files changed, 9 insertions(+), 0 deletions(-) diff --git a/configure.ac b/configure.ac index d2851f6..926a270 100644 --- a/configure.ac +++ b/configure.ac @@ -229,6 +229,12 @@ AC_ARG_ENABLE( ) AC_ARG_WITH( + [special-build], + [AS_HELP_STRING([--with-special-build=STRING], [specify special build string])], + [AC_DEFINE_UNQUOTED([CONFIGURE_SPECIAL_BUILD], ["${withval}"], [special build string])] +) + +AC_ARG_WITH( [mem-check], [AS_HELP_STRING([--with-mem-check=TYPE], [build with debug memory checking, TYPE=no|dmalloc|valgrind|ssl @<:@default=no@:>@])], [ diff --git a/src/openvpn/options.c b/src/openvpn/options.c index 4ee2f31..9e77463 100644 --- a/src/openvpn/options.c +++ b/src/openvpn/options.c @@ -3484,6 +3484,9 @@ usage_version (void) #ifdef CONFIGURE_DEFINES msg (M_INFO|M_NOPREFIX, "Compile time defines: %s", CONFIGURE_DEFINES); #endif +#ifdef CONFIGURE_SPECIAL_BUILD + msg (M_INFO|M_NOPREFIX, "special build: %s", CONFIGURE_SPECIAL_BUILD); +#endif #ifdef CONFIGURE_GIT_REVISION msg (M_INFO|M_NOPREFIX, "git revision: %s", CONFIGURE_GIT_REVISION); #endif -- 1.7.3.4