From 7d568925bda9797f611e36d1d00cd941701cb3c8 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Mon, 6 Sep 2010 03:11:24 +0200 Subject: [PATCH] systemctl: make --version a little bit more verbose --- configure.ac | 1 + src/main.c | 2 +- src/systemctl.c | 3 +++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 8d0da436..ba9bbf82 100644 --- a/configure.ac +++ b/configure.ac @@ -262,6 +262,7 @@ if test "z$with_distro" = "z"; then fi fi with_distro=`echo ${with_distro} | tr '[[:upper:]]' '[[:lower:]]' ` +AC_DEFINE_UNQUOTED(DISTRIBUTION, ["${with_distro}"], [Target Distribution]) # Default generic names SPECIAL_SYSLOG_SERVICE=syslog.service diff --git a/src/main.c b/src/main.c index 2e6ccfaa..d0587cb5 100644 --- a/src/main.c +++ b/src/main.c @@ -992,7 +992,7 @@ int main(int argc, char *argv[]) { install_crash_handler(); log_full(arg_running_as == MANAGER_SYSTEM ? LOG_INFO : LOG_DEBUG, - PACKAGE_STRING " running in %s mode. (" SYSTEMD_FEATURES ")", manager_running_as_to_string(arg_running_as)); + PACKAGE_STRING " running in %s mode. (" SYSTEMD_FEATURES "; " DISTRIBUTION ")", manager_running_as_to_string(arg_running_as)); if (arg_running_as == MANAGER_SYSTEM && !serialization) { if (arg_show_status) diff --git a/src/systemctl.c b/src/systemctl.c index c77f831e..627b9055 100644 --- a/src/systemctl.c +++ b/src/systemctl.c @@ -52,6 +52,7 @@ #include "shutdownd.h" #include "exit-status.h" #include "bus-errors.h" +#include "build.h" static const char *arg_type = NULL; static char **arg_property = NULL; @@ -4031,6 +4032,8 @@ static int systemctl_parse_argv(int argc, char *argv[]) { case ARG_VERSION: puts(PACKAGE_STRING); + puts(DISTRIBUTION); + puts(SYSTEMD_FEATURES); return 0; case 't': -- 2.39.5