MINOR: wurfl: indicate in haproxy -vv the wurfl version in use
It also explicitly mentions that the library is the dummy one when it
is detected.
We have this output now :
$ ./haproxy -vv |grep -i wurfl
Built with WURFL support (dummy library version 1.11.2.100)
diff --git a/src/wurfl.c b/src/wurfl.c
index 75dcf00..5c490f7 100644
--- a/src/wurfl.c
+++ b/src/wurfl.c
@@ -795,6 +795,17 @@
return ((ha_wurfl_header_t *)wh)->header_value;
}
+static void ha_wurfl_register_build_options()
+{
+ const char *ver = wurfl_get_api_version();
+ char *ptr = NULL;
+
+ memprintf(&ptr, "Built with WURFL support (%sversion %s)",
+ strcmp(ver, "1.11.2.100") ? "" : "dummy library ",
+ ver);
+ hap_register_build_opts(ptr, 1);
+}
+
REGISTER_POST_CHECK(ha_wurfl_init);
REGISTER_POST_DEINIT(ha_wurfl_deinit);
-REGISTER_BUILD_OPTS("Built with WURFL support.");
+INITCALL0(STG_REGISTER, ha_wurfl_register_build_options);