context: Log version number at startup

Having this should at least give us a slightly better idea about the
version that the user has installed. Obviously it is still not very
accurate (maybe a git hash would be good if available?), but it should
still be helpful overall.
This commit is contained in:
Benjamin Berg
2022-04-10 13:58:58 +02:00
parent 2b760dfa38
commit da1a56a600
2 changed files with 3 additions and 0 deletions

View File

@@ -361,6 +361,8 @@ fp_context_init (FpContext *self)
FpContextPrivate *priv = fp_context_get_instance_private (self); FpContextPrivate *priv = fp_context_get_instance_private (self);
guint i; guint i;
g_debug ("Initializing FpContext (libfprint version " LIBFPRINT_VERSION ")");
priv->drivers = fpi_get_driver_types (); priv->drivers = fpi_get_driver_types ();
if (get_drivers_whitelist_env ()) if (get_drivers_whitelist_env ())

View File

@@ -11,6 +11,7 @@ project('libfprint', [ 'c', 'cpp' ],
gnome = import('gnome') gnome = import('gnome')
libfprint_conf = configuration_data() libfprint_conf = configuration_data()
libfprint_conf.set_quoted('LIBFPRINT_VERSION', meson.project_version())
cc = meson.get_compiler('c') cc = meson.get_compiler('c')
cpp = meson.get_compiler('cpp') cpp = meson.get_compiler('cpp')