mirror of
https://github.com/Dasharo/systemd.git
synced 2026-03-06 15:02:31 -08:00
basic: move version() to build.h+c
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
#include <getopt.h>
|
||||
|
||||
#include "build.h"
|
||||
#include "main-func.h"
|
||||
#include "udev-util.h"
|
||||
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include "sd-daemon.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "env-util.h"
|
||||
#include "errno-util.h"
|
||||
#include "escape.h"
|
||||
@@ -23,7 +24,6 @@
|
||||
#include "string-util.h"
|
||||
#include "strv.h"
|
||||
#include "terminal-util.h"
|
||||
#include "util.h"
|
||||
|
||||
static char **arg_listen = NULL;
|
||||
static bool arg_accept = false;
|
||||
|
||||
@@ -37,6 +37,7 @@
|
||||
#include "analyze-unit-paths.h"
|
||||
#include "analyze-compare-versions.h"
|
||||
#include "analyze-verify.h"
|
||||
#include "build.h"
|
||||
#include "bus-error.h"
|
||||
#include "bus-locator.h"
|
||||
#include "bus-map-properties.h"
|
||||
@@ -79,7 +80,6 @@
|
||||
#include "time-util.h"
|
||||
#include "tmpfile-util.h"
|
||||
#include "unit-name.h"
|
||||
#include "util.h"
|
||||
#include "verb-log-control.h"
|
||||
#include "verbs.h"
|
||||
#include "version.h"
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include <unistd.h>
|
||||
|
||||
#include "ask-password-api.h"
|
||||
#include "build.h"
|
||||
#include "def.h"
|
||||
#include "log.h"
|
||||
#include "macro.h"
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
/* SPDX-License-Identifier: LGPL-2.1-or-later */
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "build.h"
|
||||
#include "macro.h"
|
||||
|
||||
const char* const systemd_features =
|
||||
|
||||
@@ -226,3 +229,9 @@ const char* const systemd_features =
|
||||
|
||||
" default-hierarchy=" DEFAULT_HIERARCHY_NAME
|
||||
;
|
||||
|
||||
int version(void) {
|
||||
printf("systemd " STRINGIFY(PROJECT_VERSION) " (" GIT_VERSION ")\n%s\n",
|
||||
systemd_features);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -4,3 +4,5 @@
|
||||
#include "version.h"
|
||||
|
||||
extern const char* const systemd_features;
|
||||
|
||||
int version(void);
|
||||
|
||||
@@ -20,9 +20,3 @@
|
||||
|
||||
int saved_argc = 0;
|
||||
char **saved_argv = NULL;
|
||||
|
||||
int version(void) {
|
||||
printf("systemd " STRINGIFY(PROJECT_VERSION) " (" GIT_VERSION ")\n%s\n",
|
||||
systemd_features);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -65,5 +65,3 @@ static inline unsigned log2u_round_up(unsigned x) {
|
||||
|
||||
return log2u(x - 1) + 1;
|
||||
}
|
||||
|
||||
int version(void);
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "binfmt-util.h"
|
||||
#include "build.h"
|
||||
#include "conf-files.h"
|
||||
#include "def.h"
|
||||
#include "fd-util.h"
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bootspec.h"
|
||||
#include "build.h"
|
||||
#include "devnum-util.h"
|
||||
#include "efi-api.h"
|
||||
#include "efi-loader.h"
|
||||
@@ -19,7 +20,6 @@
|
||||
#include "pretty-print.h"
|
||||
#include "sync-util.h"
|
||||
#include "terminal-util.h"
|
||||
#include "util.h"
|
||||
#include "verbs.h"
|
||||
#include "virt.h"
|
||||
|
||||
|
||||
@@ -8,12 +8,12 @@
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-error.h"
|
||||
#include "log.h"
|
||||
#include "main-func.h"
|
||||
#include "pretty-print.h"
|
||||
#include "terminal-util.h"
|
||||
#include "util.h"
|
||||
|
||||
static int help(void) {
|
||||
_cleanup_free_ char *link = NULL;
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include "alloc-util.h"
|
||||
#include "blkid-util.h"
|
||||
#include "bootspec.h"
|
||||
#include "build.h"
|
||||
#include "chase-symlinks.h"
|
||||
#include "copy.h"
|
||||
#include "devnum-util.h"
|
||||
@@ -53,7 +54,6 @@
|
||||
#include "tpm2-util.h"
|
||||
#include "umask-util.h"
|
||||
#include "utf8.h"
|
||||
#include "util.h"
|
||||
#include "verbs.h"
|
||||
#include "virt.h"
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#include <unistd.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "efi-loader.h"
|
||||
#include "fd-util.h"
|
||||
#include "fileio.h"
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
#include <sd-messages.h>
|
||||
|
||||
#include "build.h"
|
||||
#include "efivars.h"
|
||||
#include "main-func.h"
|
||||
#include "openssl-util.h"
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-dump.h"
|
||||
#include "bus-internal.h"
|
||||
#include "bus-message.h"
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-util.h"
|
||||
#include "cgroup-show.h"
|
||||
#include "cgroup-util.h"
|
||||
@@ -21,7 +22,6 @@
|
||||
#include "pretty-print.h"
|
||||
#include "strv.h"
|
||||
#include "unit-name.h"
|
||||
#include "util.h"
|
||||
|
||||
static PagerFlags arg_pager_flags = 0;
|
||||
static OutputFlags arg_output_flags = OUTPUT_CGROUP_XATTRS | OUTPUT_CGROUP_ID;
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "sd-bus.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-error.h"
|
||||
#include "bus-util.h"
|
||||
#include "cgroup-show.h"
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include "sd-messages.h"
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "build.h"
|
||||
#include "bus-error.h"
|
||||
#include "bus-locator.h"
|
||||
#include "bus-util.h"
|
||||
@@ -42,7 +43,6 @@
|
||||
#include "terminal-util.h"
|
||||
#include "tmpfile-util.h"
|
||||
#include "user-util.h"
|
||||
#include "util.h"
|
||||
#include "verbs.h"
|
||||
|
||||
#define SHORT_BUS_CALL_TIMEOUT_USEC (3 * USEC_PER_SEC)
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include <getopt.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "build.h"
|
||||
#include "creds-util.h"
|
||||
#include "dirent-util.h"
|
||||
#include "escape.h"
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include <getopt.h>
|
||||
|
||||
#include "ask-password-api.h"
|
||||
#include "build.h"
|
||||
#include "cryptenroll-fido2.h"
|
||||
#include "cryptenroll-list.h"
|
||||
#include "cryptenroll-password.h"
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user