From 3f6fd1ba65f962702753c4ad284b588e59689a23 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Wed, 23 Sep 2015 03:01:06 +0200 Subject: util: introduce common version() implementation and use it everywhere This also allows us to drop build.h from a ton of files, hence do so. Since we touched the #includes of those files, let's order them properly according to CODING_STYLE. --- src/basic/util.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/basic/util.c') diff --git a/src/basic/util.c b/src/basic/util.c index f7e4aefebb..2bad33be1b 100644 --- a/src/basic/util.c +++ b/src/basic/util.c @@ -72,6 +72,7 @@ * otherwise conflicts with sys/mount.h. Yay, Linux is great! */ #include +#include "build.h" #include "def.h" #include "device-nodes.h" #include "env-util.h" @@ -6920,3 +6921,9 @@ int receive_one_fd(int transport_fd, int flags) { void nop_signal_handler(int sig) { /* nothing here */ } + +int version(void) { + puts(PACKAGE_STRING "\n" + SYSTEMD_FEATURES); + return 0; +} -- cgit v1.2.3-54-g00ecf