Daan De Meyer
f102bc3e5f
tree-wide: Introduce sd-forward.h and shared-forward.h headers
...
Let's not leak details from src/shared and src/libsystemd into
src/basic, even though you can't actually do anything useful with
just forward declarations from src/shared.
The sd-forward.h header is put in src/libsystemd/sd-common as we
don't have a directory for shared internal headers for libsystemd
yet.
Let's also rename forward.h to basic-forward.h to keep things
self-explanatory.
2025-10-16 17:00:29 +02:00
Daan De Meyer
69a283c5f2
shared: Clean up includes
...
Split out of #37344 .
2025-05-24 14:00:44 +02:00
Daan De Meyer
401a22bfc1
tree-wide: Make sure all headers are standalone
...
Let's make sure all of our headers include everything they require.
2025-04-23 10:33:38 +02:00
Merlin Jehli
274a38c79a
machine-id: Add cmdline argument to use VM behaviour on bare metal ( #32086 )
...
Closes #30707
2024-07-13 18:00:16 +02:00
Yu Watanabe
bac11cd667
core: move several source files to src/shared
...
As, the files are used by many executables, fstab-generator, remount-fs,
machine-id-setup, and etc.
With this change, the total size of the relevant executables and
libshared slightly decreases.
Before:
```
$ ll systemd-fstab-generator systemd-remount-fs systemd-machine-id-setup systemd-shutdown systemd-nspawn systemd src/shared/libsystemd-shared-247.so
-rwxrwxr-x 1 watanabe watanabe 7577800 Jan 5 13:35 src/shared/libsystemd-shared-247.so
-rwxrwxr-x 1 watanabe watanabe 4608360 Jan 5 13:35 systemd
-rwxrwxr-x 1 watanabe watanabe 117240 Jan 5 13:35 systemd-fstab-generator
-rwxrwxr-x 1 watanabe watanabe 61576 Jan 5 13:35 systemd-machine-id-setup
-rwxrwxr-x 1 watanabe watanabe 853080 Jan 5 13:35 systemd-nspawn
-rwxrwxr-x 1 watanabe watanabe 70600 Jan 5 13:35 systemd-remount-fs
-rwxrwxr-x 1 watanabe watanabe 172624 Jan 5 13:35 systemd-shutdown
```
Total: 13461280
After:
```
$ ll systemd-fstab-generator systemd-remount-fs systemd-machine-id-setup systemd-shutdown systemd-nspawn systemd src/shared/libsystemd-shared-247.so
-rwxrwxr-x 1 watanabe watanabe 7658336 Jan 5 13:32 src/shared/libsystemd-shared-247.so
-rwxrwxr-x 1 watanabe watanabe 4523560 Jan 5 13:32 systemd
-rwxrwxr-x 1 watanabe watanabe 78288 Jan 5 13:32 systemd-fstab-generator
-rwxrwxr-x 1 watanabe watanabe 30984 Jan 5 13:32 systemd-machine-id-setup
-rwxrwxr-x 1 watanabe watanabe 840384 Jan 5 13:32 systemd-nspawn
-rwxrwxr-x 1 watanabe watanabe 39104 Jan 5 13:32 systemd-remount-fs
-rwxrwxr-x 1 watanabe watanabe 117160 Jan 5 13:32 systemd-shutdown
```
Total: 13287816
2021-01-19 07:04:19 +09:00
Lennart Poettering
08e1fb68d7
build-sys: move *-setup out of shared to avoid selinux being pulled in
2012-04-12 18:19:34 +02:00
Lennart Poettering
b6e661357c
main: we want all setup functions to be in files called xxx-setup.[ch]
2012-04-12 14:29:29 +02:00
Kay Sievers
78a825f216
rename machine-id-main.c tomacht the binary and move main.c to core/
2012-04-12 13:12:06 +02:00
Kay Sievers
f33d3ec1d7
move more common files to shared/ and add them to shared.la
2012-04-12 02:39:37 +02:00