diff options
author | Lennart Poettering <lennart@poettering.net> | 2019-03-05 12:12:33 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2019-03-05 12:21:17 +0100 |
commit | 9e71f5d9838af32b9484d1757129c419e57866ae (patch) | |
tree | 771a1eb36a153322b6e9a943ff0b8b3ec09d7abb | |
parent | 3a736a32164672550fead7417a2159751ac94df5 (diff) | |
download | systemd-9e71f5d9838af32b9484d1757129c419e57866ae.tar.gz |
shutdown: rearrange shutdown sources in source tree
Let's move the shutdown binary into its own subdirectory in
src/shutdown, after all it is relatively isolated from the normal PID 1
sources, being a different binary and all.
Unfortunately it's not possible to move some of the code, since it is
shared with PID 1, that I wished we could move, but I still think it's
worth it.
-rw-r--r-- | meson.build | 6 | ||||
-rw-r--r-- | src/core/meson.build | 10 | ||||
-rw-r--r-- | src/shutdown/meson.build | 5 | ||||
-rw-r--r-- | src/shutdown/shutdown.c (renamed from src/core/shutdown.c) | 0 | ||||
-rw-r--r-- | src/shutdown/umount.c (renamed from src/core/umount.c) | 0 | ||||
-rw-r--r-- | src/shutdown/umount.h (renamed from src/core/umount.h) | 0 | ||||
-rw-r--r-- | src/test/meson.build | 4 |
7 files changed, 13 insertions, 12 deletions
diff --git a/meson.build b/meson.build index 239f13c061..f2b975abc5 100644 --- a/meson.build +++ b/meson.build @@ -1441,6 +1441,7 @@ includes = include_directories('src/basic', 'src/udev', 'src/libudev', 'src/core', + 'src/shutdown', 'src/libsystemd/sd-bus', 'src/libsystemd/sd-device', 'src/libsystemd/sd-event', @@ -1527,6 +1528,7 @@ public_programs = [] subdir('src/libudev') subdir('src/shared') subdir('src/core') +subdir('src/shutdown') subdir('src/udev') subdir('src/network') @@ -2676,6 +2678,10 @@ public_programs += exe executable('systemd-shutdown', systemd_shutdown_sources, + 'src/core/mount-setup.c', + 'src/core/mount-setup.h', + 'src/core/killall.c', + 'src/core/killall.h', include_directories : includes, link_with : [libshared], dependencies : [libmount], diff --git a/src/core/meson.build b/src/core/meson.build index 88fb093732..6f387c4796 100644 --- a/src/core/meson.build +++ b/src/core/meson.build @@ -163,16 +163,6 @@ libcore = static_library( systemd_sources = files('main.c') -systemd_shutdown_sources = files(''' - shutdown.c - umount.c - umount.h - mount-setup.c - mount-setup.h - killall.c - killall.h -'''.split()) - in_files = [['macros.systemd', rpmmacrosdir], ['system.conf', pkgsysconfdir], ['systemd.pc', pkgconfigdatadir], diff --git a/src/shutdown/meson.build b/src/shutdown/meson.build new file mode 100644 index 0000000000..ebf0bed242 --- /dev/null +++ b/src/shutdown/meson.build @@ -0,0 +1,5 @@ +systemd_shutdown_sources = files(''' + shutdown.c + umount.c + umount.h +'''.split()) diff --git a/src/core/shutdown.c b/src/shutdown/shutdown.c index 842ba57f13..842ba57f13 100644 --- a/src/core/shutdown.c +++ b/src/shutdown/shutdown.c diff --git a/src/core/umount.c b/src/shutdown/umount.c index 7af0195aab..7af0195aab 100644 --- a/src/core/umount.c +++ b/src/shutdown/umount.c diff --git a/src/core/umount.h b/src/shutdown/umount.h index 6f2b24d195..6f2b24d195 100644 --- a/src/core/umount.h +++ b/src/shutdown/umount.h diff --git a/src/test/meson.build b/src/test/meson.build index c53b9653f9..e43f119230 100644 --- a/src/test/meson.build +++ b/src/test/meson.build @@ -716,8 +716,8 @@ tests += [ [['src/test/test-umount.c', 'src/core/mount-setup.c', 'src/core/mount-setup.h', - 'src/core/umount.c', - 'src/core/umount.h'], + 'src/shutdown/umount.c', + 'src/shutdown/umount.h'], [], [libmount]], |