From f102bc3e5f0bf5fb116af98d51836fd55995cd18 Mon Sep 17 00:00:00 2001 From: Daan De Meyer Date: Thu, 16 Oct 2025 15:20:36 +0200 Subject: [PATCH] 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. --- docs/CODING_STYLE.md | 30 +- meson.build | 1 + src/analyze/analyze-time-data.h | 2 +- src/analyze/analyze-verify-util.h | 2 +- src/analyze/analyze.h | 2 +- src/basic/af-list.h | 2 +- src/basic/alloc-util.h | 2 +- src/basic/ansi-color.h | 2 +- src/basic/architecture.h | 2 +- src/basic/argv-util.h | 2 +- src/basic/arphrd-util.h | 2 +- src/basic/audit-util.h | 2 +- src/basic/basic-forward.h | 134 ++++++++ src/basic/bitfield.h | 2 +- src/basic/btrfs.h | 2 +- src/basic/build.h | 2 +- src/basic/bus-label.h | 2 +- src/basic/capability-list.h | 2 +- src/basic/capability-util.h | 2 +- src/basic/capsule-util.h | 2 +- src/basic/cgroup-util.h | 2 +- src/basic/chase.h | 2 +- src/basic/chattr-util.h | 2 +- src/basic/compress.h | 2 +- src/basic/conf-files.h | 2 +- src/basic/confidential-virt.h | 2 +- src/basic/devnum-util.h | 2 +- src/basic/dirent-util.h | 2 +- src/basic/dlfcn-util.h | 2 +- src/basic/dns-def.h | 2 +- src/basic/efivars.h | 2 +- src/basic/env-file.h | 2 +- src/basic/env-util.h | 2 +- src/basic/errno-list.h | 2 +- src/basic/errno-util.h | 2 +- src/basic/escape.h | 2 +- src/basic/ether-addr-util.h | 2 +- src/basic/extract-word.h | 2 +- src/basic/fd-util.h | 2 +- src/basic/fileio.h | 2 +- src/basic/filesystems.h | 2 +- src/basic/format-util.h | 2 +- src/basic/forward.h | 325 ------------------ src/basic/fs-util.h | 2 +- src/basic/gcrypt-util.h | 2 +- src/basic/glob-util.h | 2 +- src/basic/glyph-util.h | 2 +- src/basic/gunicode.h | 2 +- src/basic/hash-funcs.h | 2 +- src/basic/hashmap.h | 2 +- src/basic/hexdecoct.h | 2 +- src/basic/hmac.h | 2 +- src/basic/hostname-util.h | 2 +- src/basic/in-addr-util.h | 2 +- src/basic/initrd-util.h | 2 +- src/basic/inotify-util.h | 2 +- src/basic/io-util.h | 2 +- src/basic/iovec-util.h | 2 +- src/basic/iovec-wrapper.h | 2 +- src/basic/iterator.h | 2 +- src/basic/keyring-util.h | 2 +- src/basic/label.h | 2 +- src/basic/limits-util.h | 2 +- src/basic/list.h | 2 +- src/basic/locale-util.h | 2 +- src/basic/lock-util.h | 2 +- src/basic/log-context.h | 2 +- src/basic/log.h | 2 +- src/basic/login-util.h | 2 +- src/basic/math-util.h | 2 +- src/basic/memfd-util.h | 2 +- src/basic/memory-util.h | 2 +- src/basic/mempool.h | 2 +- src/basic/memstream-util.h | 2 +- src/basic/mkdir.h | 2 +- src/basic/mountpoint-util.h | 2 +- src/basic/namespace-util.h | 2 +- src/basic/nulstr-util.h | 2 +- src/basic/ordered-set.h | 2 +- src/basic/os-util.h | 2 +- src/basic/parse-util.h | 2 +- src/basic/path-util.h | 2 +- src/basic/pcapng.h | 2 +- src/basic/percent-util.h | 2 +- src/basic/pidfd-util.h | 2 +- src/basic/pidref.h | 2 +- src/basic/prioq.h | 2 +- src/basic/proc-cmdline.h | 2 +- src/basic/process-util.h | 2 +- src/basic/procfs-util.h | 2 +- src/basic/psi-util.h | 2 +- src/basic/pthread-util.h | 2 +- src/basic/random-util.h | 2 +- src/basic/ratelimit.h | 2 +- src/basic/raw-clone.h | 2 +- src/basic/recurse-dir.h | 2 +- src/basic/replace-var.h | 2 +- src/basic/rlimit-util.h | 2 +- src/basic/runtime-scope.h | 2 +- src/basic/set.h | 2 +- src/basic/sha256.h | 2 +- src/basic/sigbus.h | 2 +- src/basic/signal-util.h | 2 +- src/basic/siphash24.h | 2 +- src/basic/socket-util.h | 2 +- src/basic/sort-util.h | 2 +- src/basic/sparse-endian.h | 2 +- src/basic/stat-util.h | 2 +- src/basic/static-destruct.h | 2 +- src/basic/stdio-util.h | 2 +- src/basic/strbuf.h | 2 +- src/basic/string-table.h | 2 +- src/basic/string-util.h | 2 +- src/basic/strv.h | 2 +- src/basic/strxcpyx.h | 2 +- src/basic/sync-util.h | 2 +- src/basic/sysctl-util.h | 2 +- src/basic/syslog-util.h | 2 +- src/basic/terminal-util.h | 2 +- src/basic/time-util.h | 2 +- src/basic/tmpfile-util.h | 2 +- src/basic/uid-classification.h | 2 +- src/basic/uid-range.h | 2 +- src/basic/umask-util.h | 2 +- src/basic/unaligned.h | 2 +- src/basic/unit-def.h | 2 +- src/basic/unit-name.h | 2 +- src/basic/user-util.h | 2 +- src/basic/utf8.h | 2 +- src/basic/virt.h | 2 +- src/basic/xattr-util.h | 2 +- src/bootctl/bootctl-reboot-to-firmware.h | 2 +- src/bootctl/bootctl-status.h | 2 +- src/bootctl/bootctl-uki.h | 2 +- src/bootctl/bootctl.h | 2 +- src/busctl/busctl-introspect.h | 2 +- src/core/audit-fd.h | 2 +- src/core/clock-warp.h | 2 +- src/core/core-forward.h | 2 +- src/core/crash-handler.h | 2 +- src/core/generator-setup.h | 2 +- src/core/kill.h | 2 +- src/core/main.h | 2 +- src/core/manager.h | 2 +- src/core/namespace.h | 2 +- src/core/selinux-setup.h | 2 +- src/core/show-status.h | 2 +- src/core/smack-setup.h | 2 +- src/core/unit-dependency-atom.h | 2 +- src/core/varlink-cgroup.h | 2 +- src/core/varlink-common.h | 2 +- src/core/varlink-dynamic-user.h | 2 +- src/core/varlink-manager.h | 2 +- src/core/varlink-unit.h | 2 +- src/coredump/coredump-vacuum.h | 2 +- src/cryptenroll/cryptenroll-fido2.h | 2 +- src/cryptenroll/cryptenroll-list.h | 2 +- src/cryptenroll/cryptenroll-password.h | 2 +- src/cryptenroll/cryptenroll-pkcs11.h | 2 +- src/cryptenroll/cryptenroll-recovery.h | 2 +- src/cryptenroll/cryptenroll-tpm2.h | 2 +- src/cryptenroll/cryptenroll-wipe.h | 2 +- src/cryptenroll/cryptenroll.h | 2 +- src/cryptsetup/cryptsetup-keyfile.h | 2 +- src/cryptsetup/cryptsetup-pkcs11.h | 2 +- .../cryptsetup-tokens/cryptsetup-token-util.h | 2 +- .../cryptsetup-tokens/cryptsetup-token.h | 2 +- .../cryptsetup-tokens/luks2-pkcs11.h | 2 +- src/fuzz/fuzz.h | 2 +- .../hibernate-resume-config.h | 2 +- src/home/home-util.h | 2 +- src/home/homectl-fido2.h | 2 +- src/home/homectl-pkcs11.h | 2 +- src/home/homectl-recovery-key.h | 2 +- src/home/homed-bus.h | 2 +- src/home/homed-forward.h | 2 +- src/home/homed-home.h | 2 +- src/home/homework-forward.h | 2 +- src/home/user-record-password-quality.h | 2 +- src/home/user-record-sign.h | 2 +- src/home/user-record-util.h | 2 +- src/import/curl-util.h | 2 +- src/import/export-raw.h | 2 +- src/import/export-tar.h | 2 +- src/import/import-common.h | 2 +- src/import/import-compress.h | 2 +- src/import/import-raw.h | 2 +- src/import/import-tar.h | 2 +- src/import/pull-common.h | 2 +- src/import/pull-job.h | 2 +- src/import/pull-raw.h | 2 +- src/import/pull-tar.h | 2 +- src/integritysetup/integrity-util.h | 2 +- src/journal-remote/journal-compression-util.h | 2 +- src/journal-remote/journal-header-util.h | 2 +- src/journal-remote/journal-remote-parse.h | 2 +- src/journal-remote/journal-remote.h | 2 +- src/journal-remote/journal-upload.h | 2 +- src/journal-remote/microhttpd-util.h | 2 +- src/journal/journalctl-filter.h | 2 +- src/journal/journalctl-misc.h | 2 +- src/journal/journalctl-util.h | 2 +- src/journal/journalctl.h | 2 +- src/journal/journald-forward.h | 2 +- src/libsystemd-network/arp-util.h | 2 +- .../dhcp-client-id-internal.h | 2 +- src/libsystemd-network/dhcp-client-internal.h | 2 +- src/libsystemd-network/dhcp-duid-internal.h | 2 +- src/libsystemd-network/dhcp-lease-internal.h | 2 +- src/libsystemd-network/dhcp-network.h | 2 +- src/libsystemd-network/dhcp-option.h | 2 +- src/libsystemd-network/dhcp-packet.h | 2 +- src/libsystemd-network/dhcp-protocol.h | 2 +- src/libsystemd-network/dhcp-server-internal.h | 2 +- .../dhcp-server-lease-internal.h | 2 +- .../dhcp6-client-internal.h | 2 +- src/libsystemd-network/dhcp6-internal.h | 2 +- src/libsystemd-network/dhcp6-lease-internal.h | 2 +- src/libsystemd-network/dhcp6-option.h | 2 +- src/libsystemd-network/dhcp6-protocol.h | 2 +- .../dns-resolver-internal.h | 2 +- src/libsystemd-network/icmp6-packet.h | 2 +- src/libsystemd-network/icmp6-util.h | 2 +- src/libsystemd-network/lldp-neighbor.h | 2 +- src/libsystemd-network/lldp-rx-internal.h | 2 +- src/libsystemd-network/ndisc-internal.h | 2 +- .../ndisc-neighbor-internal.h | 2 +- .../ndisc-redirect-internal.h | 2 +- .../ndisc-router-solicit-internal.h | 2 +- src/libsystemd-network/network-common.h | 2 +- src/libsystemd-network/network-internal.h | 2 +- src/libsystemd-network/radv-internal.h | 2 +- src/libsystemd-network/sd-dns-resolver.h | 2 +- src/libsystemd/sd-bus/bus-container.h | 2 +- src/libsystemd/sd-bus/bus-control.h | 2 +- src/libsystemd/sd-bus/bus-creds.h | 2 +- src/libsystemd/sd-bus/bus-dump.h | 2 +- src/libsystemd/sd-bus/bus-error.h | 2 +- src/libsystemd/sd-bus/bus-forward.h | 2 +- src/libsystemd/sd-bus/bus-kernel.h | 2 +- src/libsystemd/sd-bus/bus-signature.h | 2 +- src/libsystemd/sd-bus/bus-socket.h | 2 +- src/libsystemd/sd-bus/bus-track.h | 2 +- src/libsystemd/sd-bus/bus-type.h | 2 +- src/libsystemd/sd-common/sd-forward.h | 127 +++++++ .../sd-device/device-enumerator-private.h | 2 +- src/libsystemd/sd-device/device-filter.h | 2 +- src/libsystemd/sd-device/device-internal.h | 2 +- .../sd-device/device-monitor-private.h | 2 +- src/libsystemd/sd-device/device-private.h | 2 +- src/libsystemd/sd-device/device-util.h | 2 +- src/libsystemd/sd-event/event-source.h | 2 +- src/libsystemd/sd-event/event-util.h | 2 +- src/libsystemd/sd-hwdb/hwdb-internal.h | 2 +- src/libsystemd/sd-id128/id128-util.h | 2 +- src/libsystemd/sd-journal/audit-type.h | 2 +- src/libsystemd/sd-journal/catalog.h | 2 +- src/libsystemd/sd-journal/fsprg.h | 2 +- .../sd-journal/journal-authenticate.h | 2 +- src/libsystemd/sd-journal/journal-def.h | 2 +- src/libsystemd/sd-journal/journal-file.h | 2 +- src/libsystemd/sd-journal/journal-internal.h | 2 +- src/libsystemd/sd-journal/journal-vacuum.h | 2 +- src/libsystemd/sd-journal/lookup3.h | 2 +- src/libsystemd/sd-journal/mmap-cache.h | 2 +- src/libsystemd/sd-json/json-internal.h | 2 +- src/libsystemd/sd-json/json-util.h | 2 +- src/libsystemd/sd-netlink/netlink-genl.h | 2 +- src/libsystemd/sd-netlink/netlink-internal.h | 2 +- src/libsystemd/sd-netlink/netlink-slot.h | 2 +- src/libsystemd/sd-netlink/netlink-types.h | 2 +- src/libsystemd/sd-netlink/netlink-util.h | 2 +- src/libsystemd/sd-network/network-util.h | 2 +- src/libsystemd/sd-path/path-lookup.h | 2 +- src/libsystemd/sd-varlink/varlink-idl-util.h | 2 +- src/libsystemd/sd-varlink/varlink-internal.h | 2 +- src/libsystemd/sd-varlink/varlink-util.h | 2 +- src/libudev/libudev-device-internal.h | 2 +- src/libudev/libudev-list-internal.h | 2 +- src/libudev/libudev-util.c | 2 +- src/libudev/libudev-util.h | 2 +- src/locale/localed-util.h | 2 +- src/locale/xkbcommon-util.h | 2 +- src/login/logind-forward.h | 2 +- src/login/logind-user.h | 2 +- src/login/sysfs-show.h | 2 +- src/machine/machine-forward.h | 2 +- src/mountfsd/mountfsd-manager.h | 2 +- src/network/netdev/bareudp.h | 2 +- src/network/netdev/batadv.h | 2 +- src/network/netdev/bond.h | 2 +- src/network/netdev/bridge.h | 2 +- src/network/netdev/dummy.h | 2 +- src/network/netdev/fou-tunnel.h | 2 +- src/network/netdev/geneve.h | 2 +- src/network/netdev/l2tp-tunnel.h | 2 +- src/network/netdev/macsec.h | 2 +- src/network/netdev/tunnel.h | 2 +- src/network/netdev/tuntap.h | 2 +- src/network/netdev/vlan.h | 2 +- src/network/netdev/wlan.h | 2 +- src/network/netdev/xfrm.h | 2 +- src/network/networkctl-dump-util.h | 2 +- src/network/networkctl-link-info.h | 2 +- src/network/networkctl-lldp.h | 2 +- src/network/networkctl-status-system.h | 2 +- src/network/networkctl-util.h | 2 +- src/network/networkctl.h | 2 +- src/network/networkd-address.h | 2 +- src/network/networkd-bridge-fdb.h | 2 +- src/network/networkd-forward.h | 2 +- src/network/networkd-link.h | 2 +- src/network/tc/drr.h | 2 +- src/network/tc/ets.h | 2 +- src/network/tc/fifo.h | 2 +- src/network/tc/fq-codel.h | 2 +- src/network/tc/fq-pie.h | 2 +- src/network/tc/fq.h | 2 +- src/network/tc/gred.h | 2 +- src/network/tc/hhf.h | 2 +- src/network/tc/htb.h | 2 +- src/network/tc/mq.c | 2 +- src/network/tc/mq.h | 2 +- src/network/tc/multiq.h | 2 +- src/network/tc/netem.h | 2 +- src/network/tc/pie.h | 2 +- src/network/tc/qfq.h | 2 +- src/network/tc/sfb.h | 2 +- src/network/tc/sfq.h | 2 +- src/network/tc/tbf.h | 2 +- src/network/tc/tc-util.h | 2 +- src/network/tc/teql.h | 2 +- src/network/wait-online/dns-configuration.h | 2 +- src/network/wait-online/wait-online-link.h | 2 +- src/network/wait-online/wait-online-manager.h | 2 +- src/nspawn/nspawn-bind-user.h | 2 +- src/nspawn/nspawn-cgroup.h | 2 +- src/nspawn/nspawn-expose-ports.h | 2 +- src/nspawn/nspawn-mount.h | 2 +- src/nspawn/nspawn-network.h | 2 +- src/nspawn/nspawn-oci.h | 2 +- src/nspawn/nspawn-register.h | 2 +- src/nspawn/nspawn-seccomp.h | 2 +- src/nspawn/nspawn-settings.h | 2 +- src/nspawn/nspawn-setuid.h | 2 +- src/nspawn/nspawn-stub-pid1.h | 2 +- src/nspawn/nspawn.h | 2 +- src/nsresourced/nsresourced-manager.h | 2 +- src/nsresourced/userns-registry.h | 2 +- src/nsresourced/userns-restrict.h | 2 +- src/nss-systemd/nss-systemd.h | 2 +- src/nss-systemd/userdb-glue.h | 2 +- src/oom/oomd-manager-bus.h | 2 +- src/oom/oomd-manager.h | 2 +- src/oom/oomd-util.h | 2 +- src/pcrlock/pcrlock-firmware.h | 2 +- src/portable/portable.h | 2 +- src/portable/portabled-forward.h | 2 +- src/resolve/dns-type.h | 2 +- src/resolve/resolvectl.h | 2 +- src/resolve/resolved-dns-scope.h | 2 +- src/resolve/resolved-dns-server.h | 2 +- src/resolve/resolved-dns-stream.h | 2 +- src/resolve/resolved-dnssd-bus.h | 2 +- src/resolve/resolved-forward.h | 2 +- src/resolve/resolved-manager.h | 2 +- src/sbsign/authenticode.h | 2 +- src/shared/acl-util.h | 2 +- src/shared/acpi-fpdt.h | 2 +- src/shared/apparmor-util.h | 2 +- src/shared/ask-password-agent.h | 2 +- src/shared/ask-password-api.h | 2 +- src/shared/async.h | 2 +- src/shared/barrier.h | 2 +- src/shared/base-filesystem.h | 2 +- src/shared/battery-util.h | 2 +- src/shared/bitmap.h | 2 +- src/shared/blkid-util.h | 2 +- src/shared/blockdev-list.h | 2 +- src/shared/blockdev-util.h | 2 +- src/shared/bond-util.h | 2 +- src/shared/boot-entry.h | 2 +- src/shared/boot-timestamps.h | 2 +- src/shared/bootspec.h | 2 +- src/shared/bpf-dlopen.h | 2 +- src/shared/bpf-link.h | 2 +- src/shared/bpf-program.h | 2 +- src/shared/bridge-util.h | 2 +- src/shared/btrfs-util.h | 2 +- src/shared/bus-get-properties.h | 2 +- src/shared/bus-locator.h | 2 +- src/shared/bus-log-control-api.h | 2 +- src/shared/bus-map-properties.h | 2 +- src/shared/bus-message-util.h | 2 +- src/shared/bus-object.h | 2 +- src/shared/bus-polkit.h | 2 +- src/shared/bus-print-properties.h | 2 +- src/shared/bus-unit-procs.h | 2 +- src/shared/bus-unit-util.h | 2 +- src/shared/bus-util.h | 2 +- src/shared/bus-wait-for-jobs.h | 2 +- src/shared/bus-wait-for-units.h | 2 +- src/shared/calendarspec.h | 2 +- src/shared/cgroup-setup.h | 2 +- src/shared/cgroup-show.h | 2 +- src/shared/chown-recursive.h | 2 +- src/shared/clean-ipc.h | 2 +- src/shared/color-util.h | 2 +- src/shared/common-signal.h | 2 +- src/shared/compare-operator.h | 2 +- src/shared/condition.h | 2 +- src/shared/conf-parser.h | 2 +- src/shared/copy.h | 2 +- src/shared/coredump-util.h | 2 +- src/shared/cpu-set-util.h | 2 +- src/shared/creds-util.h | 2 +- src/shared/cryptsetup-fido2.h | 2 +- src/shared/cryptsetup-tpm2.h | 2 +- src/shared/cryptsetup-util.h | 2 +- src/shared/daemon-util.h | 2 +- src/shared/data-fd-util.h | 2 +- src/shared/dev-setup.h | 2 +- src/shared/device-nodes.h | 2 +- src/shared/discover-image.h | 2 +- src/shared/dissect-image.h | 2 +- src/shared/dns-domain.h | 2 +- src/shared/dropin.h | 2 +- src/shared/edit-util.h | 2 +- src/shared/efi-api.h | 2 +- src/shared/efi-loader.h | 2 +- src/shared/elf-util.h | 2 +- src/shared/ethtool-util.h | 2 +- src/shared/exec-util.h | 2 +- src/shared/exit-status.h | 2 +- src/shared/extension-util.h | 2 +- src/shared/factory-reset.h | 2 +- src/shared/fdisk-util.h | 2 +- src/shared/fdset.h | 2 +- src/shared/fido2-util.h | 2 +- src/shared/find-esp.h | 2 +- src/shared/firewall-util.h | 2 +- src/shared/fork-notify.h | 2 +- src/shared/format-table.h | 2 +- src/shared/fstab-util.h | 2 +- src/shared/generator.h | 2 +- src/shared/geneve-util.h | 2 +- src/shared/gpt.h | 2 +- src/shared/group-record.h | 2 +- src/shared/hibernate-util.h | 2 +- src/shared/hostname-setup.h | 2 +- src/shared/hwdb-util.h | 2 +- src/shared/id128-print.h | 2 +- src/shared/idn-util.h | 2 +- src/shared/ima-util.h | 2 +- src/shared/image-policy.h | 2 +- src/shared/import-util.h | 2 +- src/shared/in-addr-prefix-util.h | 2 +- src/shared/install-file.h | 2 +- src/shared/install-printf.h | 2 +- src/shared/install.h | 2 +- src/shared/ioprio-util.h | 2 +- src/shared/ip-protocol-list.h | 2 +- src/shared/ipvlan-util.h | 2 +- src/shared/journal-file-util.h | 2 +- src/shared/journal-importer.h | 2 +- src/shared/journal-util.h | 2 +- src/shared/kbd-util.h | 2 +- src/shared/kernel-config.h | 2 +- src/shared/kernel-image.h | 2 +- src/shared/killall.h | 2 +- src/shared/label-util.h | 2 +- src/shared/libarchive-util.h | 2 +- src/shared/libaudit-util.h | 2 +- src/shared/libcrypt-util.h | 2 +- src/shared/libfido2-util.h | 2 +- src/shared/libmount-util.h | 2 +- src/shared/local-addresses.h | 2 +- src/shared/locale-setup.h | 2 +- src/shared/logs-show.h | 2 +- src/shared/loop-util.h | 2 +- src/shared/machine-bind-user.h | 2 +- src/shared/machine-credential.h | 2 +- src/shared/machine-id-setup.h | 2 +- src/shared/machine-pool.h | 2 +- src/shared/macvlan-util.h | 2 +- src/shared/main-func.h | 2 +- src/shared/mkdir-label.h | 2 +- src/shared/mkfs-util.h | 2 +- src/shared/module-util.h | 2 +- src/shared/mount-setup.h | 2 +- src/shared/mount-util.h | 2 +- src/shared/net-condition.h | 2 +- src/shared/netif-naming-scheme.h | 2 +- src/shared/netif-sriov.h | 2 +- src/shared/netif-util.h | 2 +- src/shared/notify-recv.h | 2 +- src/shared/nsflags.h | 2 +- src/shared/nsresource.h | 2 +- src/shared/nss-util.h | 2 +- src/shared/numa-util.h | 2 +- src/shared/open-file.h | 2 +- src/shared/openssl-util.h | 2 +- src/shared/osc-context.h | 2 +- src/shared/output-mode.h | 2 +- src/shared/pager.h | 2 +- src/shared/pam-util.h | 2 +- src/shared/parse-argument.h | 2 +- src/shared/parse-helpers.h | 2 +- src/shared/password-quality-util-passwdqc.h | 2 +- src/shared/password-quality-util-pwquality.h | 2 +- src/shared/pcre2-util.h | 2 +- src/shared/pkcs11-util.h | 2 +- src/shared/plymouth-util.h | 2 +- src/shared/polkit-agent.h | 2 +- src/shared/portable-util.h | 2 +- src/shared/pretty-print.h | 2 +- src/shared/prompt-util.h | 2 +- src/shared/ptyfwd.h | 2 +- src/shared/qrcode-util.h | 2 +- src/shared/quota-util.h | 2 +- src/shared/reboot-util.h | 2 +- src/shared/recovery-key.h | 2 +- src/shared/resize-fs.h | 2 +- src/shared/resolve-util.h | 2 +- src/shared/rm-rf.h | 2 +- src/shared/seccomp-util.h | 2 +- src/shared/securebits-util.h | 2 +- src/shared/selinux-util.h | 2 +- src/shared/serialize.h | 2 +- src/shared/service-util.h | 2 +- src/shared/shared-forward.h | 72 ++++ src/shared/shift-uid.h | 2 +- src/shared/sleep-config.h | 2 +- src/shared/smack-util.h | 2 +- src/shared/smbios11.h | 2 +- src/shared/socket-netlink.h | 2 +- src/shared/specifier.h | 2 +- src/shared/switch-root.h | 2 +- src/shared/test-tables.h | 2 +- src/shared/tests.h | 2 +- src/shared/tmpfile-util-label.h | 2 +- src/shared/tomoyo-util.h | 2 +- src/shared/tpm2-event-log.h | 2 +- src/shared/tpm2-util.h | 2 +- src/shared/udev-util.h | 2 +- src/shared/unit-file.h | 2 +- src/shared/user-record-nss.h | 2 +- src/shared/user-record-show.h | 2 +- src/shared/user-record.h | 2 +- src/shared/userdb-dropin.h | 2 +- src/shared/userdb.h | 2 +- src/shared/utmp-wtmp.h | 2 +- src/shared/varlink-serialize.h | 2 +- src/shared/vconsole-util.h | 2 +- src/shared/verb-log-control.h | 2 +- src/shared/verbs.h | 2 +- src/shared/vlan-util.h | 2 +- src/shared/volatile-util.h | 2 +- src/shared/vpick.h | 2 +- src/shared/wall.h | 2 +- src/shared/watchdog.h | 2 +- src/shared/web-util.h | 2 +- src/shared/wifi-util.h | 2 +- src/shared/xml.h | 2 +- src/shutdown/detach-dm.h | 2 +- src/shutdown/detach-loopback.h | 2 +- src/shutdown/detach-md.h | 2 +- src/shutdown/detach-swap.h | 2 +- src/shutdown/umount.h | 2 +- src/systemctl/systemctl-list-machines.h | 2 +- src/systemctl/systemctl.h | 2 +- src/sysupdate/sysupdate-forward.h | 2 +- src/sysupdate/sysupdate-update-set-flags.h | 2 +- src/test/nss-test-util.h | 2 +- src/test/test-dlopen.c | 2 +- src/test/test-sizeof.c | 2 +- src/timedate/hwclock-util.h | 2 +- src/timesync/timesyncd-forward.h | 2 +- src/tmpfiles/offline-passwd.h | 2 +- src/udev/fido_id/fido_id_desc.h | 2 +- src/udev/mtd_probe/mtd_probe.h | 2 +- src/udev/net/link-config.h | 2 +- src/udev/udev-builtin.h | 2 +- src/udev/udev-error.h | 2 +- src/udev/udev-forward.h | 2 +- src/udev/udev-manager.h | 2 +- src/udev/udev-node.h | 2 +- src/udev/udev-trace.h | 2 +- src/udev/udevadm-util.h | 2 +- src/udev/udevadm.h | 2 +- src/userdb/userdbd-manager.h | 2 +- src/vmspawn/vmspawn-mount.h | 2 +- src/vmspawn/vmspawn-register.h | 2 +- src/vmspawn/vmspawn-scope.h | 2 +- src/vmspawn/vmspawn-settings.h | 2 +- src/vmspawn/vmspawn-util.h | 2 +- .../xdg-autostart-service.h | 2 +- 597 files changed, 944 insertions(+), 927 deletions(-) create mode 100644 src/basic/basic-forward.h delete mode 100644 src/basic/forward.h create mode 100644 src/libsystemd/sd-common/sd-forward.h create mode 100644 src/shared/shared-forward.h diff --git a/docs/CODING_STYLE.md b/docs/CODING_STYLE.md index 71ebecaf35..ccbe415acd 100644 --- a/docs/CODING_STYLE.md +++ b/docs/CODING_STYLE.md @@ -250,9 +250,9 @@ SPDX-License-Identifier: LGPL-2.1-or-later inline functions that require the full definition of a struct into the implementation file so that only a forward declaration of the struct is required and not the full definition. - - `src/basic/forward.h` contains forward declarations for common types. If - possible, only include `forward.h` in header files which makes circular - header dependencies a non-issue. + - `src/basic/basic-forward.h` contains forward declarations for common types. + If possible, only include `basic-forward.h` in header files which makes + circular header dependencies a non-issue. Bad: @@ -319,13 +319,21 @@ SPDX-License-Identifier: LGPL-2.1-or-later incremental builds as much as possible. To avoid having to include other headers in header files, always include - `forward.h` in each header file and then add other required includes as - needed. `forward.h` already includes generic headers and contains forward - declarations for common types which should be sufficient for most header - files. For each extra include you add on top of `forward.h`, check if it can - be replaced by adding another forward declaration to `forward.h`. Depending on - the daemon, there might be a specific forward header to include (e.g. - `resolved-forward.h` for systemd-resolved header files). + the corresponding forward declaration header in each header file and then add + other required includes as needed. The forward declaration header already + includes generic headers and contains forward declarations for common types + which should be sufficient for most header files. For each extra include you + add on top of, check if it can be replaced by adding another forward + declaration to the forward declaration header. Depending on the daemon, there + might be a specific forward header to include (e.g. `resolved-forward.h` for + systemd-resolved header files). + + For common code, there are three different forward declaration headers: + + - `src/basic`: `basic-forward.h` + - `src/libsystemd`: `sd-forward.h` + - `src/libsystemd-network`: `sd-forward.h` + - `src/shared`: `shared-forward.h` Header files that extend other header files can include the original header file. For example, `iovec-util.h` includes `iovec-fundamental.h` and @@ -352,7 +360,7 @@ SPDX-License-Identifier: LGPL-2.1-or-later ```c // source.h - #include "forward.h" + #include "basic-forward.h" void my_function_that_logs(size_t sz); diff --git a/meson.build b/meson.build index d95dce86d5..80ea425259 100644 --- a/meson.build +++ b/meson.build @@ -2083,6 +2083,7 @@ basic_includes = [ libsystemd_includes = [basic_includes, include_directories( 'src/libsystemd/sd-bus', + 'src/libsystemd/sd-common', 'src/libsystemd/sd-device', 'src/libsystemd/sd-event', 'src/libsystemd/sd-hwdb', diff --git a/src/analyze/analyze-time-data.h b/src/analyze/analyze-time-data.h index 8fa8e2e475..b9dcc46d6c 100644 --- a/src/analyze/analyze-time-data.h +++ b/src/analyze/analyze-time-data.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "unit-def.h" typedef struct BootTimes { diff --git a/src/analyze/analyze-verify-util.h b/src/analyze/analyze-verify-util.h index ac54aa7a84..66fb2acd5a 100644 --- a/src/analyze/analyze-verify-util.h +++ b/src/analyze/analyze-verify-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct ExecCommand ExecCommand; typedef struct Unit Unit; diff --git a/src/analyze/analyze.h b/src/analyze/analyze.h index d5b7bfcb82..b987e272ce 100644 --- a/src/analyze/analyze.h +++ b/src/analyze/analyze.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum RecursiveErrors RecursiveErrors; diff --git a/src/basic/af-list.h b/src/basic/af-list.h index 6b7154cb59..b2948e916a 100644 --- a/src/basic/af-list.h +++ b/src/basic/af-list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" const char* af_to_name(int id) _const_; int af_from_name(const char *name) _pure_; diff --git a/src/basic/alloc-util.h b/src/basic/alloc-util.h index 263815c528..577a8174fa 100644 --- a/src/basic/alloc-util.h +++ b/src/basic/alloc-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" #include "memory-util.h" #if HAS_FEATURE_MEMORY_SANITIZER diff --git a/src/basic/ansi-color.h b/src/basic/ansi-color.h index de86d36150..a5eea226a9 100644 --- a/src/basic/ansi-color.h +++ b/src/basic/ansi-color.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Limits the use of ANSI colors to a subset. */ typedef enum ColorMode { diff --git a/src/basic/architecture.h b/src/basic/architecture.h index 3793415e5d..261a9288e8 100644 --- a/src/basic/architecture.h +++ b/src/basic/architecture.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: keep */ -#include "forward.h" +#include "basic-forward.h" /* A cleaned up architecture definition. We don't want to get lost in * processor features, models, generations or even ABIs. Hence we diff --git a/src/basic/argv-util.h b/src/basic/argv-util.h index d79bd6f222..392f7873a4 100644 --- a/src/basic/argv-util.h +++ b/src/basic/argv-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" extern int saved_argc; extern char **saved_argv; diff --git a/src/basic/arphrd-util.h b/src/basic/arphrd-util.h index 97a1c0b248..4c2fd207d1 100644 --- a/src/basic/arphrd-util.h +++ b/src/basic/arphrd-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" const char* arphrd_to_name(int id) _const_; int arphrd_from_name(const char *name) _pure_; diff --git a/src/basic/audit-util.h b/src/basic/audit-util.h index ff9ce72e0b..7f06d4bb88 100644 --- a/src/basic/audit-util.h +++ b/src/basic/audit-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define AUDIT_SESSION_INVALID UINT32_MAX diff --git a/src/basic/basic-forward.h b/src/basic/basic-forward.h new file mode 100644 index 0000000000..38c3098f32 --- /dev/null +++ b/src/basic/basic-forward.h @@ -0,0 +1,134 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ +#pragma once + +/* IWYU pragma: always_keep */ + +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ +#include /* IWYU pragma: export */ + +#include "assert-util.h" /* IWYU pragma: export */ +#include "cleanup-util.h" /* IWYU pragma: export */ +#include "macro.h" /* IWYU pragma: export */ + +/* Generic types */ + +typedef uint64_t usec_t; +typedef uint64_t nsec_t; + +/* Libc/Linux forward declarations */ + +struct dirent; +struct ether_addr; +struct fiemap; +struct file_handle; +struct glob_t; +struct group; +struct icmp6_hdr; +struct in_addr; +struct in6_addr; +struct inotify_event; +struct iovec; +struct mount_attr; +struct msghdr; +struct passwd; +struct pollfd; +struct rlimit; +struct sgrp; +struct shadow; +struct signalfd_siginfo; +struct siphash; +struct sockaddr; +struct spwd; +struct stat; +struct statfs; +struct statx_timestamp; +struct statx; +struct termios; +struct tm; +struct ucred; + +/* To forward declare FILE and DIR, we have to declare the internal struct names for them. Since these are + * used for C++ symbol name mangling, they're effectively part of the ABI and won't actually change. */ +typedef struct _IO_FILE FILE; +typedef struct __dirstream DIR; + +/* 3rd-party library forward declarations */ + +enum bpf_map_type; + +struct fdisk_context; +struct fdisk_table; +struct crypt_device; + +/* basic/ forward declarations */ + +typedef void (*hash_func_t)(const void *p, struct siphash *state); +typedef int (*compare_func_t)(const void *a, const void *b); +typedef compare_func_t comparison_fn_t; +typedef int (*comparison_userdata_fn_t)(const void *, const void *, void *); + +struct hash_ops; +struct hw_addr_data; +struct in_addr_data; +struct iovec_wrapper; +union in_addr_union; +union sockaddr_union; + +typedef enum CGroupFlags CGroupFlags; +typedef enum CGroupMask CGroupMask; +typedef enum ChaseFlags ChaseFlags; +typedef enum ExtractFlags ExtractFlags; +typedef enum Glyph Glyph; +typedef enum ImageClass ImageClass; +typedef enum JobMode JobMode; +typedef enum RuntimeScope RuntimeScope; +typedef enum TimestampStyle TimestampStyle; +typedef enum UnitActiveState UnitActiveState; +typedef enum UnitDependency UnitDependency; +typedef enum UnitType UnitType; + +typedef struct Hashmap Hashmap; +typedef struct HashmapBase HashmapBase; +typedef struct IteratedCache IteratedCache; +typedef struct Iterator Iterator; +typedef struct OrderedHashmap OrderedHashmap; +typedef struct OrderedSet OrderedSet; +typedef struct Set Set; + +typedef struct dual_timestamp dual_timestamp; +typedef struct triple_timestamp triple_timestamp; +typedef struct ConfFile ConfFile; +typedef struct LockFile LockFile; +typedef struct PidRef PidRef; +typedef struct Prioq Prioq; +typedef struct RateLimit RateLimit; +typedef struct SocketAddress SocketAddress; + +/* Constants */ + +/* We duplicate various commonly used constants here so we can keep most static inline functions without + * having to include the full header that provides these constants. */ + +#define AT_FDCWD -100 +#define AT_EMPTY_PATH 0x1000 +#define AT_SYMLINK_FOLLOW 0x400 +#define AT_SYMLINK_NOFOLLOW 0x100 + +#define MODE_INVALID ((mode_t) -1) + +#define UID_INVALID ((uid_t) -1) +#define GID_INVALID ((gid_t) -1) + +#define USEC_INFINITY ((usec_t) UINT64_MAX) +#define NSEC_INFINITY ((nsec_t) UINT64_MAX) + +/* MAX_ERRNO is defined as 4095 in linux/err.h. We use the same value here. */ +#define ERRNO_MAX 4095 diff --git a/src/basic/bitfield.h b/src/basic/bitfield.h index a06841a649..96b4684871 100644 --- a/src/basic/bitfield.h +++ b/src/basic/bitfield.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Bit index (0-based) to mask of specified type. Assertion failure if index is out of range. */ #define _INDEX_TO_MASK(type, i, uniq) \ diff --git a/src/basic/btrfs.h b/src/basic/btrfs.h index 0b3ae1082c..1493270489 100644 --- a/src/basic/btrfs.h +++ b/src/basic/btrfs.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "basic-forward.h" int btrfs_validate_subvolume_name(const char *name); diff --git a/src/basic/build.h b/src/basic/build.h index 3f1211e708..83fac462cd 100644 --- a/src/basic/build.h +++ b/src/basic/build.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" extern const char* const systemd_features; diff --git a/src/basic/bus-label.h b/src/basic/bus-label.h index 22dd796984..890f34716b 100644 --- a/src/basic/bus-label.h +++ b/src/basic/bus-label.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" char* bus_label_escape(const char *s); char* bus_label_unescape_n(const char *f, size_t l); diff --git a/src/basic/capability-list.h b/src/basic/capability-list.h index ea80ca3d5c..e588e87dee 100644 --- a/src/basic/capability-list.h +++ b/src/basic/capability-list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Space for capability_to_string() in case we write out a numeric capability because we don't know the name * for it. "0x3e" is the largest string we might output, in both sensese of the word "largest": two chars for diff --git a/src/basic/capability-util.h b/src/basic/capability-util.h index 3c265e4064..09b612b1e6 100644 --- a/src/basic/capability-util.h +++ b/src/basic/capability-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" /* Special marker used when storing a capabilities mask as "unset". This would need to be updated as soon as * Linux learns more than 63 caps. */ diff --git a/src/basic/capsule-util.h b/src/basic/capsule-util.h index 02b00220f1..1ed80a908b 100644 --- a/src/basic/capsule-util.h +++ b/src/basic/capsule-util.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int capsule_name_is_valid(const char *name); diff --git a/src/basic/cgroup-util.h b/src/basic/cgroup-util.h index f69ebbf953..8ed8d7704c 100644 --- a/src/basic/cgroup-util.h +++ b/src/basic/cgroup-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define SYSTEMD_CGROUP_CONTROLLER_LEGACY "name=systemd" #define SYSTEMD_CGROUP_CONTROLLER_HYBRID "name=unified" diff --git a/src/basic/chase.h b/src/basic/chase.h index 554ab6cadd..948b83aad0 100644 --- a/src/basic/chase.h +++ b/src/basic/chase.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum ChaseFlags { CHASE_PREFIX_ROOT = 1 << 0, /* The specified path will be prefixed by the specified root before beginning the iteration */ diff --git a/src/basic/chattr-util.h b/src/basic/chattr-util.h index 543843db2c..1f93b3182d 100644 --- a/src/basic/chattr-util.h +++ b/src/basic/chattr-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" /* The chattr() flags to apply when creating a new file *before* writing to it. In particular, flags such as * FS_NOCOW_FL don't work if applied a-posteriori. All other flags are fine (or even necessary, think diff --git a/src/basic/compress.h b/src/basic/compress.h index dcd0e4a734..d3a09126ef 100644 --- a/src/basic/compress.h +++ b/src/basic/compress.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum Compression { COMPRESSION_NONE, diff --git a/src/basic/conf-files.h b/src/basic/conf-files.h index c5cad2084c..f6e63120e5 100644 --- a/src/basic/conf-files.h +++ b/src/basic/conf-files.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" typedef enum ConfFilesFlags { CONF_FILES_EXECUTABLE = 1 << 0, diff --git a/src/basic/confidential-virt.h b/src/basic/confidential-virt.h index 708b3ab604..67206cbb29 100644 --- a/src/basic/confidential-virt.h +++ b/src/basic/confidential-virt.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum ConfidentialVirtualization { CONFIDENTIAL_VIRTUALIZATION_NONE = 0, diff --git a/src/basic/devnum-util.h b/src/basic/devnum-util.h index 4b4a81f3ca..8588b434fb 100644 --- a/src/basic/devnum-util.h +++ b/src/basic/devnum-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" int parse_devnum(const char *s, dev_t *ret); diff --git a/src/basic/dirent-util.h b/src/basic/dirent-util.h index 1f305930c6..521dbd5de7 100644 --- a/src/basic/dirent-util.h +++ b/src/basic/dirent-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" #include "path-util.h" bool dirent_is_file(const struct dirent *de) _pure_; diff --git a/src/basic/dlfcn-util.h b/src/basic/dlfcn-util.h index 4b054e8cb3..e9ecd8d1e5 100644 --- a/src/basic/dlfcn-util.h +++ b/src/basic/dlfcn-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" void* safe_dlclose(void *dl); diff --git a/src/basic/dns-def.h b/src/basic/dns-def.h index 5c0f031df7..04205e4665 100644 --- a/src/basic/dns-def.h +++ b/src/basic/dns-def.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Length of a single label, with all escaping removed, excluding any trailing dot or NUL byte */ #define DNS_LABEL_MAX 63 diff --git a/src/basic/efivars.h b/src/basic/efivars.h index dd049283f5..e4cbf53f55 100644 --- a/src/basic/efivars.h +++ b/src/basic/efivars.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "sd-id128.h" diff --git a/src/basic/env-file.h b/src/basic/env-file.h index b17a1804cf..78d47f4980 100644 --- a/src/basic/env-file.h +++ b/src/basic/env-file.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int parse_env_filev(FILE *f, const char *fname, va_list ap); int parse_env_file_fdv(int fd, const char *fname, va_list ap); diff --git a/src/basic/env-util.h b/src/basic/env-util.h index 9f55a91fff..28338a1458 100644 --- a/src/basic/env-util.h +++ b/src/basic/env-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" size_t sc_arg_max(void); diff --git a/src/basic/errno-list.h b/src/basic/errno-list.h index 2064afa0f4..cd96573ea8 100644 --- a/src/basic/errno-list.h +++ b/src/basic/errno-list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" const char* errno_name_no_fallback(int id) _const_; int errno_from_name(const char *name) _pure_; diff --git a/src/basic/errno-util.h b/src/basic/errno-util.h index 5fe337cfb1..db13cd364a 100644 --- a/src/basic/errno-util.h +++ b/src/basic/errno-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" /* strerror(3) says that glibc uses a maximum length of 1024 bytes. */ #define ERRNO_BUF_LEN 1024 diff --git a/src/basic/escape.h b/src/basic/escape.h index 3d8a1890cf..a8b68fa75c 100644 --- a/src/basic/escape.h +++ b/src/basic/escape.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* What characters are special in the shell? */ /* must be escaped outside and inside double-quotes */ diff --git a/src/basic/ether-addr-util.h b/src/basic/ether-addr-util.h index d2c6df444a..cf014a9527 100644 --- a/src/basic/ether-addr-util.h +++ b/src/basic/ether-addr-util.h @@ -5,7 +5,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" /* This is MAX_ADDR_LEN as defined in linux/netdevice.h, but net/if_arp.h * defines a macro of the same name with a much lower size. */ diff --git a/src/basic/extract-word.h b/src/basic/extract-word.h index 2740de9189..17b2f1a396 100644 --- a/src/basic/extract-word.h +++ b/src/basic/extract-word.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum ExtractFlags { EXTRACT_RELAX = 1 << 0, /* Allow unbalanced quote and eat up trailing backslash. */ diff --git a/src/basic/fd-util.h b/src/basic/fd-util.h index 94caf06e2f..95184c5783 100644 --- a/src/basic/fd-util.h +++ b/src/basic/fd-util.h @@ -5,7 +5,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" /* maximum length of fdname */ #define FDNAME_MAX 255 diff --git a/src/basic/fileio.h b/src/basic/fileio.h index 4d798e7e64..96a8773620 100644 --- a/src/basic/fileio.h +++ b/src/basic/fileio.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define LONG_LINE_MAX (1U*1024U*1024U) diff --git a/src/basic/filesystems.h b/src/basic/filesystems.h index 4d6d7e2641..0a6e97ef47 100644 --- a/src/basic/filesystems.h +++ b/src/basic/filesystems.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "stat-util.h" #define FILESYSTEM_MAGIC_MAX 10 diff --git a/src/basic/format-util.h b/src/basic/format-util.h index ab3328e1d2..c603e99d82 100644 --- a/src/basic/format-util.h +++ b/src/basic/format-util.h @@ -2,7 +2,7 @@ #pragma once #include "cgroup-util.h" -#include "forward.h" +#include "basic-forward.h" #include "stdio-util.h" assert_cc(sizeof(pid_t) == sizeof(int32_t)); diff --git a/src/basic/forward.h b/src/basic/forward.h deleted file mode 100644 index a9fda3b917..0000000000 --- a/src/basic/forward.h +++ /dev/null @@ -1,325 +0,0 @@ -/* SPDX-License-Identifier: LGPL-2.1-or-later */ -#pragma once - -/* IWYU pragma: always_keep */ - -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ -#include /* IWYU pragma: export */ - -#include "assert-util.h" /* IWYU pragma: export */ -#include "cleanup-util.h" /* IWYU pragma: export */ -#include "macro.h" /* IWYU pragma: export */ - -/* Generic types */ - -typedef uint64_t usec_t; -typedef uint64_t nsec_t; - -/* Libc/Linux forward declarations */ - -struct dirent; -struct ether_addr; -struct fiemap; -struct file_handle; -struct glob_t; -struct group; -struct icmp6_hdr; -struct in_addr; -struct in6_addr; -struct inotify_event; -struct iovec; -struct mount_attr; -struct msghdr; -struct passwd; -struct pollfd; -struct rlimit; -struct sgrp; -struct shadow; -struct signalfd_siginfo; -struct siphash; -struct sockaddr; -struct spwd; -struct stat; -struct statfs; -struct statx_timestamp; -struct statx; -struct termios; -struct tm; -struct ucred; - -/* To forward declare FILE and DIR, we have to declare the internal struct names for them. Since these are - * used for C++ symbol name mangling, they're effectively part of the ABI and won't actually change. */ -typedef struct _IO_FILE FILE; -typedef struct __dirstream DIR; - -/* 3rd-party library forward declarations */ - -enum bpf_map_type; - -struct fdisk_context; -struct fdisk_table; -struct crypt_device; - -/* basic/ forward declarations */ - -typedef void (*hash_func_t)(const void *p, struct siphash *state); -typedef int (*compare_func_t)(const void *a, const void *b); -typedef compare_func_t comparison_fn_t; -typedef int (*comparison_userdata_fn_t)(const void *, const void *, void *); - -struct hash_ops; -struct hw_addr_data; -struct in_addr_data; -struct iovec_wrapper; -union in_addr_union; -union sockaddr_union; - -typedef enum CGroupFlags CGroupFlags; -typedef enum CGroupMask CGroupMask; -typedef enum ChaseFlags ChaseFlags; -typedef enum ExtractFlags ExtractFlags; -typedef enum Glyph Glyph; -typedef enum ImageClass ImageClass; -typedef enum JobMode JobMode; -typedef enum RuntimeScope RuntimeScope; -typedef enum TimestampStyle TimestampStyle; -typedef enum UnitActiveState UnitActiveState; -typedef enum UnitDependency UnitDependency; - -typedef struct Hashmap Hashmap; -typedef struct HashmapBase HashmapBase; -typedef struct IteratedCache IteratedCache; -typedef struct Iterator Iterator; -typedef struct OrderedHashmap OrderedHashmap; -typedef struct OrderedSet OrderedSet; -typedef struct Set Set; - -typedef struct dual_timestamp dual_timestamp; -typedef struct triple_timestamp triple_timestamp; -typedef struct ConfFile ConfFile; -typedef struct LockFile LockFile; -typedef struct PidRef PidRef; -typedef struct Prioq Prioq; -typedef struct RateLimit RateLimit; -typedef struct SocketAddress SocketAddress; - -/* libsystemd/ and libsystemd-network/ forward declarations */ - -typedef void (*_sd_destroy_t)(void *userdata); - -typedef union sd_id128 sd_id128_t; - -typedef struct sd_event sd_event; -typedef struct sd_event_source sd_event_source; - -typedef int (*sd_event_handler_t)(sd_event_source *s, void *userdata); -typedef int (*sd_event_io_handler_t)(sd_event_source *s, int fd, uint32_t revents, void *userdata); -typedef int (*sd_event_time_handler_t)(sd_event_source *s, uint64_t usec, void *userdata); -typedef int (*sd_event_signal_handler_t)(sd_event_source *s, const struct signalfd_siginfo *si, void *userdata); -typedef int (*sd_event_inotify_handler_t)(sd_event_source *s, const struct inotify_event *event, void *userdata); -typedef _sd_destroy_t sd_event_destroy_t; - -enum ENUM_TYPE_S64(sd_json_format_flags_t); -enum ENUM_TYPE_S64(sd_json_dispatch_flags_t); -enum ENUM_TYPE_S64(sd_json_variant_type_t); -enum ENUM_TYPE_S64(sd_json_parse_flags_t); - -typedef enum sd_json_format_flags_t sd_json_format_flags_t; -typedef enum sd_json_dispatch_flags_t sd_json_dispatch_flags_t; -typedef enum sd_json_variant_type_t sd_json_variant_type_t; -typedef enum sd_json_parse_flags_t sd_json_parse_flags_t; - -typedef struct sd_json_variant sd_json_variant; - -typedef struct sd_bus sd_bus; -typedef struct sd_bus_error sd_bus_error; -typedef struct sd_bus_error_map sd_bus_error_map; -typedef struct sd_bus_message sd_bus_message; -typedef struct sd_bus_slot sd_bus_slot; -typedef struct sd_bus_creds sd_bus_creds; -typedef struct sd_bus_track sd_bus_track; -typedef struct sd_bus_vtable sd_bus_vtable; - -typedef int (*sd_bus_message_handler_t)(sd_bus_message *m, void *userdata, sd_bus_error *ret_error); -typedef int (*sd_bus_property_get_t)(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *reply, void *userdata, sd_bus_error *ret_error); -typedef int (*sd_bus_property_set_t)(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *value, void *userdata, sd_bus_error *ret_error); -typedef int (*sd_bus_object_find_t)(sd_bus *bus, const char *path, const char *interface, void *userdata, void **ret_found, sd_bus_error *ret_error); -typedef int (*sd_bus_node_enumerator_t)(sd_bus *bus, const char *prefix, void *userdata, char ***ret_nodes, sd_bus_error *ret_error); -typedef int (*sd_bus_track_handler_t)(sd_bus_track *track, void *userdata); -typedef _sd_destroy_t sd_bus_destroy_t; - -enum ENUM_TYPE_S64(sd_device_action_t); - -typedef enum sd_device_action_t sd_device_action_t; - -typedef struct sd_device sd_device; -typedef struct sd_device_enumerator sd_device_enumerator; -typedef struct sd_device_monitor sd_device_monitor; - -typedef struct sd_netlink sd_netlink; -typedef struct sd_netlink_message sd_netlink_message; -typedef struct sd_netlink_slot sd_netlink_slot; - -typedef int (*sd_netlink_message_handler_t)(sd_netlink *nl, sd_netlink_message *m, void *userdata); -typedef _sd_destroy_t sd_netlink_destroy_t; - -typedef struct sd_network_monitor sd_network_monitor; - -enum ENUM_TYPE_S64(sd_dhcp_lease_server_type_t); -enum ENUM_TYPE_S64(sd_lldp_rx_event_t); -enum ENUM_TYPE_S64(sd_lldp_multicast_mode_t); -enum ENUM_TYPE_S64(sd_ndisc_event_t); - -typedef enum sd_dhcp_lease_server_type_t sd_dhcp_lease_server_type_t; -typedef enum sd_lldp_rx_event_t sd_lldp_rx_event_t; -typedef enum sd_lldp_multicast_mode_t sd_lldp_multicast_mode_t; -typedef enum sd_ndisc_event_t sd_ndisc_event_t; - -typedef struct sd_ipv4ll sd_ipv4ll; -typedef struct sd_dhcp_client sd_dhcp_client; -typedef struct sd_dhcp_lease sd_dhcp_lease; -typedef struct sd_dhcp_route sd_dhcp_route; -typedef struct sd_dns_resolver sd_dns_resolver; -typedef struct sd_dhcp_server sd_dhcp_server; -typedef struct sd_ndisc sd_ndisc; -typedef struct sd_radv sd_radv; -typedef struct sd_dhcp6_client sd_dhcp6_client; -typedef struct sd_dhcp6_lease sd_dhcp6_lease; -typedef struct sd_lldp_tx sd_lldp_tx; -typedef struct sd_lldp_rx sd_lldp_rx; -typedef struct sd_lldp_neighbor sd_lldp_neighbor; - -typedef struct ICMP6Packet ICMP6Packet; - -enum ENUM_TYPE_S64(sd_varlink_method_flags_t); -enum ENUM_TYPE_S64(sd_varlink_interface_flags_t); -enum ENUM_TYPE_S64(sd_varlink_symbol_type_t); -enum ENUM_TYPE_S64(sd_varlink_field_type_t); -enum ENUM_TYPE_S64(sd_varlink_field_direction_t); -enum ENUM_TYPE_S64(sd_varlink_field_flags_t); -enum ENUM_TYPE_S64(sd_varlink_idl_format_flags_t); -enum ENUM_TYPE_S64(sd_varlink_reply_flags_t); -enum ENUM_TYPE_S64(sd_varlink_server_flags_t); -enum ENUM_TYPE_S64(sd_varlink_invocation_flags_t); - -typedef enum sd_varlink_method_flags_t sd_varlink_method_flags_t; -typedef enum sd_varlink_interface_flags_t sd_varlink_interface_flags_t; -typedef enum sd_varlink_symbol_type_t sd_varlink_symbol_type_t; -typedef enum sd_varlink_field_type_t sd_varlink_field_type_t; -typedef enum sd_varlink_field_direction_t sd_varlink_field_direction_t; -typedef enum sd_varlink_field_flags_t sd_varlink_field_flags_t; -typedef enum sd_varlink_idl_format_flags_t sd_varlink_idl_format_flags_t; -typedef enum sd_varlink_reply_flags_t sd_varlink_reply_flags_t; -typedef enum sd_varlink_server_flags_t sd_varlink_server_flags_t; -typedef enum sd_varlink_invocation_flags_t sd_varlink_invocation_flags_t; - -typedef struct sd_varlink sd_varlink; -typedef struct sd_varlink_server sd_varlink_server; -typedef struct sd_varlink_field sd_varlink_field; -typedef struct sd_varlink_symbol sd_varlink_symbol; -typedef struct sd_varlink_interface sd_varlink_interface; - -typedef struct sd_journal sd_journal; - -typedef struct sd_resolve sd_resolve; -typedef struct sd_resolve_query sd_resolve_query; - -typedef struct sd_hwdb sd_hwdb; - -/* shared/ forward declarations */ - -typedef int (*copy_progress_bytes_t)(uint64_t n_bytes, uint64_t bytes_per_second, void *userdata); -typedef int (*copy_progress_path_t)(const char *path, const struct stat *st, void *userdata); - -struct local_address; -struct in_addr_prefix; -struct in_addr_full; - -typedef enum AskPasswordFlags AskPasswordFlags; -typedef enum BootEntryTokenType BootEntryTokenType; -typedef enum BusPrintPropertyFlags BusPrintPropertyFlags; -typedef enum BusTransport BusTransport; -typedef enum CatFlags CatFlags; -typedef enum CertificateSourceType CertificateSourceType; -typedef enum DnsCacheMode DnsCacheMode; -typedef enum DnsOverTlsMode DnsOverTlsMode; -typedef enum DnssecMode DnssecMode; -typedef enum Fido2EnrollFlags Fido2EnrollFlags; -typedef enum KeySourceType KeySourceType; -typedef enum LabelFixFlags LabelFixFlags; -typedef enum MountInNamespaceFlags MountInNamespaceFlags; -typedef enum NamePolicy NamePolicy; -typedef enum OutputFlags OutputFlags; -typedef enum OutputMode OutputMode; -typedef enum PagerFlags PagerFlags; -typedef enum PatternCompileCase PatternCompileCase; -typedef enum RemoveFlags RemoveFlags; -typedef enum ResolveSupport ResolveSupport; -typedef enum TPM2Flags TPM2Flags; -typedef enum Tpm2Support Tpm2Support; -typedef enum Tpm2UserspaceEventType Tpm2UserspaceEventType; -typedef enum UnitFileFlags UnitFileFlags; -typedef enum UnitFilePresetMode UnitFilePresetMode; -typedef enum UnitFileState UnitFileState; -typedef enum UnitType UnitType; -typedef enum UserDBFlags UserDBFlags; -typedef enum UserRecordLoadFlags UserRecordLoadFlags; -typedef enum UserStorage UserStorage; - -typedef struct Bitmap Bitmap; -typedef struct BPFProgram BPFProgram; -typedef struct BusObjectImplementation BusObjectImplementation; -typedef struct CalendarSpec CalendarSpec; -typedef struct Condition Condition; -typedef struct ConfigSection ConfigSection; -typedef struct ConfigTableItem ConfigTableItem; -typedef struct CPUSet CPUSet; -typedef struct FDSet FDSet; -typedef struct Fido2HmacSalt Fido2HmacSalt; -typedef struct GroupRecord GroupRecord; -typedef struct Image Image; -typedef struct ImagePolicy ImagePolicy; -typedef struct InstallInfo InstallInfo; -typedef struct LookupPaths LookupPaths; -typedef struct LoopDevice LoopDevice; -typedef struct MachineBindUserContext MachineBindUserContext; -typedef struct MachineCredentialContext MachineCredentialContext; -typedef struct MountOptions MountOptions; -typedef struct OpenFile OpenFile; -typedef struct Pkcs11EncryptedKey Pkcs11EncryptedKey; -typedef struct Table Table; -typedef struct Tpm2Context Tpm2Context; -typedef struct Tpm2Handle Tpm2Handle; -typedef struct Tpm2PCRValue Tpm2PCRValue; -typedef struct UnitInfo UnitInfo; -typedef struct UserRecord UserRecord; -typedef struct VeritySettings VeritySettings; - -/* Constants */ - -/* We duplicate various commonly used constants here so we can keep most static inline functions without - * having to include the full header that provides these constants. */ - -#define AT_FDCWD -100 -#define AT_EMPTY_PATH 0x1000 -#define AT_SYMLINK_FOLLOW 0x400 -#define AT_SYMLINK_NOFOLLOW 0x100 - -#define MODE_INVALID ((mode_t) -1) - -#define UID_INVALID ((uid_t) -1) -#define GID_INVALID ((gid_t) -1) - -#define USEC_INFINITY ((usec_t) UINT64_MAX) -#define NSEC_INFINITY ((nsec_t) UINT64_MAX) - -/* MAX_ERRNO is defined as 4095 in linux/err.h. We use the same value here. */ -#define ERRNO_MAX 4095 diff --git a/src/basic/fs-util.h b/src/basic/fs-util.h index 1c4b88e53b..5e7ed32a52 100644 --- a/src/basic/fs-util.h +++ b/src/basic/fs-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "lock-util.h" /* The following macros add 1 when converting things, since 0 is a valid mode, while the pointer diff --git a/src/basic/gcrypt-util.h b/src/basic/gcrypt-util.h index 9fab3500a5..147a174da0 100644 --- a/src/basic/gcrypt-util.h +++ b/src/basic/gcrypt-util.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" int dlopen_gcrypt(void); diff --git a/src/basic/glob-util.h b/src/basic/glob-util.h index ea3e869319..7fc13648db 100644 --- a/src/basic/glob-util.h +++ b/src/basic/glob-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" typedef DIR* (*opendir_t)(const char *); diff --git a/src/basic/glyph-util.h b/src/basic/glyph-util.h index 92b325726b..c9582ec61e 100644 --- a/src/basic/glyph-util.h +++ b/src/basic/glyph-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum Glyph { GLYPH_SPACE, diff --git a/src/basic/gunicode.h b/src/basic/gunicode.h index 9bba03ba30..3ee0c4ebbe 100644 --- a/src/basic/gunicode.h +++ b/src/basic/gunicode.h @@ -6,7 +6,7 @@ */ #pragma once -#include "forward.h" +#include "basic-forward.h" char *utf8_prev_char (const char *p); diff --git a/src/basic/hash-funcs.h b/src/basic/hash-funcs.h index 7ce29fbe6c..19af1aa031 100644 --- a/src/basic/hash-funcs.h +++ b/src/basic/hash-funcs.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef void (*hash_func_t)(const void *p, struct siphash *state); typedef int (*compare_func_t)(const void *a, const void *b); diff --git a/src/basic/hashmap.h b/src/basic/hashmap.h index 3e8fc28ee0..6ae9241760 100644 --- a/src/basic/hashmap.h +++ b/src/basic/hashmap.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "hash-funcs.h" #include "iterator.h" diff --git a/src/basic/hexdecoct.h b/src/basic/hexdecoct.h index 5841af0b7a..755a0798cd 100644 --- a/src/basic/hexdecoct.h +++ b/src/basic/hexdecoct.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" char octchar(int x) _const_; int unoctchar(char c) _const_; diff --git a/src/basic/hmac.h b/src/basic/hmac.h index fd474f7649..35faf14f26 100644 --- a/src/basic/hmac.h +++ b/src/basic/hmac.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "sha256.h" /* Unoptimized implementation based on FIPS 198. 'res' has to be allocated by diff --git a/src/basic/hostname-util.h b/src/basic/hostname-util.h index 3cbf0966ea..e9e605cab0 100644 --- a/src/basic/hostname-util.h +++ b/src/basic/hostname-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "strv.h" char* get_default_hostname_raw(void); diff --git a/src/basic/in-addr-util.h b/src/basic/in-addr-util.h index cb76ef221c..4148fa2e67 100644 --- a/src/basic/in-addr-util.h +++ b/src/basic/in-addr-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" union in_addr_union { struct in_addr in; diff --git a/src/basic/initrd-util.h b/src/basic/initrd-util.h index 29e47828da..387c2c6717 100644 --- a/src/basic/initrd-util.h +++ b/src/basic/initrd-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" bool in_initrd(void); void in_initrd_force(bool value); diff --git a/src/basic/inotify-util.h b/src/basic/inotify-util.h index a509a97f50..ebd3809906 100644 --- a/src/basic/inotify-util.h +++ b/src/basic/inotify-util.h @@ -4,7 +4,7 @@ #include /* IWYU pragma: export */ #include -#include "forward.h" +#include "basic-forward.h" #define INOTIFY_EVENT_MAX (offsetof(struct inotify_event, name) + NAME_MAX + 1) diff --git a/src/basic/io-util.h b/src/basic/io-util.h index 237a9ff77f..918108c023 100644 --- a/src/basic/io-util.h +++ b/src/basic/io-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int flush_fd(int fd); diff --git a/src/basic/iovec-util.h b/src/basic/iovec-util.h index f1e4be88d4..0d1d4a7a94 100644 --- a/src/basic/iovec-util.h +++ b/src/basic/iovec-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" #include "iovec-util-fundamental.h" /* IWYU pragma: export */ extern const struct iovec iovec_nul_byte; /* Points to a single NUL byte */ diff --git a/src/basic/iovec-wrapper.h b/src/basic/iovec-wrapper.h index 082d7e0ae0..6bc4d3905a 100644 --- a/src/basic/iovec-wrapper.h +++ b/src/basic/iovec-wrapper.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" struct iovec_wrapper { struct iovec *iovec; diff --git a/src/basic/iterator.h b/src/basic/iterator.h index be9e1a9b6b..ecdc5efca4 100644 --- a/src/basic/iterator.h +++ b/src/basic/iterator.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Ideally the Iterator would be an opaque struct, but it is instantiated * by hashmap users, so the definition has to be here. Do not use its fields diff --git a/src/basic/keyring-util.h b/src/basic/keyring-util.h index b8a36a9ad6..2ec12d3583 100644 --- a/src/basic/keyring-util.h +++ b/src/basic/keyring-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" /* Like TAKE_PTR() but for key_serial_t, resetting them to -1 */ #define TAKE_KEY_SERIAL(key_serial) TAKE_GENERIC(key_serial, key_serial_t, -1) diff --git a/src/basic/label.h b/src/basic/label.h index 186f93d697..9f8af5e4bb 100644 --- a/src/basic/label.h +++ b/src/basic/label.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef struct LabelOps { int (*pre)(int dir_fd, const char *path, mode_t mode); diff --git a/src/basic/limits-util.h b/src/basic/limits-util.h index 6049cfa9e9..ef7ce40cde 100644 --- a/src/basic/limits-util.h +++ b/src/basic/limits-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" uint64_t physical_memory(void); uint64_t physical_memory_scale(uint64_t v, uint64_t max); diff --git a/src/basic/list.h b/src/basic/list.h index ee3405f054..d86002f2b3 100644 --- a/src/basic/list.h +++ b/src/basic/list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* The head of the linked list. Use this in the structure that shall * contain the head of the linked list */ diff --git a/src/basic/locale-util.h b/src/basic/locale-util.h index 1ec6d3074e..1524122e09 100644 --- a/src/basic/locale-util.h +++ b/src/basic/locale-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" typedef enum LocaleVariable { /* We don't list LC_ALL here on purpose. People should be diff --git a/src/basic/lock-util.h b/src/basic/lock-util.h index b9643c22a1..d44c4e74df 100644 --- a/src/basic/lock-util.h +++ b/src/basic/lock-util.h @@ -4,7 +4,7 @@ /* Include here so consumers have LOCK_{EX,SH,NB} available. */ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" typedef struct LockFile { int dir_fd; diff --git a/src/basic/log-context.h b/src/basic/log-context.h index a49bddd591..52998707bb 100644 --- a/src/basic/log-context.h +++ b/src/basic/log-context.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "list.h" /* diff --git a/src/basic/log.h b/src/basic/log.h index 544d6e16e1..a07841c6ca 100644 --- a/src/basic/log.h +++ b/src/basic/log.h @@ -5,7 +5,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" typedef enum LogTarget{ LOG_TARGET_CONSOLE, diff --git a/src/basic/login-util.h b/src/basic/login-util.h index fd07ed2c6e..0b4b7b77ca 100644 --- a/src/basic/login-util.h +++ b/src/basic/login-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define SD_LOGIND_ROOT_CHECK_INHIBITORS (UINT64_C(1) << 0) #define SD_LOGIND_REBOOT_VIA_KEXEC (UINT64_C(1) << 1) diff --git a/src/basic/math-util.h b/src/basic/math-util.h index 2cdd655ce8..f3c471b160 100644 --- a/src/basic/math-util.h +++ b/src/basic/math-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" /* On some optimization level, iszero(x) is converted to (x == 0.0), and emits warning -Wfloat-equal. * The argument must be a floating point, i.e. one of float, double, or long double. */ diff --git a/src/basic/memfd-util.h b/src/basic/memfd-util.h index befe41ac43..2fc94f429f 100644 --- a/src/basic/memfd-util.h +++ b/src/basic/memfd-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" int memfd_create_wrapper(const char *name, unsigned mode); diff --git a/src/basic/memory-util.h b/src/basic/memory-util.h index c36a0cc337..1a609dea98 100644 --- a/src/basic/memory-util.h +++ b/src/basic/memory-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" #include "memory-util-fundamental.h" /* IWYU pragma: export */ size_t page_size(void) _pure_; diff --git a/src/basic/mempool.h b/src/basic/mempool.h index 69fbae18a5..a6f990d124 100644 --- a/src/basic/mempool.h +++ b/src/basic/mempool.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" struct pool; diff --git a/src/basic/memstream-util.h b/src/basic/memstream-util.h index 8c979c7a0a..895073be8e 100644 --- a/src/basic/memstream-util.h +++ b/src/basic/memstream-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef struct MemStream { FILE *f; diff --git a/src/basic/mkdir.h b/src/basic/mkdir.h index 93af446ebf..82323b1058 100644 --- a/src/basic/mkdir.h +++ b/src/basic/mkdir.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum MkdirFlags { MKDIR_FOLLOW_SYMLINK = 1 << 0, diff --git a/src/basic/mountpoint-util.h b/src/basic/mountpoint-util.h index 004d2b2af5..180d75343c 100644 --- a/src/basic/mountpoint-util.h +++ b/src/basic/mountpoint-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* The limit used for /dev itself. 4MB should be enough since device nodes and symlinks don't * consume any space and udev isn't supposed to create regular file either. There's no limit on the diff --git a/src/basic/namespace-util.h b/src/basic/namespace-util.h index e0e857b7a4..2c4a7da29f 100644 --- a/src/basic/namespace-util.h +++ b/src/basic/namespace-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum NamespaceType { NAMESPACE_CGROUP, diff --git a/src/basic/nulstr-util.h b/src/basic/nulstr-util.h index 600667f3c1..370d650a7f 100644 --- a/src/basic/nulstr-util.h +++ b/src/basic/nulstr-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" #define NULSTR_FOREACH(i, l) \ for (typeof(*(l)) *(i) = (l); (i) && *(i); (i) = strchr((i), 0)+1) diff --git a/src/basic/ordered-set.h b/src/basic/ordered-set.h index fb3e53395e..e25fc606e4 100644 --- a/src/basic/ordered-set.h +++ b/src/basic/ordered-set.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "hashmap.h" typedef struct OrderedSet OrderedSet; diff --git a/src/basic/os-util.h b/src/basic/os-util.h index 5051a39075..a3829b4f51 100644 --- a/src/basic/os-util.h +++ b/src/basic/os-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum ImageClass { IMAGE_MACHINE, diff --git a/src/basic/parse-util.h b/src/basic/parse-util.h index f79be849fd..4927bc9e56 100644 --- a/src/basic/parse-util.h +++ b/src/basic/parse-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef unsigned long loadavg_t; diff --git a/src/basic/path-util.h b/src/basic/path-util.h index a3a82574dd..5b2baef4e1 100644 --- a/src/basic/path-util.h +++ b/src/basic/path-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define PATH_SPLIT_BIN(x) x "sbin:" x "bin" #define PATH_SPLIT_BIN_NULSTR(x) x "sbin\0" x "bin\0" diff --git a/src/basic/pcapng.h b/src/basic/pcapng.h index ff2560c404..d4181520a6 100644 --- a/src/basic/pcapng.h +++ b/src/basic/pcapng.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* * For details about the file format see RFC: diff --git a/src/basic/percent-util.h b/src/basic/percent-util.h index 60b0d4a9ef..7b75654e32 100644 --- a/src/basic/percent-util.h +++ b/src/basic/percent-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int parse_percent_unbounded(const char *p); int parse_percent(const char *p); diff --git a/src/basic/pidfd-util.h b/src/basic/pidfd-util.h index 811d40dce9..2050734ab2 100644 --- a/src/basic/pidfd-util.h +++ b/src/basic/pidfd-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" int pidfd_get_namespace(int fd, unsigned long ns_type_cmd); diff --git a/src/basic/pidref.h b/src/basic/pidref.h index 4d8a084c4b..1a7ff85935 100644 --- a/src/basic/pidref.h +++ b/src/basic/pidref.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" /* An embeddable structure carrying a reference to a process. Supposed to be used when tracking processes * continuously. This combines a PID, a modern Linux pidfd and the 64bit inode number of the pidfd into one diff --git a/src/basic/prioq.h b/src/basic/prioq.h index 97b4f40b4a..07cedf603c 100644 --- a/src/basic/prioq.h +++ b/src/basic/prioq.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef struct Prioq Prioq; diff --git a/src/basic/proc-cmdline.h b/src/basic/proc-cmdline.h index 8eb905de3d..eee2ce24aa 100644 --- a/src/basic/proc-cmdline.h +++ b/src/basic/proc-cmdline.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum ProcCmdlineFlags { PROC_CMDLINE_STRIP_RD_PREFIX = 1 << 0, /* automatically strip "rd." prefix if it is set (and we are in the initrd, since otherwise we'd not consider it anyway) */ diff --git a/src/basic/process-util.h b/src/basic/process-util.h index 17065420dc..b3ccb2dc35 100644 --- a/src/basic/process-util.h +++ b/src/basic/process-util.h @@ -5,7 +5,7 @@ #include "fileio.h" #include "format-util.h" -#include "forward.h" +#include "basic-forward.h" #include "string-util.h" #define procfs_file_alloca(pid, field) \ diff --git a/src/basic/procfs-util.h b/src/basic/procfs-util.h index a0de848c82..560be323dc 100644 --- a/src/basic/procfs-util.h +++ b/src/basic/procfs-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int procfs_get_pid_max(uint64_t *ret); int procfs_get_threads_max(uint64_t *ret); diff --git a/src/basic/psi-util.h b/src/basic/psi-util.h index 3029e091a4..f5e79960a8 100644 --- a/src/basic/psi-util.h +++ b/src/basic/psi-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "parse-util.h" typedef enum PressureType { diff --git a/src/basic/pthread-util.h b/src/basic/pthread-util.h index 362944efc8..1e62bc1d62 100644 --- a/src/basic/pthread-util.h +++ b/src/basic/pthread-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" static inline pthread_mutex_t* pthread_mutex_lock_assert(pthread_mutex_t *mutex) { assert_se(pthread_mutex_lock(mutex) == 0); diff --git a/src/basic/random-util.h b/src/basic/random-util.h index 28bdb583c0..c0ed0488e7 100644 --- a/src/basic/random-util.h +++ b/src/basic/random-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" void random_bytes(void *p, size_t n) _nonnull_if_nonzero_(1, 2); /* Returns random bytes suitable for most uses, but may be insecure sometimes. */ int crypto_random_bytes(void *p, size_t n) _nonnull_if_nonzero_(1, 2); /* Returns secure random bytes after waiting for the RNG to initialize. */ diff --git a/src/basic/ratelimit.h b/src/basic/ratelimit.h index 321cfbbb44..ecc1b9dd1f 100644 --- a/src/basic/ratelimit.h +++ b/src/basic/ratelimit.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef struct RateLimit { usec_t interval; /* Keep those two fields first so they can be initialized easily: */ diff --git a/src/basic/raw-clone.h b/src/basic/raw-clone.h index af20cde73b..2b826bb352 100644 --- a/src/basic/raw-clone.h +++ b/src/basic/raw-clone.h @@ -3,6 +3,6 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" pid_t raw_clone(unsigned long flags); diff --git a/src/basic/recurse-dir.h b/src/basic/recurse-dir.h index 5e9548b046..68abb279f4 100644 --- a/src/basic/recurse-dir.h +++ b/src/basic/recurse-dir.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" typedef enum RecurseDirFlags { /* Interpreted by readdir_all() */ diff --git a/src/basic/replace-var.h b/src/basic/replace-var.h index abaa57b503..3f1fda65c1 100644 --- a/src/basic/replace-var.h +++ b/src/basic/replace-var.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" char* replace_var(const char *text, char *(*lookup)(const char *variable, void *userdata), void *userdata); diff --git a/src/basic/rlimit-util.h b/src/basic/rlimit-util.h index 8b600fe1d2..59e9532858 100644 --- a/src/basic/rlimit-util.h +++ b/src/basic/rlimit-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" #define _RLIMIT_MAX RLIMIT_NLIMITS diff --git a/src/basic/runtime-scope.h b/src/basic/runtime-scope.h index 94c2d2ea6a..4729fa1a95 100644 --- a/src/basic/runtime-scope.h +++ b/src/basic/runtime-scope.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum RuntimeScope { RUNTIME_SCOPE_SYSTEM, /* for the system */ diff --git a/src/basic/set.h b/src/basic/set.h index e6ce91c752..52854934ad 100644 --- a/src/basic/set.h +++ b/src/basic/set.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "hashmap.h" #define set_free_and_replace(a, b) \ diff --git a/src/basic/sha256.h b/src/basic/sha256.h index 8ec35a3ba5..afcb5810dc 100644 --- a/src/basic/sha256.h +++ b/src/basic/sha256.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "sha256-fundamental.h" /* IWYU pragma: export */ int sha256_fd(int fd, uint64_t max_size, uint8_t ret[static SHA256_DIGEST_SIZE]); diff --git a/src/basic/sigbus.h b/src/basic/sigbus.h index cf7593072d..f5946a0d87 100644 --- a/src/basic/sigbus.h +++ b/src/basic/sigbus.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" void sigbus_install(void); void sigbus_reset(void); diff --git a/src/basic/signal-util.h b/src/basic/signal-util.h index 04f3e73c78..f529abcd72 100644 --- a/src/basic/signal-util.h +++ b/src/basic/signal-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" int reset_all_signal_handlers(void); int reset_signal_mask(void); diff --git a/src/basic/siphash24.h b/src/basic/siphash24.h index 61d83233a5..d72233beda 100644 --- a/src/basic/siphash24.h +++ b/src/basic/siphash24.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" struct siphash { uint64_t v0; diff --git a/src/basic/socket-util.h b/src/basic/socket-util.h index 89b4c11b6d..6e937ffee9 100644 --- a/src/basic/socket-util.h +++ b/src/basic/socket-util.h @@ -10,7 +10,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" #include "memory-util.h" #include "missing-network.h" diff --git a/src/basic/sort-util.h b/src/basic/sort-util.h index 8b6d2aaddf..2b558d6fd8 100644 --- a/src/basic/sort-util.h +++ b/src/basic/sort-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" void *xbsearch_r(const void *key, const void *base, size_t nmemb, size_t size, comparison_userdata_fn_t compar, void *arg); diff --git a/src/basic/sparse-endian.h b/src/basic/sparse-endian.h index d66e77afc2..c56268f4d6 100644 --- a/src/basic/sparse-endian.h +++ b/src/basic/sparse-endian.h @@ -25,7 +25,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" #ifdef __CHECKER__ #define __sd_bitwise __attribute__((__bitwise__)) diff --git a/src/basic/stat-util.h b/src/basic/stat-util.h index a3c60e43c6..490ee96c5f 100644 --- a/src/basic/stat-util.h +++ b/src/basic/stat-util.h @@ -4,7 +4,7 @@ #include /* IWYU pragma: export */ #include /* IWYU pragma: export */ -#include "forward.h" +#include "basic-forward.h" int stat_verify_regular(const struct stat *st); int verify_regular_at(int fd, const char *path, bool follow); diff --git a/src/basic/static-destruct.h b/src/basic/static-destruct.h index 3502d192e2..5772d24240 100644 --- a/src/basic/static-destruct.h +++ b/src/basic/static-destruct.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef void (*free_func_t)(void *p); diff --git a/src/basic/stdio-util.h b/src/basic/stdio-util.h index 052087ce15..f8ab0f0012 100644 --- a/src/basic/stdio-util.h +++ b/src/basic/stdio-util.h @@ -4,7 +4,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" _printf_(3, 4) static inline char* snprintf_ok(char *buf, size_t len, const char *format, ...) { diff --git a/src/basic/strbuf.h b/src/basic/strbuf.h index 68baaffb40..9f4a63fe92 100644 --- a/src/basic/strbuf.h +++ b/src/basic/strbuf.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" struct strbuf { char *buf; diff --git a/src/basic/string-table.h b/src/basic/string-table.h index 7e0569a489..444de4161f 100644 --- a/src/basic/string-table.h +++ b/src/basic/string-table.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" const char* string_table_lookup_to_string(const char * const *table, size_t len, ssize_t i) _const_; diff --git a/src/basic/string-util.h b/src/basic/string-util.h index 70722d9983..79e87c8914 100644 --- a/src/basic/string-util.h +++ b/src/basic/string-util.h @@ -4,7 +4,7 @@ #include #include "alloc-util.h" -#include "forward.h" +#include "basic-forward.h" #include "string-util-fundamental.h" /* IWYU pragma: export */ static inline char* strstr_ptr(const char *haystack, const char *needle) { diff --git a/src/basic/strv.h b/src/basic/strv.h index 394376a806..b358ab4c2b 100644 --- a/src/basic/strv.h +++ b/src/basic/strv.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "strv-fundamental.h" /* IWYU pragma: export */ char* strv_find(char * const *l, const char *name) _pure_; diff --git a/src/basic/strxcpyx.h b/src/basic/strxcpyx.h index 7d045fe8d2..b89d180fb8 100644 --- a/src/basic/strxcpyx.h +++ b/src/basic/strxcpyx.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" size_t strnpcpy_full(char **dest, size_t size, const char *src, size_t len, bool *ret_truncated); static inline size_t strnpcpy(char **dest, size_t size, const char *src, size_t len) { diff --git a/src/basic/sync-util.h b/src/basic/sync-util.h index c464a656d4..0f6e195ec3 100644 --- a/src/basic/sync-util.h +++ b/src/basic/sync-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int fsync_directory_of_file(int fd); int fsync_full(int fd); diff --git a/src/basic/sysctl-util.h b/src/basic/sysctl-util.h index ef08376916..4055d0181f 100644 --- a/src/basic/sysctl-util.h +++ b/src/basic/sysctl-util.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "basic-forward.h" #include "stdio-util.h" char* sysctl_normalize(char *s); diff --git a/src/basic/syslog-util.h b/src/basic/syslog-util.h index dff09db239..215b175b0d 100644 --- a/src/basic/syslog-util.h +++ b/src/basic/syslog-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int log_facility_unshifted_to_string_alloc(int i, char **s); int log_facility_unshifted_from_string(const char *s); diff --git a/src/basic/terminal-util.h b/src/basic/terminal-util.h index d18d33a181..aca549bbc4 100644 --- a/src/basic/terminal-util.h +++ b/src/basic/terminal-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* Erase characters until the end of the line */ #define ANSI_ERASE_TO_END_OF_LINE "\x1B[K" diff --git a/src/basic/time-util.h b/src/basic/time-util.h index 0c698eabd8..322a2ece6b 100644 --- a/src/basic/time-util.h +++ b/src/basic/time-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" #define PRI_NSEC PRIu64 #define PRI_USEC PRIu64 diff --git a/src/basic/tmpfile-util.h b/src/basic/tmpfile-util.h index cbaae5dbb3..3999020e01 100644 --- a/src/basic/tmpfile-util.h +++ b/src/basic/tmpfile-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int fopen_temporary_at(int dir_fd, const char *path, FILE **ret_file, char **ret_path); static inline int fopen_temporary(const char *path, FILE **ret_file, char **ret_path) { diff --git a/src/basic/uid-classification.h b/src/basic/uid-classification.h index f732b6ef9b..5b75c0ab78 100644 --- a/src/basic/uid-classification.h +++ b/src/basic/uid-classification.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* The container base should have the last 16 bit set to zero */ assert_cc((CONTAINER_UID_BASE_MIN & 0xFFFFU) == 0); diff --git a/src/basic/uid-range.h b/src/basic/uid-range.h index 5f3c033524..b74ab9d332 100644 --- a/src/basic/uid-range.h +++ b/src/basic/uid-range.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef struct UIDRangeEntry { uid_t start, nr; diff --git a/src/basic/umask-util.h b/src/basic/umask-util.h index 1f9ea2bf2b..86dfcfcd31 100644 --- a/src/basic/umask-util.h +++ b/src/basic/umask-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" static inline void umaskp(mode_t *u) { umask(*u); diff --git a/src/basic/unaligned.h b/src/basic/unaligned.h index 61ee82b773..b45fb3c358 100644 --- a/src/basic/unaligned.h +++ b/src/basic/unaligned.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "basic-forward.h" #include "unaligned-fundamental.h" /* IWYU pragma: export */ /* BE */ diff --git a/src/basic/unit-def.h b/src/basic/unit-def.h index 7ae086c0b9..f42198e08e 100644 --- a/src/basic/unit-def.h +++ b/src/basic/unit-def.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" /* The enum order is used to order unit jobs in the job queue * when other criteria (cpu weight, nice level) are identical. diff --git a/src/basic/unit-name.h b/src/basic/unit-name.h index 50fe3ac8e9..334877c2f2 100644 --- a/src/basic/unit-name.h +++ b/src/basic/unit-name.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define UNIT_NAME_MAX 256 diff --git a/src/basic/user-util.h b/src/basic/user-util.h index 8ce25ab35c..c4f2aea309 100644 --- a/src/basic/user-util.h +++ b/src/basic/user-util.h @@ -8,7 +8,7 @@ #include #include -#include "forward.h" +#include "basic-forward.h" /* Users managed by systemd-homed. See https://systemd.io/UIDS-GIDS for details how this range fits into the rest of the world */ #define HOME_UID_MIN ((uid_t) 60001) diff --git a/src/basic/utf8.h b/src/basic/utf8.h index dc97f4aee7..967edb4014 100644 --- a/src/basic/utf8.h +++ b/src/basic/utf8.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" #define UTF8_REPLACEMENT_CHARACTER "\xef\xbf\xbd" #define UTF8_BYTE_ORDER_MARK "\xef\xbb\xbf" diff --git a/src/basic/virt.h b/src/basic/virt.h index cac3f4496c..b34bfd8261 100644 --- a/src/basic/virt.h +++ b/src/basic/virt.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" typedef enum Virtualization { VIRTUALIZATION_NONE = 0, diff --git a/src/basic/xattr-util.h b/src/basic/xattr-util.h index f38ecf491d..d8e521b969 100644 --- a/src/basic/xattr-util.h +++ b/src/basic/xattr-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "basic-forward.h" int getxattr_at_malloc(int fd, const char *path, const char *name, int at_flags, char **ret, size_t *ret_size); static inline int getxattr_malloc(const char *path, const char *name, char **ret, size_t *ret_size) { diff --git a/src/bootctl/bootctl-reboot-to-firmware.h b/src/bootctl/bootctl-reboot-to-firmware.h index 82f77b997d..5ac2e9c40b 100644 --- a/src/bootctl/bootctl-reboot-to-firmware.h +++ b/src/bootctl/bootctl-reboot-to-firmware.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int verb_reboot_to_firmware(int argc, char *argv[], void *userdata); diff --git a/src/bootctl/bootctl-status.h b/src/bootctl/bootctl-status.h index 6dfc578a0c..234a44546e 100644 --- a/src/bootctl/bootctl-status.h +++ b/src/bootctl/bootctl-status.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int verb_status(int argc, char *argv[], void *userdata); int verb_list(int argc, char *argv[], void *userdata); diff --git a/src/bootctl/bootctl-uki.h b/src/bootctl/bootctl-uki.h index 20c080cf85..dbbd41f45c 100644 --- a/src/bootctl/bootctl-uki.h +++ b/src/bootctl/bootctl-uki.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int verb_kernel_identify(int argc, char *argv[], void *userdata); int verb_kernel_inspect(int argc, char *argv[], void *userdata); diff --git a/src/bootctl/bootctl.h b/src/bootctl/bootctl.h index 4f052e67bc..f4d6bb40ba 100644 --- a/src/bootctl/bootctl.h +++ b/src/bootctl/bootctl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum InstallSource { INSTALL_SOURCE_IMAGE, diff --git a/src/busctl/busctl-introspect.h b/src/busctl/busctl-introspect.h index 374ab53a19..d83be3715d 100644 --- a/src/busctl/busctl-introspect.h +++ b/src/busctl/busctl-introspect.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct XMLIntrospectOps { int (*on_path)(const char *path, void *userdata); diff --git a/src/core/audit-fd.h b/src/core/audit-fd.h index 55bd357c81..4f02bdfdd0 100644 --- a/src/core/audit-fd.h +++ b/src/core/audit-fd.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int get_core_audit_fd(void); void close_core_audit_fd(void); diff --git a/src/core/clock-warp.h b/src/core/clock-warp.h index 84ffdc230a..1c6011b3d5 100644 --- a/src/core/clock-warp.h +++ b/src/core/clock-warp.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int clock_reset_timewarp(void); void clock_apply_epoch(bool allow_backwards); diff --git a/src/core/core-forward.h b/src/core/core-forward.h index a5159ba306..a82a12bc08 100644 --- a/src/core/core-forward.h +++ b/src/core/core-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ #include "unit-def.h" /* IWYU pragma: export */ typedef enum CGroupDevicePermissions CGroupDevicePermissions; diff --git a/src/core/crash-handler.h b/src/core/crash-handler.h index 4fd185fa45..379f3050b1 100644 --- a/src/core/crash-handler.h +++ b/src/core/crash-handler.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum CrashAction { CRASH_FREEZE, diff --git a/src/core/generator-setup.h b/src/core/generator-setup.h index 5746823153..2b24cc56a9 100644 --- a/src/core/generator-setup.h +++ b/src/core/generator-setup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "core-forward.h" int lookup_paths_mkdir_generator(LookupPaths *p); void lookup_paths_trim_generator(LookupPaths *p); diff --git a/src/core/kill.h b/src/core/kill.h index 199945bc8b..4bb88c9bd9 100644 --- a/src/core/kill.h +++ b/src/core/kill.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum KillMode { /* The kill mode is a property of a unit. */ diff --git a/src/core/main.h b/src/core/main.h index a871d573fd..f892b13f02 100644 --- a/src/core/main.h +++ b/src/core/main.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "crash-handler.h" extern bool arg_dump_core; diff --git a/src/core/manager.h b/src/core/manager.h index b4f34f66e6..d57912f6bd 100644 --- a/src/core/manager.h +++ b/src/core/manager.h @@ -6,7 +6,7 @@ #include "cgroup.h" #include "common-signal.h" #include "execute.h" -#include "forward.h" +#include "shared-forward.h" #include "log.h" #include "path-lookup.h" #include "show-status.h" diff --git a/src/core/namespace.h b/src/core/namespace.h index 4e9d87e266..66a88ae3c1 100644 --- a/src/core/namespace.h +++ b/src/core/namespace.h @@ -5,7 +5,7 @@ Copyright © 2016 Djalal Harouni ***/ -#include "forward.h" +#include "core-forward.h" #include "list.h" #include "runtime-scope.h" diff --git a/src/core/selinux-setup.h b/src/core/selinux-setup.h index 99c05650d0..2caa75ff73 100644 --- a/src/core/selinux-setup.h +++ b/src/core/selinux-setup.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int mac_selinux_setup(bool *loaded_policy); diff --git a/src/core/show-status.h b/src/core/show-status.h index 38c23e6a24..9625426fa1 100644 --- a/src/core/show-status.h +++ b/src/core/show-status.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Manager status */ diff --git a/src/core/smack-setup.h b/src/core/smack-setup.h index 4b7da569ca..df64d58547 100644 --- a/src/core/smack-setup.h +++ b/src/core/smack-setup.h @@ -7,6 +7,6 @@ Nathaniel Chen ***/ -#include "forward.h" +#include "shared-forward.h" int mac_smack_setup(bool *loaded_policy); diff --git a/src/core/unit-dependency-atom.h b/src/core/unit-dependency-atom.h index 36ea729f5c..c0ad3db513 100644 --- a/src/core/unit-dependency-atom.h +++ b/src/core/unit-dependency-atom.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Flags that identify the various "atomic" behaviours a specific dependency type implies. Each dependency is * a combination of one or more of these flags that define what they actually entail. */ diff --git a/src/core/varlink-cgroup.h b/src/core/varlink-cgroup.h index befd1fdde8..8e5f2363c3 100644 --- a/src/core/varlink-cgroup.h +++ b/src/core/varlink-cgroup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int unit_cgroup_context_build_json(sd_json_variant **ret, const char *name, void *userdata); int unit_cgroup_runtime_build_json(sd_json_variant **ret, const char *name, void *userdata); diff --git a/src/core/varlink-common.h b/src/core/varlink-common.h index 45b47cb661..314398e438 100644 --- a/src/core/varlink-common.h +++ b/src/core/varlink-common.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int rlimit_build_json(sd_json_variant **ret, const char *name, void *userdata); int rlimit_table_build_json(sd_json_variant **ret, const char *name, void *userdata); diff --git a/src/core/varlink-dynamic-user.h b/src/core/varlink-dynamic-user.h index 5ff22418b0..14bcf3191f 100644 --- a/src/core/varlink-dynamic-user.h +++ b/src/core/varlink-dynamic-user.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int vl_method_get_user_record(sd_varlink *link, sd_json_variant *parameters, sd_varlink_method_flags_t flags, void *userdata); int vl_method_get_group_record(sd_varlink *link, sd_json_variant *parameters, sd_varlink_method_flags_t flags, void *userdata); diff --git a/src/core/varlink-manager.h b/src/core/varlink-manager.h index f7396e1264..5836d5443a 100644 --- a/src/core/varlink-manager.h +++ b/src/core/varlink-manager.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int vl_method_describe_manager(sd_varlink *link, sd_json_variant *parameters, sd_varlink_method_flags_t flags, void *userdata); diff --git a/src/core/varlink-unit.h b/src/core/varlink-unit.h index 074ed651eb..431f1f832e 100644 --- a/src/core/varlink-unit.h +++ b/src/core/varlink-unit.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define VARLINK_ERROR_UNIT_NO_SUCH_UNIT "io.systemd.Unit.NoSuchUnit" diff --git a/src/coredump/coredump-vacuum.h b/src/coredump/coredump-vacuum.h index 1a2d648111..74cd4344bc 100644 --- a/src/coredump/coredump-vacuum.h +++ b/src/coredump/coredump-vacuum.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int coredump_vacuum(int exclude_fd, uint64_t keep_free, uint64_t max_use); diff --git a/src/cryptenroll/cryptenroll-fido2.h b/src/cryptenroll/cryptenroll-fido2.h index 931ce94ac8..7d0c25c02a 100644 --- a/src/cryptenroll/cryptenroll-fido2.h +++ b/src/cryptenroll/cryptenroll-fido2.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int load_volume_key_fido2(struct crypt_device *cd, const char *cd_node, const char *device, void *ret_vk, size_t *ret_vks); int enroll_fido2(struct crypt_device *cd, const struct iovec *volume_key, const char *device, Fido2EnrollFlags lock_with, int cred_alg, const char *salt_file, bool parameters_in_header); diff --git a/src/cryptenroll/cryptenroll-list.h b/src/cryptenroll/cryptenroll-list.h index 40270bfeea..9097bc42c1 100644 --- a/src/cryptenroll/cryptenroll-list.h +++ b/src/cryptenroll/cryptenroll-list.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int list_enrolled(struct crypt_device *cd); diff --git a/src/cryptenroll/cryptenroll-password.h b/src/cryptenroll/cryptenroll-password.h index f83e627469..f0c97ced29 100644 --- a/src/cryptenroll/cryptenroll-password.h +++ b/src/cryptenroll/cryptenroll-password.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int load_volume_key_password(struct crypt_device *cd, const char* cd_node, void *ret_vk, size_t *ret_vks); int enroll_password(struct crypt_device *cd, const struct iovec *volume_key); diff --git a/src/cryptenroll/cryptenroll-pkcs11.h b/src/cryptenroll/cryptenroll-pkcs11.h index 3d5d1e3022..b3e6e4584a 100644 --- a/src/cryptenroll/cryptenroll-pkcs11.h +++ b/src/cryptenroll/cryptenroll-pkcs11.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int enroll_pkcs11(struct crypt_device *cd, const struct iovec *volume_key, const char *uri); diff --git a/src/cryptenroll/cryptenroll-recovery.h b/src/cryptenroll/cryptenroll-recovery.h index c8a947ca3b..0c76d86108 100644 --- a/src/cryptenroll/cryptenroll-recovery.h +++ b/src/cryptenroll/cryptenroll-recovery.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int enroll_recovery(struct crypt_device *cd, const struct iovec *volume_key); diff --git a/src/cryptenroll/cryptenroll-tpm2.h b/src/cryptenroll/cryptenroll-tpm2.h index 079da9271e..48f6c12b7f 100644 --- a/src/cryptenroll/cryptenroll-tpm2.h +++ b/src/cryptenroll/cryptenroll-tpm2.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int load_volume_key_tpm2(struct crypt_device *cd, const char *cd_node, const char *device, void *ret_vk, size_t *ret_vks); int enroll_tpm2(struct crypt_device *cd, const struct iovec *volume_key, const char *device, uint32_t seal_key_handle, const char *device_key, Tpm2PCRValue *hash_pcr_values, size_t n_hash_pcr_values, const char *pubkey_path, bool load_pcr_pubkey, uint32_t pubkey_pcr_mask, const char *signature_path, bool use_pin, const char *pcrlock_path, int *ret_slot_to_wipe); diff --git a/src/cryptenroll/cryptenroll-wipe.h b/src/cryptenroll/cryptenroll-wipe.h index d2679c306a..aa82f9dbbd 100644 --- a/src/cryptenroll/cryptenroll-wipe.h +++ b/src/cryptenroll/cryptenroll-wipe.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum WipeScope WipeScope; diff --git a/src/cryptenroll/cryptenroll.h b/src/cryptenroll/cryptenroll.h index 6a2f36c36a..613940fe97 100644 --- a/src/cryptenroll/cryptenroll.h +++ b/src/cryptenroll/cryptenroll.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum EnrollType { ENROLL_PASSWORD, diff --git a/src/cryptsetup/cryptsetup-keyfile.h b/src/cryptsetup/cryptsetup-keyfile.h index 76c21004af..87ff70d65f 100644 --- a/src/cryptsetup/cryptsetup-keyfile.h +++ b/src/cryptsetup/cryptsetup-keyfile.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int find_key_file(const char *key_file, char **search_path, const char *bindname, struct iovec *ret_key); diff --git a/src/cryptsetup/cryptsetup-pkcs11.h b/src/cryptsetup/cryptsetup-pkcs11.h index 2dcacd5015..472e5d0e78 100644 --- a/src/cryptsetup/cryptsetup-pkcs11.h +++ b/src/cryptsetup/cryptsetup-pkcs11.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int decrypt_pkcs11_key( const char *volume_name, diff --git a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-util.h b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-util.h index cdd26fd085..68b09fc458 100644 --- a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-util.h +++ b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token-util.h @@ -4,7 +4,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* crypt_dump() internal indentation magic */ #define CRYPT_DUMP_LINE_SEP "\n\t " diff --git a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token.h b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token.h index b23f62be8d..fa02ec207b 100644 --- a/src/cryptsetup/cryptsetup-tokens/cryptsetup-token.h +++ b/src/cryptsetup/cryptsetup-tokens/cryptsetup-token.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* for more information see libcryptsetup.h crypt-tokens section */ diff --git a/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.h b/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.h index 9f51fc8161..d233b7ad06 100644 --- a/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.h +++ b/src/cryptsetup/cryptsetup-tokens/luks2-pkcs11.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" int acquire_luks2_key( struct crypt_device *cd, diff --git a/src/fuzz/fuzz.h b/src/fuzz/fuzz.h index 6e4935d555..a4cc7ab67d 100644 --- a/src/fuzz/fuzz.h +++ b/src/fuzz/fuzz.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "fileio.h" #include "log.h" diff --git a/src/hibernate-resume/hibernate-resume-config.h b/src/hibernate-resume/hibernate-resume-config.h index 55f344a9e6..bad2cf8283 100644 --- a/src/hibernate-resume/hibernate-resume-config.h +++ b/src/hibernate-resume/hibernate-resume-config.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef struct KernelHibernateLocation KernelHibernateLocation; diff --git a/src/home/home-util.h b/src/home/home-util.h index 425ad7be63..0b1781d272 100644 --- a/src/home/home-util.h +++ b/src/home/home-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "homed-forward.h" /* Flags supported by UpdateEx() */ #define SD_HOMED_UPDATE_OFFLINE (UINT64_C(1) << 0) diff --git a/src/home/homectl-fido2.h b/src/home/homectl-fido2.h index 840dd79d19..9815ec8e18 100644 --- a/src/home/homectl-fido2.h +++ b/src/home/homectl-fido2.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int identity_add_fido2_parameters(sd_json_variant **v, const char *device, Fido2EnrollFlags lock_with, int cred_alg); diff --git a/src/home/homectl-pkcs11.h b/src/home/homectl-pkcs11.h index cee12b49ed..ca79a0f29b 100644 --- a/src/home/homectl-pkcs11.h +++ b/src/home/homectl-pkcs11.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int identity_add_token_pin(sd_json_variant **v, const char *pin); int identity_add_pkcs11_key_data(sd_json_variant **v, const char *token_uri); diff --git a/src/home/homectl-recovery-key.h b/src/home/homectl-recovery-key.h index 5a48f5fec1..b5100da0f1 100644 --- a/src/home/homectl-recovery-key.h +++ b/src/home/homectl-recovery-key.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int identity_add_recovery_key(sd_json_variant **v); diff --git a/src/home/homed-bus.h b/src/home/homed-bus.h index 4adb60e8a2..77a6838642 100644 --- a/src/home/homed-bus.h +++ b/src/home/homed-bus.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "homed-forward.h" int bus_message_read_secret(sd_bus_message *m, UserRecord **ret, sd_bus_error *error); int bus_message_read_home_record(sd_bus_message *m, UserRecordLoadFlags flags, UserRecord **ret, sd_bus_error *error); diff --git a/src/home/homed-forward.h b/src/home/homed-forward.h index 3672b163d6..18a8df8e61 100644 --- a/src/home/homed-forward.h +++ b/src/home/homed-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef struct Manager Manager; typedef struct Home Home; diff --git a/src/home/homed-home.h b/src/home/homed-home.h index 8fcdca32ce..0692e56089 100644 --- a/src/home/homed-home.h +++ b/src/home/homed-home.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "homed-forward.h" #include "pidref.h" #include "stat-util.h" diff --git a/src/home/homework-forward.h b/src/home/homework-forward.h index 21871d4deb..04fefe6d45 100644 --- a/src/home/homework-forward.h +++ b/src/home/homework-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum HomeSetupFlags HomeSetupFlags; diff --git a/src/home/user-record-password-quality.h b/src/home/user-record-password-quality.h index b76092113c..36e2b3ed13 100644 --- a/src/home/user-record-password-quality.h +++ b/src/home/user-record-password-quality.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int user_record_check_password_quality(UserRecord *hr, UserRecord *secret, sd_bus_error *error); diff --git a/src/home/user-record-sign.h b/src/home/user-record-sign.h index 350e745766..3007d00b01 100644 --- a/src/home/user-record-sign.h +++ b/src/home/user-record-sign.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int user_record_sign(UserRecord *ur, EVP_PKEY *private_key, UserRecord **ret); diff --git a/src/home/user-record-util.h b/src/home/user-record-util.h index 31961184a8..876baa4103 100644 --- a/src/home/user-record-util.h +++ b/src/home/user-record-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* We intentionally use snake_case instead of the usual camelCase here to further * reduce the chance of collision with a field any legitimate user record may ever diff --git a/src/import/curl-util.h b/src/import/curl-util.h index abba49044b..b48eeb9c43 100644 --- a/src/import/curl-util.h +++ b/src/import/curl-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef struct CurlGlue CurlGlue; diff --git a/src/import/export-raw.h b/src/import/export-raw.h index 9bac076b35..7af9091929 100644 --- a/src/import/export-raw.h +++ b/src/import/export-raw.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-compress.h" typedef struct RawExport RawExport; diff --git a/src/import/export-tar.h b/src/import/export-tar.h index f261c0c8d2..9eeec80dda 100644 --- a/src/import/export-tar.h +++ b/src/import/export-tar.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-compress.h" typedef struct TarExport TarExport; diff --git a/src/import/import-common.h b/src/import/import-common.h index 552e68f67c..55d00ea466 100644 --- a/src/import/import-common.h +++ b/src/import/import-common.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum ImportFlags { /* Public Flags (i.e. accessible via D-Bus, must stay stable! */ diff --git a/src/import/import-compress.h b/src/import/import-compress.h index ea14038a4f..6e7f0e514a 100644 --- a/src/import/import-compress.h +++ b/src/import/import-compress.h @@ -10,7 +10,7 @@ #include #endif -#include "forward.h" +#include "shared-forward.h" typedef enum ImportCompressType { IMPORT_COMPRESS_UNKNOWN, diff --git a/src/import/import-raw.h b/src/import/import-raw.h index 9b71162409..7c38a1f819 100644 --- a/src/import/import-raw.h +++ b/src/import/import-raw.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-common.h" typedef struct RawImport RawImport; diff --git a/src/import/import-tar.h b/src/import/import-tar.h index 90d432b1e0..3586ba0d57 100644 --- a/src/import/import-tar.h +++ b/src/import/import-tar.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-common.h" typedef struct TarImport TarImport; diff --git a/src/import/pull-common.h b/src/import/pull-common.h index 455b8395d2..160c035a21 100644 --- a/src/import/pull-common.h +++ b/src/import/pull-common.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-common.h" #include "import-util.h" #include "pull-job.h" diff --git a/src/import/pull-job.h b/src/import/pull-job.h index 504185aaa9..b39e11929f 100644 --- a/src/import/pull-job.h +++ b/src/import/pull-job.h @@ -4,7 +4,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "import-compress.h" #include "openssl-util.h" diff --git a/src/import/pull-raw.h b/src/import/pull-raw.h index 8ca6579590..c8126d4ff1 100644 --- a/src/import/pull-raw.h +++ b/src/import/pull-raw.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-common.h" #include "import-util.h" diff --git a/src/import/pull-tar.h b/src/import/pull-tar.h index 627cb0bcc8..8f622dff3a 100644 --- a/src/import/pull-tar.h +++ b/src/import/pull-tar.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "import-common.h" #include "import-util.h" diff --git a/src/integritysetup/integrity-util.h b/src/integritysetup/integrity-util.h index edc3ceac5f..64aa79da87 100644 --- a/src/integritysetup/integrity-util.h +++ b/src/integritysetup/integrity-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int parse_integrity_options( const char *options, diff --git a/src/journal-remote/journal-compression-util.h b/src/journal-remote/journal-compression-util.h index ca079dbb8d..6670d61756 100644 --- a/src/journal-remote/journal-compression-util.h +++ b/src/journal-remote/journal-compression-util.h @@ -3,7 +3,7 @@ #include "compress.h" #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" typedef struct CompressionConfig { Compression algorithm; diff --git a/src/journal-remote/journal-header-util.h b/src/journal-remote/journal-header-util.h index 767de11e5a..0e99b66009 100644 --- a/src/journal-remote/journal-header-util.h +++ b/src/journal-remote/journal-header-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" bool header_value_is_valid(const char *value); diff --git a/src/journal-remote/journal-remote-parse.h b/src/journal-remote/journal-remote-parse.h index 54b984431e..2ce0b86ad7 100644 --- a/src/journal-remote/journal-remote-parse.h +++ b/src/journal-remote/journal-remote-parse.h @@ -2,7 +2,7 @@ #pragma once #include "compress.h" -#include "forward.h" +#include "shared-forward.h" #include "journal-importer.h" #include "journal-remote-write.h" diff --git a/src/journal-remote/journal-remote.h b/src/journal-remote/journal-remote.h index bcf619332c..b893530250 100644 --- a/src/journal-remote/journal-remote.h +++ b/src/journal-remote/journal-remote.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "journal-remote-parse.h" #include "journal-remote-write.h" diff --git a/src/journal-remote/journal-upload.h b/src/journal-remote/journal-upload.h index cfb30c7f84..9ab0f535a4 100644 --- a/src/journal-remote/journal-upload.h +++ b/src/journal-remote/journal-upload.h @@ -4,7 +4,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "journal-compression-util.h" typedef enum { diff --git a/src/journal-remote/microhttpd-util.h b/src/journal-remote/microhttpd-util.h index 632fef5e95..80142e24f5 100644 --- a/src/journal-remote/microhttpd-util.h +++ b/src/journal-remote/microhttpd-util.h @@ -5,7 +5,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* Those defines are added when options are renamed. If the old names * are not '#define'd, then they are not deprecated yet and there are diff --git a/src/journal/journalctl-filter.h b/src/journal/journalctl-filter.h index d5966ab5f6..dc9474c0f0 100644 --- a/src/journal/journalctl-filter.h +++ b/src/journal/journalctl-filter.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int add_filters(sd_journal *j, char **matches); diff --git a/src/journal/journalctl-misc.h b/src/journal/journalctl-misc.h index 0da319079c..dad0d4edbd 100644 --- a/src/journal/journalctl-misc.h +++ b/src/journal/journalctl-misc.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int action_print_header(void); int action_verify(void); diff --git a/src/journal/journalctl-util.h b/src/journal/journalctl-util.h index 4571c28540..f237aab2b0 100644 --- a/src/journal/journalctl-util.h +++ b/src/journal/journalctl-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "logs-show.h" /* The lists below are supposed to return the superset of unit names possibly matched by rules added with diff --git a/src/journal/journalctl.h b/src/journal/journalctl.h index b78d617b7c..79ffe03464 100644 --- a/src/journal/journalctl.h +++ b/src/journal/journalctl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "pcre2-util.h" typedef enum JournalctlAction { diff --git a/src/journal/journald-forward.h b/src/journal/journald-forward.h index ef597bbf11..141b98024f 100644 --- a/src/journal/journald-forward.h +++ b/src/journal/journald-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum Storage Storage; typedef enum SplitMode SplitMode; diff --git a/src/libsystemd-network/arp-util.h b/src/libsystemd-network/arp-util.h index 4152c3a098..5cf56c064a 100644 --- a/src/libsystemd-network/arp-util.h +++ b/src/libsystemd-network/arp-util.h @@ -5,7 +5,7 @@ Copyright © 2014 Axis Communications AB. All rights reserved. ***/ -#include "forward.h" +#include "sd-forward.h" int arp_update_filter(int fd, const struct in_addr *a, const struct ether_addr *mac); int arp_network_bind_raw_socket(int ifindex, const struct in_addr *a, const struct ether_addr *mac); diff --git a/src/libsystemd-network/dhcp-client-id-internal.h b/src/libsystemd-network/dhcp-client-id-internal.h index 2f51968758..8efc007a3d 100644 --- a/src/libsystemd-network/dhcp-client-id-internal.h +++ b/src/libsystemd-network/dhcp-client-id-internal.h @@ -6,7 +6,7 @@ #include "sd-dhcp-client-id.h" #include "dhcp-duid-internal.h" -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" /* RFC 2132 section 9.14: its minimum length is 2. diff --git a/src/libsystemd-network/dhcp-client-internal.h b/src/libsystemd-network/dhcp-client-internal.h index 3248e1098b..16d5ac8630 100644 --- a/src/libsystemd-network/dhcp-client-internal.h +++ b/src/libsystemd-network/dhcp-client-internal.h @@ -3,7 +3,7 @@ #include "sd-dhcp-client.h" -#include "forward.h" +#include "sd-forward.h" #include "network-common.h" typedef enum DHCPState { diff --git a/src/libsystemd-network/dhcp-duid-internal.h b/src/libsystemd-network/dhcp-duid-internal.h index c2af1fa4dd..94a119c3e8 100644 --- a/src/libsystemd-network/dhcp-duid-internal.h +++ b/src/libsystemd-network/dhcp-duid-internal.h @@ -5,7 +5,7 @@ #include "sd-id128.h" #include "ether-addr-util.h" -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" #define SYSTEMD_PEN 43793 diff --git a/src/libsystemd-network/dhcp-lease-internal.h b/src/libsystemd-network/dhcp-lease-internal.h index 0ed8c3fc93..93831d8720 100644 --- a/src/libsystemd-network/dhcp-lease-internal.h +++ b/src/libsystemd-network/dhcp-lease-internal.h @@ -9,7 +9,7 @@ #include "dhcp-client-id-internal.h" #include "dhcp-option.h" -#include "forward.h" +#include "sd-forward.h" #include "list.h" struct sd_dhcp_route { diff --git a/src/libsystemd-network/dhcp-network.h b/src/libsystemd-network/dhcp-network.h index c493cfeee5..3cc66dad9d 100644 --- a/src/libsystemd-network/dhcp-network.h +++ b/src/libsystemd-network/dhcp-network.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" int dhcp_network_bind_raw_socket( diff --git a/src/libsystemd-network/dhcp-option.h b/src/libsystemd-network/dhcp-option.h index c3738b87c1..baaba1dcf2 100644 --- a/src/libsystemd-network/dhcp-option.h +++ b/src/libsystemd-network/dhcp-option.h @@ -4,7 +4,7 @@ #include "sd-dhcp-option.h" /* IWYU pragma: export */ #include "dhcp-protocol.h" -#include "forward.h" +#include "sd-forward.h" #include "hash-funcs.h" struct sd_dhcp_option { diff --git a/src/libsystemd-network/dhcp-packet.h b/src/libsystemd-network/dhcp-packet.h index ba058e06c1..967bd5d89d 100644 --- a/src/libsystemd-network/dhcp-packet.h +++ b/src/libsystemd-network/dhcp-packet.h @@ -2,7 +2,7 @@ #pragma once #include "dhcp-protocol.h" -#include "forward.h" +#include "sd-forward.h" int bootp_message_init( DHCPMessage *message, diff --git a/src/libsystemd-network/dhcp-protocol.h b/src/libsystemd-network/dhcp-protocol.h index ca872a8081..425f730894 100644 --- a/src/libsystemd-network/dhcp-protocol.h +++ b/src/libsystemd-network/dhcp-protocol.h @@ -10,7 +10,7 @@ #include "sd-dhcp-protocol.h" -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" #include "time-util.h" diff --git a/src/libsystemd-network/dhcp-server-internal.h b/src/libsystemd-network/dhcp-server-internal.h index eeaed11096..8b7c856d21 100644 --- a/src/libsystemd-network/dhcp-server-internal.h +++ b/src/libsystemd-network/dhcp-server-internal.h @@ -10,7 +10,7 @@ #include "dhcp-client-id-internal.h" #include "dhcp-option.h" -#include "forward.h" +#include "sd-forward.h" #include "network-common.h" #include "sparse-endian.h" diff --git a/src/libsystemd-network/dhcp-server-lease-internal.h b/src/libsystemd-network/dhcp-server-lease-internal.h index 4a36df6ead..aeb099ff81 100644 --- a/src/libsystemd-network/dhcp-server-lease-internal.h +++ b/src/libsystemd-network/dhcp-server-lease-internal.h @@ -5,7 +5,7 @@ #include "dhcp-client-id-internal.h" #include "dhcp-server-internal.h" -#include "forward.h" +#include "sd-forward.h" typedef struct sd_dhcp_server_lease { unsigned n_ref; diff --git a/src/libsystemd-network/dhcp6-client-internal.h b/src/libsystemd-network/dhcp6-client-internal.h index 1a84053735..2c68263508 100644 --- a/src/libsystemd-network/dhcp6-client-internal.h +++ b/src/libsystemd-network/dhcp6-client-internal.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "sd-dhcp6-client.h" int dhcp6_client_set_state_callback( diff --git a/src/libsystemd-network/dhcp6-internal.h b/src/libsystemd-network/dhcp6-internal.h index 5762966c26..faa82c230b 100644 --- a/src/libsystemd-network/dhcp6-internal.h +++ b/src/libsystemd-network/dhcp6-internal.h @@ -13,7 +13,7 @@ #include "dhcp-duid-internal.h" #include "dhcp6-option.h" #include "dhcp6-protocol.h" -#include "forward.h" +#include "sd-forward.h" #include "network-common.h" #include "sparse-endian.h" diff --git a/src/libsystemd-network/dhcp6-lease-internal.h b/src/libsystemd-network/dhcp6-lease-internal.h index a841ce6271..f2f4cbc690 100644 --- a/src/libsystemd-network/dhcp6-lease-internal.h +++ b/src/libsystemd-network/dhcp6-lease-internal.h @@ -9,7 +9,7 @@ #include "dhcp6-option.h" #include "dhcp6-protocol.h" -#include "forward.h" +#include "sd-forward.h" #include "time-util.h" struct sd_dhcp6_lease { diff --git a/src/libsystemd-network/dhcp6-option.h b/src/libsystemd-network/dhcp6-option.h index 9deee41ae4..7142853197 100644 --- a/src/libsystemd-network/dhcp6-option.h +++ b/src/libsystemd-network/dhcp6-option.h @@ -5,7 +5,7 @@ #include "sd-dhcp6-option.h" /* IWYU pragma: export */ -#include "forward.h" +#include "sd-forward.h" #include "list.h" #include "sparse-endian.h" diff --git a/src/libsystemd-network/dhcp6-protocol.h b/src/libsystemd-network/dhcp6-protocol.h index 794b003248..020088ba74 100644 --- a/src/libsystemd-network/dhcp6-protocol.h +++ b/src/libsystemd-network/dhcp6-protocol.h @@ -5,7 +5,7 @@ Copyright © 2014 Intel Corporation. All rights reserved. ***/ -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" struct DHCP6Message { diff --git a/src/libsystemd-network/dns-resolver-internal.h b/src/libsystemd-network/dns-resolver-internal.h index 1ae775096d..1e53df51cf 100644 --- a/src/libsystemd-network/dns-resolver-internal.h +++ b/src/libsystemd-network/dns-resolver-internal.h @@ -3,7 +3,7 @@ #include "sd-dns-resolver.h" -#include "forward.h" +#include "sd-forward.h" #include "socket-netlink.h" /* https://www.iana.org/assignments/dns-svcb/dns-svcb.xhtml#dns-svcparamkeys */ diff --git a/src/libsystemd-network/icmp6-packet.h b/src/libsystemd-network/icmp6-packet.h index 3ae33a2039..929fff1f23 100644 --- a/src/libsystemd-network/icmp6-packet.h +++ b/src/libsystemd-network/icmp6-packet.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" #include "time-util.h" typedef struct ICMP6Packet { diff --git a/src/libsystemd-network/icmp6-util.h b/src/libsystemd-network/icmp6-util.h index a904564dfe..a1183724b2 100644 --- a/src/libsystemd-network/icmp6-util.h +++ b/src/libsystemd-network/icmp6-util.h @@ -7,7 +7,7 @@ #include -#include "forward.h" +#include "sd-forward.h" #define IN6_ADDR_ALL_ROUTERS_MULTICAST \ ((const struct in6_addr) { { { \ diff --git a/src/libsystemd-network/lldp-neighbor.h b/src/libsystemd-network/lldp-neighbor.h index 9a2dc7d81d..2060474e2a 100644 --- a/src/libsystemd-network/lldp-neighbor.h +++ b/src/libsystemd-network/lldp-neighbor.h @@ -5,7 +5,7 @@ #include "sd-lldp-rx.h" -#include "forward.h" +#include "sd-forward.h" #include "memory-util.h" #include "time-util.h" diff --git a/src/libsystemd-network/lldp-rx-internal.h b/src/libsystemd-network/lldp-rx-internal.h index 9c451c183d..a47eede68a 100644 --- a/src/libsystemd-network/lldp-rx-internal.h +++ b/src/libsystemd-network/lldp-rx-internal.h @@ -6,7 +6,7 @@ #include "sd-lldp-rx.h" /* IWYU pragma: export */ #include "network-common.h" -#include "forward.h" +#include "sd-forward.h" struct sd_lldp_rx { unsigned n_ref; diff --git a/src/libsystemd-network/ndisc-internal.h b/src/libsystemd-network/ndisc-internal.h index f0488cff8d..dfa38cd61f 100644 --- a/src/libsystemd-network/ndisc-internal.h +++ b/src/libsystemd-network/ndisc-internal.h @@ -11,7 +11,7 @@ #include "sd-event.h" #include "sd-ndisc.h" /* IWYU pragma: export */ -#include "forward.h" +#include "sd-forward.h" #include "network-common.h" #include "time-util.h" diff --git a/src/libsystemd-network/ndisc-neighbor-internal.h b/src/libsystemd-network/ndisc-neighbor-internal.h index 295c093b43..2b54aac8ed 100644 --- a/src/libsystemd-network/ndisc-neighbor-internal.h +++ b/src/libsystemd-network/ndisc-neighbor-internal.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" typedef struct sd_ndisc_neighbor { unsigned n_ref; diff --git a/src/libsystemd-network/ndisc-redirect-internal.h b/src/libsystemd-network/ndisc-redirect-internal.h index 77d6f8b88f..96a0156f37 100644 --- a/src/libsystemd-network/ndisc-redirect-internal.h +++ b/src/libsystemd-network/ndisc-redirect-internal.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" typedef struct sd_ndisc_redirect { unsigned n_ref; diff --git a/src/libsystemd-network/ndisc-router-solicit-internal.h b/src/libsystemd-network/ndisc-router-solicit-internal.h index 2186238a6f..1c57e9d0b4 100644 --- a/src/libsystemd-network/ndisc-router-solicit-internal.h +++ b/src/libsystemd-network/ndisc-router-solicit-internal.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef struct sd_ndisc_router_solicit { unsigned n_ref; diff --git a/src/libsystemd-network/network-common.h b/src/libsystemd-network/network-common.h index 933ce170b7..87a51c76fc 100644 --- a/src/libsystemd-network/network-common.h +++ b/src/libsystemd-network/network-common.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "log-link.h" #include "sparse-endian.h" #include "time-util.h" diff --git a/src/libsystemd-network/network-internal.h b/src/libsystemd-network/network-internal.h index aace983d5b..7e22723976 100644 --- a/src/libsystemd-network/network-internal.h +++ b/src/libsystemd-network/network-internal.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" size_t serialize_in_addrs(FILE *f, const struct in_addr *addresses, diff --git a/src/libsystemd-network/radv-internal.h b/src/libsystemd-network/radv-internal.h index 0e34176e8c..673d863ca3 100644 --- a/src/libsystemd-network/radv-internal.h +++ b/src/libsystemd-network/radv-internal.h @@ -7,7 +7,7 @@ #include -#include "forward.h" +#include "sd-forward.h" #include "network-common.h" #include "time-util.h" diff --git a/src/libsystemd-network/sd-dns-resolver.h b/src/libsystemd-network/sd-dns-resolver.h index 8a574263cc..02f39bc90b 100644 --- a/src/libsystemd-network/sd-dns-resolver.h +++ b/src/libsystemd-network/sd-dns-resolver.h @@ -3,7 +3,7 @@ #include "_sd-common.h" -#include "forward.h" +#include "sd-forward.h" _SD_BEGIN_DECLARATIONS; diff --git a/src/libsystemd/sd-bus/bus-container.h b/src/libsystemd/sd-bus/bus-container.h index bca37304c0..2e933bd9a7 100644 --- a/src/libsystemd/sd-bus/bus-container.h +++ b/src/libsystemd/sd-bus/bus-container.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int bus_container_connect_socket(sd_bus *b); diff --git a/src/libsystemd/sd-bus/bus-control.h b/src/libsystemd/sd-bus/bus-control.h index 56b4a70cda..9f65eda23a 100644 --- a/src/libsystemd/sd-bus/bus-control.h +++ b/src/libsystemd/sd-bus/bus-control.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int bus_add_match_internal(sd_bus *bus, const char *match, uint64_t timeout_usec, uint64_t *ret_counter); int bus_add_match_internal_async(sd_bus *bus, sd_bus_slot **ret, const char *match, sd_bus_message_handler_t callback, void *userdata, uint64_t timeout_usec); diff --git a/src/libsystemd/sd-bus/bus-creds.h b/src/libsystemd/sd-bus/bus-creds.h index 089442e885..212da42055 100644 --- a/src/libsystemd/sd-bus/bus-creds.h +++ b/src/libsystemd/sd-bus/bus-creds.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef struct sd_bus_creds { bool allocated; diff --git a/src/libsystemd/sd-bus/bus-dump.h b/src/libsystemd/sd-bus/bus-dump.h index ba38da1686..ecf7598c85 100644 --- a/src/libsystemd/sd-bus/bus-dump.h +++ b/src/libsystemd/sd-bus/bus-dump.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int bus_creds_dump(sd_bus_creds *c, FILE *f, bool terse); diff --git a/src/libsystemd/sd-bus/bus-error.h b/src/libsystemd/sd-bus/bus-error.h index 3757fe7c27..ac3c90c0d3 100644 --- a/src/libsystemd/sd-bus/bus-error.h +++ b/src/libsystemd/sd-bus/bus-error.h @@ -4,7 +4,7 @@ #include "sd-bus-protocol.h" #include "errno-util.h" -#include "forward.h" +#include "sd-forward.h" bool bus_error_is_dirty(sd_bus_error *e); diff --git a/src/libsystemd/sd-bus/bus-forward.h b/src/libsystemd/sd-bus/bus-forward.h index 0b5433d6b6..7208e89c1b 100644 --- a/src/libsystemd/sd-bus/bus-forward.h +++ b/src/libsystemd/sd-bus/bus-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef enum BusAuth BusAuth; typedef enum BusSlotType BusSlotType; diff --git a/src/libsystemd/sd-bus/bus-kernel.h b/src/libsystemd/sd-bus/bus-kernel.h index c364f62a8d..544ee542bc 100644 --- a/src/libsystemd/sd-bus/bus-kernel.h +++ b/src/libsystemd/sd-bus/bus-kernel.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #define MEMFD_CACHE_MAX 32 diff --git a/src/libsystemd/sd-bus/bus-signature.h b/src/libsystemd/sd-bus/bus-signature.h index b75df7335d..3af5091ed4 100644 --- a/src/libsystemd/sd-bus/bus-signature.h +++ b/src/libsystemd/sd-bus/bus-signature.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" bool signature_is_single(const char *s, bool allow_dict_entry); bool signature_is_pair(const char *s); diff --git a/src/libsystemd/sd-bus/bus-socket.h b/src/libsystemd/sd-bus/bus-socket.h index 1c1d3561ee..0356f64a4b 100644 --- a/src/libsystemd/sd-bus/bus-socket.h +++ b/src/libsystemd/sd-bus/bus-socket.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" void bus_socket_setup(sd_bus *b); diff --git a/src/libsystemd/sd-bus/bus-track.h b/src/libsystemd/sd-bus/bus-track.h index 0ecd42e6d3..baa9d247d7 100644 --- a/src/libsystemd/sd-bus/bus-track.h +++ b/src/libsystemd/sd-bus/bus-track.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" void bus_track_dispatch(sd_bus_track *track); void bus_track_close(sd_bus_track *track); diff --git a/src/libsystemd/sd-bus/bus-type.h b/src/libsystemd/sd-bus/bus-type.h index 0e851b0249..b6ec78f827 100644 --- a/src/libsystemd/sd-bus/bus-type.h +++ b/src/libsystemd/sd-bus/bus-type.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" bool bus_type_is_valid(char c) _const_; bool bus_type_is_basic(char c) _const_; diff --git a/src/libsystemd/sd-common/sd-forward.h b/src/libsystemd/sd-common/sd-forward.h new file mode 100644 index 0000000000..0e9e16d91f --- /dev/null +++ b/src/libsystemd/sd-common/sd-forward.h @@ -0,0 +1,127 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ +#pragma once + +/* IWYU pragma: always_keep */ + +#include "basic-forward.h" /* IWYU pragma: export */ + +typedef void (*_sd_destroy_t)(void *userdata); + +typedef union sd_id128 sd_id128_t; + +typedef struct sd_event sd_event; +typedef struct sd_event_source sd_event_source; + +typedef int (*sd_event_handler_t)(sd_event_source *s, void *userdata); +typedef int (*sd_event_io_handler_t)(sd_event_source *s, int fd, uint32_t revents, void *userdata); +typedef int (*sd_event_time_handler_t)(sd_event_source *s, uint64_t usec, void *userdata); +typedef int (*sd_event_signal_handler_t)(sd_event_source *s, const struct signalfd_siginfo *si, void *userdata); +typedef int (*sd_event_inotify_handler_t)(sd_event_source *s, const struct inotify_event *event, void *userdata); +typedef _sd_destroy_t sd_event_destroy_t; + +enum ENUM_TYPE_S64(sd_json_format_flags_t); +enum ENUM_TYPE_S64(sd_json_dispatch_flags_t); +enum ENUM_TYPE_S64(sd_json_variant_type_t); +enum ENUM_TYPE_S64(sd_json_parse_flags_t); + +typedef enum sd_json_format_flags_t sd_json_format_flags_t; +typedef enum sd_json_dispatch_flags_t sd_json_dispatch_flags_t; +typedef enum sd_json_variant_type_t sd_json_variant_type_t; +typedef enum sd_json_parse_flags_t sd_json_parse_flags_t; + +typedef struct sd_json_variant sd_json_variant; + +typedef struct sd_bus sd_bus; +typedef struct sd_bus_error sd_bus_error; +typedef struct sd_bus_error_map sd_bus_error_map; +typedef struct sd_bus_message sd_bus_message; +typedef struct sd_bus_slot sd_bus_slot; +typedef struct sd_bus_creds sd_bus_creds; +typedef struct sd_bus_track sd_bus_track; +typedef struct sd_bus_vtable sd_bus_vtable; + +typedef int (*sd_bus_message_handler_t)(sd_bus_message *m, void *userdata, sd_bus_error *ret_error); +typedef int (*sd_bus_property_get_t)(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *reply, void *userdata, sd_bus_error *ret_error); +typedef int (*sd_bus_property_set_t)(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *value, void *userdata, sd_bus_error *ret_error); +typedef int (*sd_bus_object_find_t)(sd_bus *bus, const char *path, const char *interface, void *userdata, void **ret_found, sd_bus_error *ret_error); +typedef int (*sd_bus_node_enumerator_t)(sd_bus *bus, const char *prefix, void *userdata, char ***ret_nodes, sd_bus_error *ret_error); +typedef int (*sd_bus_track_handler_t)(sd_bus_track *track, void *userdata); +typedef _sd_destroy_t sd_bus_destroy_t; + +enum ENUM_TYPE_S64(sd_device_action_t); + +typedef enum sd_device_action_t sd_device_action_t; + +typedef struct sd_device sd_device; +typedef struct sd_device_enumerator sd_device_enumerator; +typedef struct sd_device_monitor sd_device_monitor; + +typedef struct sd_netlink sd_netlink; +typedef struct sd_netlink_message sd_netlink_message; +typedef struct sd_netlink_slot sd_netlink_slot; + +typedef int (*sd_netlink_message_handler_t)(sd_netlink *nl, sd_netlink_message *m, void *userdata); +typedef _sd_destroy_t sd_netlink_destroy_t; + +typedef struct sd_network_monitor sd_network_monitor; + +enum ENUM_TYPE_S64(sd_dhcp_lease_server_type_t); +enum ENUM_TYPE_S64(sd_lldp_rx_event_t); +enum ENUM_TYPE_S64(sd_lldp_multicast_mode_t); +enum ENUM_TYPE_S64(sd_ndisc_event_t); + +typedef enum sd_dhcp_lease_server_type_t sd_dhcp_lease_server_type_t; +typedef enum sd_lldp_rx_event_t sd_lldp_rx_event_t; +typedef enum sd_lldp_multicast_mode_t sd_lldp_multicast_mode_t; +typedef enum sd_ndisc_event_t sd_ndisc_event_t; + +typedef struct sd_ipv4ll sd_ipv4ll; +typedef struct sd_dhcp_client sd_dhcp_client; +typedef struct sd_dhcp_lease sd_dhcp_lease; +typedef struct sd_dhcp_route sd_dhcp_route; +typedef struct sd_dns_resolver sd_dns_resolver; +typedef struct sd_dhcp_server sd_dhcp_server; +typedef struct sd_ndisc sd_ndisc; +typedef struct sd_radv sd_radv; +typedef struct sd_dhcp6_client sd_dhcp6_client; +typedef struct sd_dhcp6_lease sd_dhcp6_lease; +typedef struct sd_lldp_tx sd_lldp_tx; +typedef struct sd_lldp_rx sd_lldp_rx; +typedef struct sd_lldp_neighbor sd_lldp_neighbor; + +typedef struct ICMP6Packet ICMP6Packet; + +enum ENUM_TYPE_S64(sd_varlink_method_flags_t); +enum ENUM_TYPE_S64(sd_varlink_interface_flags_t); +enum ENUM_TYPE_S64(sd_varlink_symbol_type_t); +enum ENUM_TYPE_S64(sd_varlink_field_type_t); +enum ENUM_TYPE_S64(sd_varlink_field_direction_t); +enum ENUM_TYPE_S64(sd_varlink_field_flags_t); +enum ENUM_TYPE_S64(sd_varlink_idl_format_flags_t); +enum ENUM_TYPE_S64(sd_varlink_reply_flags_t); +enum ENUM_TYPE_S64(sd_varlink_server_flags_t); +enum ENUM_TYPE_S64(sd_varlink_invocation_flags_t); + +typedef enum sd_varlink_method_flags_t sd_varlink_method_flags_t; +typedef enum sd_varlink_interface_flags_t sd_varlink_interface_flags_t; +typedef enum sd_varlink_symbol_type_t sd_varlink_symbol_type_t; +typedef enum sd_varlink_field_type_t sd_varlink_field_type_t; +typedef enum sd_varlink_field_direction_t sd_varlink_field_direction_t; +typedef enum sd_varlink_field_flags_t sd_varlink_field_flags_t; +typedef enum sd_varlink_idl_format_flags_t sd_varlink_idl_format_flags_t; +typedef enum sd_varlink_reply_flags_t sd_varlink_reply_flags_t; +typedef enum sd_varlink_server_flags_t sd_varlink_server_flags_t; +typedef enum sd_varlink_invocation_flags_t sd_varlink_invocation_flags_t; + +typedef struct sd_varlink sd_varlink; +typedef struct sd_varlink_server sd_varlink_server; +typedef struct sd_varlink_field sd_varlink_field; +typedef struct sd_varlink_symbol sd_varlink_symbol; +typedef struct sd_varlink_interface sd_varlink_interface; + +typedef struct sd_journal sd_journal; + +typedef struct sd_resolve sd_resolve; +typedef struct sd_resolve_query sd_resolve_query; + +typedef struct sd_hwdb sd_hwdb; diff --git a/src/libsystemd/sd-device/device-enumerator-private.h b/src/libsystemd/sd-device/device-enumerator-private.h index bcbbf7853f..983eddd188 100644 --- a/src/libsystemd/sd-device/device-enumerator-private.h +++ b/src/libsystemd/sd-device/device-enumerator-private.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef enum MatchInitializedType { MATCH_INITIALIZED_NO, /* only devices without a db entry */ diff --git a/src/libsystemd/sd-device/device-filter.h b/src/libsystemd/sd-device/device-filter.h index d72cbab7e8..8c71aa530e 100644 --- a/src/libsystemd/sd-device/device-filter.h +++ b/src/libsystemd/sd-device/device-filter.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int update_match_strv(Hashmap **match_strv, const char *key, const char *value, bool clear_on_null); bool device_match_sysattr(sd_device *device, Hashmap *match_sysattr, Hashmap *nomatch_sysattr); diff --git a/src/libsystemd/sd-device/device-internal.h b/src/libsystemd/sd-device/device-internal.h index 1f9cf59d51..e85ac9e05e 100644 --- a/src/libsystemd/sd-device/device-internal.h +++ b/src/libsystemd/sd-device/device-internal.h @@ -3,7 +3,7 @@ #include "sd-device.h" -#include "forward.h" +#include "sd-forward.h" #include "iterator.h" #define LATEST_UDEV_DATABASE_VERSION 1 diff --git a/src/libsystemd/sd-device/device-monitor-private.h b/src/libsystemd/sd-device/device-monitor-private.h index 309d4979e2..4582108df6 100644 --- a/src/libsystemd/sd-device/device-monitor-private.h +++ b/src/libsystemd/sd-device/device-monitor-private.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef enum MonitorNetlinkGroup { MONITOR_GROUP_NONE, diff --git a/src/libsystemd/sd-device/device-private.h b/src/libsystemd/sd-device/device-private.h index 5e75c26619..74d6ffd119 100644 --- a/src/libsystemd/sd-device/device-private.h +++ b/src/libsystemd/sd-device/device-private.h @@ -3,7 +3,7 @@ #include "sd-device.h" /* IWYU pragma: export */ -#include "forward.h" +#include "sd-forward.h" int device_new_from_mode_and_devnum(sd_device **ret, mode_t mode, dev_t devnum); int device_new_from_nulstr(sd_device **ret, char *nulstr, size_t len); diff --git a/src/libsystemd/sd-device/device-util.h b/src/libsystemd/sd-device/device-util.h index 136d399d7e..3bbe321f61 100644 --- a/src/libsystemd/sd-device/device-util.h +++ b/src/libsystemd/sd-device/device-util.h @@ -3,7 +3,7 @@ #include "sd-device.h" -#include "forward.h" +#include "sd-forward.h" #include "log.h" #define device_unref_and_replace(a, b) \ diff --git a/src/libsystemd/sd-event/event-source.h b/src/libsystemd/sd-event/event-source.h index 7f6d5b8b50..e4dc456fae 100644 --- a/src/libsystemd/sd-event/event-source.h +++ b/src/libsystemd/sd-event/event-source.h @@ -6,7 +6,7 @@ #include "sd-event.h" -#include "forward.h" +#include "sd-forward.h" #include "inotify-util.h" #include "list.h" #include "ratelimit.h" diff --git a/src/libsystemd/sd-event/event-util.h b/src/libsystemd/sd-event/event-util.h index 7cc56a38d8..dc3b3ed70f 100644 --- a/src/libsystemd/sd-event/event-util.h +++ b/src/libsystemd/sd-event/event-util.h @@ -3,7 +3,7 @@ #include "sd-event.h" -#include "forward.h" +#include "sd-forward.h" extern const struct hash_ops event_source_hash_ops; diff --git a/src/libsystemd/sd-hwdb/hwdb-internal.h b/src/libsystemd/sd-hwdb/hwdb-internal.h index 65c810416a..72b2f777c8 100644 --- a/src/libsystemd/sd-hwdb/hwdb-internal.h +++ b/src/libsystemd/sd-hwdb/hwdb-internal.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" #include "iterator.h" #include "sparse-endian.h" diff --git a/src/libsystemd/sd-id128/id128-util.h b/src/libsystemd/sd-id128/id128-util.h index 874fc9f446..e64921e525 100644 --- a/src/libsystemd/sd-id128/id128-util.h +++ b/src/libsystemd/sd-id128/id128-util.h @@ -4,7 +4,7 @@ #include "sd-id128.h" #include "errno-util.h" -#include "forward.h" +#include "sd-forward.h" bool id128_is_valid(const char *s) _pure_; diff --git a/src/libsystemd/sd-journal/audit-type.h b/src/libsystemd/sd-journal/audit-type.h index 85b4c47bb0..f9ed66fdf8 100644 --- a/src/libsystemd/sd-journal/audit-type.h +++ b/src/libsystemd/sd-journal/audit-type.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" const char* audit_type_to_string(int type); int audit_type_from_string(const char *s); diff --git a/src/libsystemd/sd-journal/catalog.h b/src/libsystemd/sd-journal/catalog.h index b91bd188b5..41dab41fbb 100644 --- a/src/libsystemd/sd-journal/catalog.h +++ b/src/libsystemd/sd-journal/catalog.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int catalog_import_file(OrderedHashmap **h, int fd, const char *path); int catalog_update(const char *database, const char *root, const char* const *dirs); diff --git a/src/libsystemd/sd-journal/fsprg.h b/src/libsystemd/sd-journal/fsprg.h index f65c5f9e06..7ad77136a7 100644 --- a/src/libsystemd/sd-journal/fsprg.h +++ b/src/libsystemd/sd-journal/fsprg.h @@ -7,7 +7,7 @@ * Contact: fsprg@point-at-infinity.org */ -#include "forward.h" +#include "sd-forward.h" #ifdef __cplusplus extern "C" { diff --git a/src/libsystemd/sd-journal/journal-authenticate.h b/src/libsystemd/sd-journal/journal-authenticate.h index 21c69ad30b..3fa9caeaeb 100644 --- a/src/libsystemd/sd-journal/journal-authenticate.h +++ b/src/libsystemd/sd-journal/journal-authenticate.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "journal-file.h" int journal_file_append_tag(JournalFile *f); diff --git a/src/libsystemd/sd-journal/journal-def.h b/src/libsystemd/sd-journal/journal-def.h index 96c193c3fd..f20c9a357a 100644 --- a/src/libsystemd/sd-journal/journal-def.h +++ b/src/libsystemd/sd-journal/journal-def.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "sd-forward.h" #include "sparse-endian.h" /* diff --git a/src/libsystemd/sd-journal/journal-file.h b/src/libsystemd/sd-journal/journal-file.h index f36db99744..472f91f546 100644 --- a/src/libsystemd/sd-journal/journal-file.h +++ b/src/libsystemd/sd-journal/journal-file.h @@ -5,7 +5,7 @@ #include #include "compress.h" -#include "forward.h" +#include "sd-forward.h" #include "gcrypt-util.h" #include "journal-def.h" #include "mmap-cache.h" diff --git a/src/libsystemd/sd-journal/journal-internal.h b/src/libsystemd/sd-journal/journal-internal.h index 15dc934db0..f0a3043974 100644 --- a/src/libsystemd/sd-journal/journal-internal.h +++ b/src/libsystemd/sd-journal/journal-internal.h @@ -3,7 +3,7 @@ #include "journal-file.h" #include "list.h" -#include "forward.h" +#include "sd-forward.h" #include "time-util.h" #define JOURNAL_FILES_MAX 7168u diff --git a/src/libsystemd/sd-journal/journal-vacuum.h b/src/libsystemd/sd-journal/journal-vacuum.h index e134a9d4b9..a9ded061d3 100644 --- a/src/libsystemd/sd-journal/journal-vacuum.h +++ b/src/libsystemd/sd-journal/journal-vacuum.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" int journal_directory_vacuum(const char *directory, uint64_t max_use, uint64_t n_max_files, usec_t max_retention_usec, usec_t *oldest_usec, bool verbose); diff --git a/src/libsystemd/sd-journal/lookup3.h b/src/libsystemd/sd-journal/lookup3.h index e4709490e2..1c5a6e3407 100644 --- a/src/libsystemd/sd-journal/lookup3.h +++ b/src/libsystemd/sd-journal/lookup3.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LicenseRef-lookup3-public-domain */ #pragma once -#include "forward.h" +#include "sd-forward.h" uint32_t jenkins_hashword(const uint32_t *k, size_t length, uint32_t initval) _pure_; void jenkins_hashword2(const uint32_t *k, size_t length, uint32_t *pc, uint32_t *pb); diff --git a/src/libsystemd/sd-journal/mmap-cache.h b/src/libsystemd/sd-journal/mmap-cache.h index bdd3494589..6361e52d09 100644 --- a/src/libsystemd/sd-journal/mmap-cache.h +++ b/src/libsystemd/sd-journal/mmap-cache.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "journal-def.h" typedef struct MMapCache MMapCache; diff --git a/src/libsystemd/sd-json/json-internal.h b/src/libsystemd/sd-json/json-internal.h index d42d1c6be5..badd88ac3c 100644 --- a/src/libsystemd/sd-json/json-internal.h +++ b/src/libsystemd/sd-json/json-internal.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "sd-forward.h" /* This header should include all prototypes only the JSON parser itself and * its tests need access to. Normal code consuming the JSON parser should not diff --git a/src/libsystemd/sd-json/json-util.h b/src/libsystemd/sd-json/json-util.h index abacb298c6..d0db4d8035 100644 --- a/src/libsystemd/sd-json/json-util.h +++ b/src/libsystemd/sd-json/json-util.h @@ -5,7 +5,7 @@ #include "sd-json.h" -#include "forward.h" +#include "sd-forward.h" #include "log.h" #include "string-util.h" diff --git a/src/libsystemd/sd-netlink/netlink-genl.h b/src/libsystemd/sd-netlink/netlink-genl.h index ea9135ac32..26b2ae1cf9 100644 --- a/src/libsystemd/sd-netlink/netlink-genl.h +++ b/src/libsystemd/sd-netlink/netlink-genl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #define CTRL_GENL_NAME "nlctrl" diff --git a/src/libsystemd/sd-netlink/netlink-internal.h b/src/libsystemd/sd-netlink/netlink-internal.h index 479bb07ffb..888637c372 100644 --- a/src/libsystemd/sd-netlink/netlink-internal.h +++ b/src/libsystemd/sd-netlink/netlink-internal.h @@ -4,7 +4,7 @@ #include #include -#include "forward.h" +#include "sd-forward.h" #include "list.h" #include "netlink-types.h" diff --git a/src/libsystemd/sd-netlink/netlink-slot.h b/src/libsystemd/sd-netlink/netlink-slot.h index 9ed1746b61..85f12013d9 100644 --- a/src/libsystemd/sd-netlink/netlink-slot.h +++ b/src/libsystemd/sd-netlink/netlink-slot.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" #include "netlink-internal.h" int netlink_slot_allocate( diff --git a/src/libsystemd/sd-netlink/netlink-types.h b/src/libsystemd/sd-netlink/netlink-types.h index 99d1246ef6..c11e5d9ec0 100644 --- a/src/libsystemd/sd-netlink/netlink-types.h +++ b/src/libsystemd/sd-netlink/netlink-types.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "sd-forward.h" typedef enum NLAType { NETLINK_TYPE_UNSPEC, /* NLA_UNSPEC */ diff --git a/src/libsystemd/sd-netlink/netlink-util.h b/src/libsystemd/sd-netlink/netlink-util.h index a25e38d473..b84018f1bc 100644 --- a/src/libsystemd/sd-netlink/netlink-util.h +++ b/src/libsystemd/sd-netlink/netlink-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "sd-forward.h" #include "in-addr-util.h" #define RTA_FLAGS(rta) ((rta)->rta_type & ~NLA_TYPE_MASK) diff --git a/src/libsystemd/sd-network/network-util.h b/src/libsystemd/sd-network/network-util.h index 84ae36ad36..818c7f73bb 100644 --- a/src/libsystemd/sd-network/network-util.h +++ b/src/libsystemd/sd-network/network-util.h @@ -4,7 +4,7 @@ #include #include "constants.h" -#include "forward.h" +#include "sd-forward.h" #define NETWORK_DIRS ((const char* const*) CONF_PATHS_STRV("systemd/network")) #define NETWORK_DIRS_NULSTR CONF_PATHS_NULSTR("systemd/network") diff --git a/src/libsystemd/sd-path/path-lookup.h b/src/libsystemd/sd-path/path-lookup.h index b706e1a6df..f996dcc2a6 100644 --- a/src/libsystemd/sd-path/path-lookup.h +++ b/src/libsystemd/sd-path/path-lookup.h @@ -3,7 +3,7 @@ #include "sd-path.h" -#include "forward.h" +#include "sd-forward.h" #include "runtime-scope.h" typedef enum LookupPathsFlags { diff --git a/src/libsystemd/sd-varlink/varlink-idl-util.h b/src/libsystemd/sd-varlink/varlink-idl-util.h index 0640a26995..07a6edbfef 100644 --- a/src/libsystemd/sd-varlink/varlink-idl-util.h +++ b/src/libsystemd/sd-varlink/varlink-idl-util.h @@ -4,7 +4,7 @@ #include "sd-varlink.h" #include "sd-varlink-idl.h" -#include "forward.h" +#include "sd-forward.h" bool varlink_idl_field_name_is_valid(const char *name); bool varlink_idl_symbol_name_is_valid(const char *name); diff --git a/src/libsystemd/sd-varlink/varlink-internal.h b/src/libsystemd/sd-varlink/varlink-internal.h index ef84824373..8041a30a5e 100644 --- a/src/libsystemd/sd-varlink/varlink-internal.h +++ b/src/libsystemd/sd-varlink/varlink-internal.h @@ -6,7 +6,7 @@ #include "sd-varlink.h" #include "list.h" -#include "forward.h" +#include "sd-forward.h" typedef enum VarlinkState { /* Client side states */ diff --git a/src/libsystemd/sd-varlink/varlink-util.h b/src/libsystemd/sd-varlink/varlink-util.h index 3a340b2216..c57bea07e0 100644 --- a/src/libsystemd/sd-varlink/varlink-util.h +++ b/src/libsystemd/sd-varlink/varlink-util.h @@ -3,7 +3,7 @@ #include "sd-varlink.h" -#include "forward.h" +#include "sd-forward.h" int varlink_get_peer_pidref(sd_varlink *v, PidRef *ret); diff --git a/src/libudev/libudev-device-internal.h b/src/libudev/libudev-device-internal.h index c872973091..230d1e9703 100644 --- a/src/libudev/libudev-device-internal.h +++ b/src/libudev/libudev-device-internal.h @@ -3,7 +3,7 @@ #include "libudev.h" -#include "forward.h" +#include "shared-forward.h" struct udev_device; diff --git a/src/libudev/libudev-list-internal.h b/src/libudev/libudev-list-internal.h index efe394d1fd..94dbd3ca09 100644 --- a/src/libudev/libudev-list-internal.h +++ b/src/libudev/libudev-list-internal.h @@ -3,7 +3,7 @@ #include "libudev.h" -#include "forward.h" +#include "shared-forward.h" struct udev_list; diff --git a/src/libudev/libudev-util.c b/src/libudev/libudev-util.c index 5ee9ebd03e..e650676851 100644 --- a/src/libudev/libudev-util.c +++ b/src/libudev/libudev-util.c @@ -2,7 +2,7 @@ #include "libudev.h" -#include "forward.h" +#include "shared-forward.h" #include "device-nodes.h" /** diff --git a/src/libudev/libudev-util.h b/src/libudev/libudev-util.h index eb899f9f1d..041a14120f 100644 --- a/src/libudev/libudev-util.h +++ b/src/libudev/libudev-util.h @@ -3,7 +3,7 @@ #include "libudev.h" -#include "forward.h" +#include "shared-forward.h" /* Cleanup functions */ DEFINE_TRIVIAL_CLEANUP_FUNC(struct udev*, udev_unref); diff --git a/src/locale/localed-util.h b/src/locale/localed-util.h index 888313b001..35f86d66e3 100644 --- a/src/locale/localed-util.h +++ b/src/locale/localed-util.h @@ -4,7 +4,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "locale-setup.h" #include "vconsole-util.h" diff --git a/src/locale/xkbcommon-util.h b/src/locale/xkbcommon-util.h index 7d4071fd79..1a709ae50c 100644 --- a/src/locale/xkbcommon-util.h +++ b/src/locale/xkbcommon-util.h @@ -2,7 +2,7 @@ #pragma once #include "dlfcn-util.h" -#include "forward.h" +#include "shared-forward.h" #if HAVE_XKBCOMMON #include diff --git a/src/login/logind-forward.h b/src/login/logind-forward.h index 308749b81f..e9b9ebce37 100644 --- a/src/login/logind-forward.h +++ b/src/login/logind-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum InhibitWhat InhibitWhat; typedef enum KillWhom KillWhom; diff --git a/src/login/logind-user.h b/src/login/logind-user.h index f41b8888ea..d3773996fa 100644 --- a/src/login/logind-user.h +++ b/src/login/logind-user.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "logind-forward.h" #include "time-util.h" diff --git a/src/login/sysfs-show.h b/src/login/sysfs-show.h index 0864419877..fe4420c624 100644 --- a/src/login/sysfs-show.h +++ b/src/login/sysfs-show.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "output-mode.h" int show_sysfs(const char *seat, const char *prefix, unsigned columns, OutputFlags flags); diff --git a/src/machine/machine-forward.h b/src/machine/machine-forward.h index e01550b25b..ff7b98fc45 100644 --- a/src/machine/machine-forward.h +++ b/src/machine/machine-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef struct Machine Machine; typedef struct Manager Manager; diff --git a/src/mountfsd/mountfsd-manager.h b/src/mountfsd/mountfsd-manager.h index 06bd15f09a..457ec0e6f2 100644 --- a/src/mountfsd/mountfsd-manager.h +++ b/src/mountfsd/mountfsd-manager.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "ratelimit.h" #define MOUNTFS_WORKERS_MIN 3 diff --git a/src/network/netdev/bareudp.h b/src/network/netdev/bareudp.h index 287769fa83..0b9ef0461d 100644 --- a/src/network/netdev/bareudp.h +++ b/src/network/netdev/bareudp.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef enum BareUDPProtocol { diff --git a/src/network/netdev/batadv.h b/src/network/netdev/batadv.h index df6183e27c..20d6e8c6e0 100644 --- a/src/network/netdev/batadv.h +++ b/src/network/netdev/batadv.h @@ -4,7 +4,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" #define BATADV_GENL_NAME "batadv" diff --git a/src/network/netdev/bond.h b/src/network/netdev/bond.h index 8ae0c9650f..fa799047c7 100644 --- a/src/network/netdev/bond.h +++ b/src/network/netdev/bond.h @@ -2,7 +2,7 @@ #pragma once #include "bond-util.h" -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct Bond { diff --git a/src/network/netdev/bridge.h b/src/network/netdev/bridge.h index 1949f5ccd7..4279c74517 100644 --- a/src/network/netdev/bridge.h +++ b/src/network/netdev/bridge.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" #define LINK_BRIDGE_PORT_PRIORITY_INVALID 128U diff --git a/src/network/netdev/dummy.h b/src/network/netdev/dummy.h index 725f458399..5ee79b6496 100644 --- a/src/network/netdev/dummy.h +++ b/src/network/netdev/dummy.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct Dummy { diff --git a/src/network/netdev/fou-tunnel.h b/src/network/netdev/fou-tunnel.h index 0a8fabec5e..6dc051adbb 100644 --- a/src/network/netdev/fou-tunnel.h +++ b/src/network/netdev/fou-tunnel.h @@ -4,7 +4,7 @@ #include #include "in-addr-util.h" -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef enum FooOverUDPEncapType { diff --git a/src/network/netdev/geneve.h b/src/network/netdev/geneve.h index 9ad8eeaebb..5a03830d98 100644 --- a/src/network/netdev/geneve.h +++ b/src/network/netdev/geneve.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" #include "netdev.h" diff --git a/src/network/netdev/l2tp-tunnel.h b/src/network/netdev/l2tp-tunnel.h index 2c4d2806fa..885791b20e 100644 --- a/src/network/netdev/l2tp-tunnel.h +++ b/src/network/netdev/l2tp-tunnel.h @@ -4,7 +4,7 @@ #include #include "in-addr-util.h" -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef enum L2tpL2specType { diff --git a/src/network/netdev/macsec.h b/src/network/netdev/macsec.h index 3060a9a47c..09def58d96 100644 --- a/src/network/netdev/macsec.h +++ b/src/network/netdev/macsec.h @@ -4,7 +4,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" #include "sparse-endian.h" diff --git a/src/network/netdev/tunnel.h b/src/network/netdev/tunnel.h index 0f3af1efde..0d97a71f1e 100644 --- a/src/network/netdev/tunnel.h +++ b/src/network/netdev/tunnel.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "fou-tunnel.h" #include "netdev.h" #include "networkd-link.h" diff --git a/src/network/netdev/tuntap.h b/src/network/netdev/tuntap.h index 406f2c3f78..e832b3dd5a 100644 --- a/src/network/netdev/tuntap.h +++ b/src/network/netdev/tuntap.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct TunTap { diff --git a/src/network/netdev/vlan.h b/src/network/netdev/vlan.h index 073f21a9f3..48ee0e5428 100644 --- a/src/network/netdev/vlan.h +++ b/src/network/netdev/vlan.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct VLan { diff --git a/src/network/netdev/wlan.h b/src/network/netdev/wlan.h index 4b4ca79b60..4c63a3048a 100644 --- a/src/network/netdev/wlan.h +++ b/src/network/netdev/wlan.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct WLan { diff --git a/src/network/netdev/xfrm.h b/src/network/netdev/xfrm.h index aafbca8939..c850c72833 100644 --- a/src/network/netdev/xfrm.h +++ b/src/network/netdev/xfrm.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "netdev.h" typedef struct Xfrm { diff --git a/src/network/networkctl-dump-util.h b/src/network/networkctl-dump-util.h index e7950a59ac..cfd0dd3de0 100644 --- a/src/network/networkctl-dump-util.h +++ b/src/network/networkctl-dump-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int dump_list(Table *table, const char *key, char * const *l); int ieee_oui(sd_hwdb *hwdb, const struct ether_addr *mac, char **ret); diff --git a/src/network/networkctl-link-info.h b/src/network/networkctl-link-info.h index 1dfd910e35..cb0f3a9b16 100644 --- a/src/network/networkctl-link-info.h +++ b/src/network/networkctl-link-info.h @@ -6,7 +6,7 @@ #include "ether-addr-util.h" #include "ethtool-util.h" -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" typedef struct VxLanInfo { diff --git a/src/network/networkctl-lldp.h b/src/network/networkctl-lldp.h index abbab83133..2225fc3abd 100644 --- a/src/network/networkctl-lldp.h +++ b/src/network/networkctl-lldp.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int dump_lldp_neighbors(sd_varlink *vl, Table *table, int ifindex); int link_lldp_status(int argc, char *argv[], void *userdata); diff --git a/src/network/networkctl-status-system.h b/src/network/networkctl-status-system.h index a3292a85f0..1c02aa38ce 100644 --- a/src/network/networkctl-status-system.h +++ b/src/network/networkctl-status-system.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int system_status(sd_netlink *rtnl, sd_hwdb *hwdb); diff --git a/src/network/networkctl-util.h b/src/network/networkctl-util.h index c8e2be8cd5..b2721f5ea2 100644 --- a/src/network/networkctl-util.h +++ b/src/network/networkctl-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int varlink_connect_networkd(sd_varlink **ret_varlink); bool networkd_is_running(void); diff --git a/src/network/networkctl.h b/src/network/networkctl.h index 39c81e7947..e15f524948 100644 --- a/src/network/networkctl.h +++ b/src/network/networkctl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "pager.h" extern PagerFlags arg_pager_flags; diff --git a/src/network/networkd-address.h b/src/network/networkd-address.h index 0edac279fa..1304e41f8c 100644 --- a/src/network/networkd-address.h +++ b/src/network/networkd-address.h @@ -2,7 +2,7 @@ #pragma once #include "firewall-util.h" -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" #include "networkd-forward.h" #include "networkd-util.h" diff --git a/src/network/networkd-bridge-fdb.h b/src/network/networkd-bridge-fdb.h index 0c60a4ad1b..b53235a8eb 100644 --- a/src/network/networkd-bridge-fdb.h +++ b/src/network/networkd-bridge-fdb.h @@ -8,7 +8,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" #include "networkd-forward.h" diff --git a/src/network/networkd-forward.h b/src/network/networkd-forward.h index b1b385f16a..f004fc6a47 100644 --- a/src/network/networkd-forward.h +++ b/src/network/networkd-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum NetDevLocalAddressType NetDevLocalAddressType; typedef enum NetworkConfigSource NetworkConfigSource; diff --git a/src/network/networkd-link.h b/src/network/networkd-link.h index 02e1a5a363..5622677600 100644 --- a/src/network/networkd-link.h +++ b/src/network/networkd-link.h @@ -4,7 +4,7 @@ #include #include "ether-addr-util.h" -#include "forward.h" +#include "shared-forward.h" #include "network-util.h" #include "networkd-bridge-vlan.h" #include "networkd-forward.h" diff --git a/src/network/tc/drr.h b/src/network/tc/drr.h index 54c6c7cafe..0ff95c43bc 100644 --- a/src/network/tc/drr.h +++ b/src/network/tc/drr.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" #include "tclass.h" diff --git a/src/network/tc/ets.h b/src/network/tc/ets.h index 6aa06ed15c..2841d342c0 100644 --- a/src/network/tc/ets.h +++ b/src/network/tc/ets.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct EnhancedTransmissionSelection { diff --git a/src/network/tc/fifo.h b/src/network/tc/fifo.h index 41af459f53..111a63caa9 100644 --- a/src/network/tc/fifo.h +++ b/src/network/tc/fifo.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct FirstInFirstOut { diff --git a/src/network/tc/fq-codel.h b/src/network/tc/fq-codel.h index ac9fe045ae..ab2a3e4e5e 100644 --- a/src/network/tc/fq-codel.h +++ b/src/network/tc/fq-codel.h @@ -2,7 +2,7 @@ * Copyright © 2019 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct FairQueueingControlledDelay { diff --git a/src/network/tc/fq-pie.h b/src/network/tc/fq-pie.h index b5acb78bac..a287bf3435 100644 --- a/src/network/tc/fq-pie.h +++ b/src/network/tc/fq-pie.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct FlowQueuePIE { diff --git a/src/network/tc/fq.h b/src/network/tc/fq.h index 35fa509983..0f10641573 100644 --- a/src/network/tc/fq.h +++ b/src/network/tc/fq.h @@ -2,7 +2,7 @@ * Copyright © 2019 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct FairQueueing { diff --git a/src/network/tc/gred.h b/src/network/tc/gred.h index c68e80db15..6c87c2534a 100644 --- a/src/network/tc/gred.h +++ b/src/network/tc/gred.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct GenericRandomEarlyDetection { diff --git a/src/network/tc/hhf.h b/src/network/tc/hhf.h index 466336692c..59c09e6f0a 100644 --- a/src/network/tc/hhf.h +++ b/src/network/tc/hhf.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct HeavyHitterFilter { diff --git a/src/network/tc/htb.h b/src/network/tc/htb.h index e5897377a8..5151f1a31d 100644 --- a/src/network/tc/htb.h +++ b/src/network/tc/htb.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" #include "tclass.h" diff --git a/src/network/tc/mq.c b/src/network/tc/mq.c index 3f0cbbb414..e9225165d4 100644 --- a/src/network/tc/mq.c +++ b/src/network/tc/mq.c @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" #include "mq.h" const QDiscVTable mq_vtable = { diff --git a/src/network/tc/mq.h b/src/network/tc/mq.h index d963f886fe..4df7158951 100644 --- a/src/network/tc/mq.h +++ b/src/network/tc/mq.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct ClassfulMultiQueueing { diff --git a/src/network/tc/multiq.h b/src/network/tc/multiq.h index 132ffdf34d..0c54f2066d 100644 --- a/src/network/tc/multiq.h +++ b/src/network/tc/multiq.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct BandMultiQueueing { diff --git a/src/network/tc/netem.h b/src/network/tc/netem.h index 3d5c7208c3..7f9e5c5789 100644 --- a/src/network/tc/netem.h +++ b/src/network/tc/netem.h @@ -2,7 +2,7 @@ * Copyright © 2019 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct NetworkEmulator { diff --git a/src/network/tc/pie.h b/src/network/tc/pie.h index 09e7ee4ddd..714c197182 100644 --- a/src/network/tc/pie.h +++ b/src/network/tc/pie.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct ProportionalIntegralControllerEnhanced { diff --git a/src/network/tc/qfq.h b/src/network/tc/qfq.h index f476f346c4..4c6dbb2600 100644 --- a/src/network/tc/qfq.h +++ b/src/network/tc/qfq.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" #include "tclass.h" diff --git a/src/network/tc/sfb.h b/src/network/tc/sfb.h index e20d62fceb..c46c1789eb 100644 --- a/src/network/tc/sfb.h +++ b/src/network/tc/sfb.h @@ -2,7 +2,7 @@ * Copyright © 2020 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct StochasticFairBlue { diff --git a/src/network/tc/sfq.h b/src/network/tc/sfq.h index 3fe6a270b1..bca9f6ba05 100644 --- a/src/network/tc/sfq.h +++ b/src/network/tc/sfq.h @@ -2,7 +2,7 @@ * Copyright © 2019 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct StochasticFairnessQueueing { diff --git a/src/network/tc/tbf.h b/src/network/tc/tbf.h index 173f01cdd6..86f460a257 100644 --- a/src/network/tc/tbf.h +++ b/src/network/tc/tbf.h @@ -2,7 +2,7 @@ * Copyright © 2019 VMware, Inc. */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct TokenBucketFilter { diff --git a/src/network/tc/tc-util.h b/src/network/tc/tc-util.h index 5c2ab002b4..d3a4bd173e 100644 --- a/src/network/tc/tc-util.h +++ b/src/network/tc/tc-util.h @@ -4,7 +4,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int tc_init(double *ret_ticks_in_usec, uint32_t *ret_hz); int tc_time_to_tick(usec_t t, uint32_t *ret); diff --git a/src/network/tc/teql.h b/src/network/tc/teql.h index 99abdc6e7f..6469946681 100644 --- a/src/network/tc/teql.h +++ b/src/network/tc/teql.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "qdisc.h" typedef struct TrivialLinkEqualizer { diff --git a/src/network/wait-online/dns-configuration.h b/src/network/wait-online/dns-configuration.h index 535c095137..e865defaab 100644 --- a/src/network/wait-online/dns-configuration.h +++ b/src/network/wait-online/dns-configuration.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef struct DNSServer { struct iovec addr; diff --git a/src/network/wait-online/wait-online-link.h b/src/network/wait-online/wait-online-link.h index 20b1764cfb..6af89ad735 100644 --- a/src/network/wait-online/wait-online-link.h +++ b/src/network/wait-online/wait-online-link.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "network-util.h" typedef struct DNSConfiguration DNSConfiguration; diff --git a/src/network/wait-online/wait-online-manager.h b/src/network/wait-online/wait-online-manager.h index 591552dc24..795aef251c 100644 --- a/src/network/wait-online/wait-online-manager.h +++ b/src/network/wait-online/wait-online-manager.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "network-util.h" typedef struct DNSConfiguration DNSConfiguration; diff --git a/src/nspawn/nspawn-bind-user.h b/src/nspawn/nspawn-bind-user.h index d4154218c0..672c23b251 100644 --- a/src/nspawn/nspawn-bind-user.h +++ b/src/nspawn/nspawn-bind-user.h @@ -1,5 +1,5 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int bind_user_setup(const MachineBindUserContext *c, const char *root); diff --git a/src/nspawn/nspawn-cgroup.h b/src/nspawn/nspawn-cgroup.h index 8d61513ad5..ae565bf1e1 100644 --- a/src/nspawn/nspawn-cgroup.h +++ b/src/nspawn/nspawn-cgroup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "nspawn-settings.h" int create_subcgroup( diff --git a/src/nspawn/nspawn-expose-ports.h b/src/nspawn/nspawn-expose-ports.h index 3a17179462..d68349bfde 100644 --- a/src/nspawn/nspawn-expose-ports.h +++ b/src/nspawn/nspawn-expose-ports.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "list.h" typedef struct ExposePort { diff --git a/src/nspawn/nspawn-mount.h b/src/nspawn/nspawn-mount.h index f049cf4aee..421c5dffff 100644 --- a/src/nspawn/nspawn-mount.h +++ b/src/nspawn/nspawn-mount.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "volatile-util.h" typedef enum MountSettingsMask { diff --git a/src/nspawn/nspawn-network.h b/src/nspawn/nspawn-network.h index 692c40108c..d2234d2e3a 100644 --- a/src/nspawn/nspawn-network.h +++ b/src/nspawn/nspawn-network.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int test_network_interfaces_initialized(char **iface_pairs); int resolve_network_interface_names(char **iface_pairs); diff --git a/src/nspawn/nspawn-oci.h b/src/nspawn/nspawn-oci.h index cb97c33853..7c30afbcce 100644 --- a/src/nspawn/nspawn-oci.h +++ b/src/nspawn/nspawn-oci.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "nspawn-settings.h" int oci_load(FILE *f, const char *path, Settings **ret); diff --git a/src/nspawn/nspawn-register.h b/src/nspawn/nspawn-register.h index c81e4dac45..c4b8048606 100644 --- a/src/nspawn/nspawn-register.h +++ b/src/nspawn/nspawn-register.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "nspawn-settings.h" int register_machine( diff --git a/src/nspawn/nspawn-seccomp.h b/src/nspawn/nspawn-seccomp.h index 03c378505d..31520a0930 100644 --- a/src/nspawn/nspawn-seccomp.h +++ b/src/nspawn/nspawn-seccomp.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int setup_seccomp(uint64_t cap_list_retain, char **syscall_allow_list, char **syscall_deny_list); diff --git a/src/nspawn/nspawn-settings.h b/src/nspawn/nspawn-settings.h index 5b36c2ad47..5d3891647d 100644 --- a/src/nspawn/nspawn-settings.h +++ b/src/nspawn/nspawn-settings.h @@ -6,7 +6,7 @@ #include "capability-util.h" #include "conf-parser-forward.h" #include "cpu-set-util.h" -#include "forward.h" +#include "shared-forward.h" #include "rlimit-util.h" #include "seccomp-util.h" #include "volatile-util.h" diff --git a/src/nspawn/nspawn-setuid.h b/src/nspawn/nspawn-setuid.h index 740375a43e..79d67266a8 100644 --- a/src/nspawn/nspawn-setuid.h +++ b/src/nspawn/nspawn-setuid.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int change_uid_gid_raw(uid_t uid, gid_t gid, const gid_t *supplementary_gids, size_t n_supplementary_gids, bool chown_stdio); int change_uid_gid(const char *user, bool chown_stdio, char **ret_home); diff --git a/src/nspawn/nspawn-stub-pid1.h b/src/nspawn/nspawn-stub-pid1.h index c7889583f4..620065b36c 100644 --- a/src/nspawn/nspawn-stub-pid1.h +++ b/src/nspawn/nspawn-stub-pid1.h @@ -3,6 +3,6 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" int stub_pid1(sd_id128_t uuid); diff --git a/src/nspawn/nspawn.h b/src/nspawn/nspawn.h index 8f1e812087..943b22db2d 100644 --- a/src/nspawn/nspawn.h +++ b/src/nspawn/nspawn.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int userns_lchown(const char *p, uid_t uid, gid_t gid); int userns_mkdir(const char *root, const char *path, mode_t mode, uid_t uid, gid_t gid); diff --git a/src/nsresourced/nsresourced-manager.h b/src/nsresourced/nsresourced-manager.h index ce8d8c690a..9acb619e9f 100644 --- a/src/nsresourced/nsresourced-manager.h +++ b/src/nsresourced/nsresourced-manager.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "ratelimit.h" #define NSRESOURCE_WORKERS_MIN 5 diff --git a/src/nsresourced/userns-registry.h b/src/nsresourced/userns-registry.h index c1e7c9f1f5..9d6b398b65 100644 --- a/src/nsresourced/userns-registry.h +++ b/src/nsresourced/userns-registry.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define USER_NAMESPACE_CGROUPS_DELEGATE_MAX 16U #define USER_NAMESPACE_NETIFS_DELEGATE_MAX 16U diff --git a/src/nsresourced/userns-restrict.h b/src/nsresourced/userns-restrict.h index a1a29ba8f6..0246b4600e 100644 --- a/src/nsresourced/userns-restrict.h +++ b/src/nsresourced/userns-restrict.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_VMLINUX_H #include "bpf/userns-restrict/userns-restrict-skel.h" diff --git a/src/nss-systemd/nss-systemd.h b/src/nss-systemd/nss-systemd.h index 054bd40305..e8c6c59615 100644 --- a/src/nss-systemd/nss-systemd.h +++ b/src/nss-systemd/nss-systemd.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int _nss_systemd_block(bool b); bool _nss_systemd_is_blocked(void); diff --git a/src/nss-systemd/userdb-glue.h b/src/nss-systemd/userdb-glue.h index 840329312d..a7205518e2 100644 --- a/src/nss-systemd/userdb-glue.h +++ b/src/nss-systemd/userdb-glue.h @@ -5,7 +5,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "userdb.h" UserDBFlags nss_glue_userdb_flags(void); diff --git a/src/oom/oomd-manager-bus.h b/src/oom/oomd-manager-bus.h index 70c473f15b..5147c5beff 100644 --- a/src/oom/oomd-manager-bus.h +++ b/src/oom/oomd-manager-bus.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" extern const BusObjectImplementation manager_object; diff --git a/src/oom/oomd-manager.h b/src/oom/oomd-manager.h index 311250c6f3..016460a719 100644 --- a/src/oom/oomd-manager.h +++ b/src/oom/oomd-manager.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #include "oomd-util.h" /* Polling interval for monitoring stats */ diff --git a/src/oom/oomd-util.h b/src/oom/oomd-util.h index cfb310ff32..a94d5c0d05 100644 --- a/src/oom/oomd-util.h +++ b/src/oom/oomd-util.h @@ -2,7 +2,7 @@ #pragma once #include "cgroup-util.h" -#include "forward.h" +#include "shared-forward.h" #include "psi-util.h" #define DUMP_ON_KILL_COUNT 10u diff --git a/src/pcrlock/pcrlock-firmware.h b/src/pcrlock/pcrlock-firmware.h index f87775e4bb..7ec045793b 100644 --- a/src/pcrlock/pcrlock-firmware.h +++ b/src/pcrlock/pcrlock-firmware.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "tpm2-event-log.h" int validate_firmware_event( diff --git a/src/portable/portable.h b/src/portable/portable.h index e83ff9a787..e001ba7795 100644 --- a/src/portable/portable.h +++ b/src/portable/portable.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "runtime-scope.h" #include "string-util.h" diff --git a/src/portable/portabled-forward.h b/src/portable/portabled-forward.h index 047a58e9a7..7dc8fee923 100644 --- a/src/portable/portabled-forward.h +++ b/src/portable/portabled-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef struct Manager Manager; typedef struct Operation Operation; diff --git a/src/resolve/dns-type.h b/src/resolve/dns-type.h index 683c7ee6ef..7c1dbf65d9 100644 --- a/src/resolve/dns-type.h +++ b/src/resolve/dns-type.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* DNS record types, taken from * http://www.iana.org/assignments/dns-parameters/dns-parameters.xhtml. diff --git a/src/resolve/resolvectl.h b/src/resolve/resolvectl.h index c6ec008169..6752060cdf 100644 --- a/src/resolve/resolvectl.h +++ b/src/resolve/resolvectl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum ExecutionMode { MODE_RESOLVE_HOST, diff --git a/src/resolve/resolved-dns-scope.h b/src/resolve/resolved-dns-scope.h index f5f78ab65c..c1a5365090 100644 --- a/src/resolve/resolved-dns-scope.h +++ b/src/resolve/resolved-dns-scope.h @@ -2,7 +2,7 @@ #pragma once #include "dns-def.h" -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "ratelimit.h" #include "resolve-util.h" diff --git a/src/resolve/resolved-dns-server.h b/src/resolve/resolved-dns-server.h index efc8de2f0a..0eaac00332 100644 --- a/src/resolve/resolved-dns-server.h +++ b/src/resolve/resolved-dns-server.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" #include "list.h" #include "resolved-conf.h" diff --git a/src/resolve/resolved-dns-stream.h b/src/resolve/resolved-dns-stream.h index 91f65e446a..6c932f5e84 100644 --- a/src/resolve/resolved-dns-stream.h +++ b/src/resolve/resolved-dns-stream.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "resolved-dns-packet.h" #include "resolved-dnstls.h" diff --git a/src/resolve/resolved-dnssd-bus.h b/src/resolve/resolved-dnssd-bus.h index 04fd506cf4..882e5a81b3 100644 --- a/src/resolve/resolved-dnssd-bus.h +++ b/src/resolve/resolved-dnssd-bus.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" extern const BusObjectImplementation dnssd_object; diff --git a/src/resolve/resolved-forward.h b/src/resolve/resolved-forward.h index e5be2fe939..9a79734847 100644 --- a/src/resolve/resolved-forward.h +++ b/src/resolve/resolved-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum DnsAnswerFlags DnsAnswerFlags; typedef enum DnsCacheMode DnsCacheMode; diff --git a/src/resolve/resolved-manager.h b/src/resolve/resolved-manager.h index 67ef4a86fa..47a25abd44 100644 --- a/src/resolve/resolved-manager.h +++ b/src/resolve/resolved-manager.h @@ -4,7 +4,7 @@ #include #include "common-signal.h" -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "resolve-util.h" #include "resolved-dns-browse-services.h" diff --git a/src/sbsign/authenticode.h b/src/sbsign/authenticode.h index c1df94c2f9..95d5499a8e 100644 --- a/src/sbsign/authenticode.h +++ b/src/sbsign/authenticode.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #define SPC_INDIRECT_DATA_OBJID "1.3.6.1.4.1.311.2.1.4" #define SPC_PE_IMAGE_DATA_OBJID "1.3.6.1.4.1.311.2.1.15" diff --git a/src/shared/acl-util.h b/src/shared/acl-util.h index 54eba92f38..a15790b94d 100644 --- a/src/shared/acl-util.h +++ b/src/shared/acl-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int fd_acl_make_read_only_fallback(int fd); int fd_acl_make_writable_fallback(int fd); diff --git a/src/shared/acpi-fpdt.h b/src/shared/acpi-fpdt.h index 167813a462..c59ef4dfbf 100644 --- a/src/shared/acpi-fpdt.h +++ b/src/shared/acpi-fpdt.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int acpi_get_boot_usec(usec_t *ret_loader_start, usec_t *ret_loader_exit); diff --git a/src/shared/apparmor-util.h b/src/shared/apparmor-util.h index 3d9df43c71..52f8f7834c 100644 --- a/src/shared/apparmor-util.h +++ b/src/shared/apparmor-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_APPARMOR # include diff --git a/src/shared/ask-password-agent.h b/src/shared/ask-password-agent.h index 610f910905..3b2e14bc65 100644 --- a/src/shared/ask-password-agent.h +++ b/src/shared/ask-password-agent.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int ask_password_agent_open(void); void ask_password_agent_close(void); diff --git a/src/shared/ask-password-api.h b/src/shared/ask-password-api.h index a470caf5da..5ea37f04d6 100644 --- a/src/shared/ask-password-api.h +++ b/src/shared/ask-password-api.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum AskPasswordFlags { ASK_PASSWORD_ACCEPT_CACHED = 1 << 0, /* read from kernel keyring */ diff --git a/src/shared/async.h b/src/shared/async.h index d887a4ca55..2088876c83 100644 --- a/src/shared/async.h +++ b/src/shared/async.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* These functions implement various potentially slow operations that are executed asynchronously. They are * carefully written to not use pthreads, but use fork() or clone() (without CLONE_VM) so that the child does diff --git a/src/shared/barrier.h b/src/shared/barrier.h index 0be490bd54..9d100e5504 100644 --- a/src/shared/barrier.h +++ b/src/shared/barrier.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* See source file for an API description. */ diff --git a/src/shared/base-filesystem.h b/src/shared/base-filesystem.h index 5c5aa573ef..9ea1062213 100644 --- a/src/shared/base-filesystem.h +++ b/src/shared/base-filesystem.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int base_filesystem_create_fd(int fd, const char *root, uid_t uid, gid_t gid); int base_filesystem_create(const char *root, uid_t uid, gid_t gid); diff --git a/src/shared/battery-util.h b/src/shared/battery-util.h index 3c39fc76c9..35e22d96ec 100644 --- a/src/shared/battery-util.h +++ b/src/shared/battery-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int on_ac_power(void); diff --git a/src/shared/bitmap.h b/src/shared/bitmap.h index a12451ca0e..a5199f746b 100644 --- a/src/shared/bitmap.h +++ b/src/shared/bitmap.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "iterator.h" typedef struct Bitmap { diff --git a/src/shared/blkid-util.h b/src/shared/blkid-util.h index e1202590dc..09502eadc4 100644 --- a/src/shared/blkid-util.h +++ b/src/shared/blkid-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_BLKID diff --git a/src/shared/blockdev-list.h b/src/shared/blockdev-list.h index d03daffc3d..f1f1bc9949 100644 --- a/src/shared/blockdev-list.h +++ b/src/shared/blockdev-list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum BlockDevListFlags { BLOCKDEV_LIST_SHOW_SYMLINKS = 1 << 0, /* Pick up symlinks to block devices too */ diff --git a/src/shared/blockdev-util.h b/src/shared/blockdev-util.h index 8bb890aefb..87b40054da 100644 --- a/src/shared/blockdev-util.h +++ b/src/shared/blockdev-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "stdio-util.h" #define SYS_BLOCK_PATH_MAX(suffix) \ diff --git a/src/shared/bond-util.h b/src/shared/bond-util.h index 11fefedc27..0830c31d84 100644 --- a/src/shared/bond-util.h +++ b/src/shared/bond-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* * Maximum number of targets supported by the kernel for a single diff --git a/src/shared/boot-entry.h b/src/shared/boot-entry.h index 71260d4ff7..41f8a09faf 100644 --- a/src/shared/boot-entry.h +++ b/src/shared/boot-entry.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef enum BootEntryTokenType { BOOT_ENTRY_TOKEN_MACHINE_ID, diff --git a/src/shared/boot-timestamps.h b/src/shared/boot-timestamps.h index 9ccbeb2c04..84cb560682 100644 --- a/src/shared/boot-timestamps.h +++ b/src/shared/boot-timestamps.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int boot_timestamps(const dual_timestamp *n, dual_timestamp *firmware, dual_timestamp *loader); diff --git a/src/shared/bootspec.h b/src/shared/bootspec.h index b8521f61f2..f1bb79f08f 100644 --- a/src/shared/bootspec.h +++ b/src/shared/bootspec.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum BootEntryType { BOOT_ENTRY_TYPE1, /* Boot Loader Specification Type #1 entries: *.conf files */ diff --git a/src/shared/bpf-dlopen.h b/src/shared/bpf-dlopen.h index 3a985738ec..ecae890035 100644 --- a/src/shared/bpf-dlopen.h +++ b/src/shared/bpf-dlopen.h @@ -10,7 +10,7 @@ #include "bpf-compat.h" /* IWYU pragma: export */ #include "dlfcn-util.h" -#include "forward.h" +#include "shared-forward.h" extern DLSYM_PROTOTYPE(bpf_link__destroy); extern DLSYM_PROTOTYPE(bpf_link__fd); diff --git a/src/shared/bpf-link.h b/src/shared/bpf-link.h index acd64f88eb..efc3cb9850 100644 --- a/src/shared/bpf-link.h +++ b/src/shared/bpf-link.h @@ -5,7 +5,7 @@ #include -#include "forward.h" +#include "shared-forward.h" bool bpf_can_link_program(struct bpf_program *prog); diff --git a/src/shared/bpf-program.h b/src/shared/bpf-program.h index 3b3aae4a75..4156bc8760 100644 --- a/src/shared/bpf-program.h +++ b/src/shared/bpf-program.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* This encapsulates three different concepts: the loaded BPF program, the BPF code, and the attachment to a * cgroup. Typically our BPF programs go through all three stages: we build the code, we load it, and finally diff --git a/src/shared/bridge-util.h b/src/shared/bridge-util.h index c23a3acf06..245657a226 100644 --- a/src/shared/bridge-util.h +++ b/src/shared/bridge-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef enum BridgeState { NETDEV_BRIDGE_STATE_DISABLED = BR_STATE_DISABLED, diff --git a/src/shared/btrfs-util.h b/src/shared/btrfs-util.h index d002618bd8..0d90ea2739 100644 --- a/src/shared/btrfs-util.h +++ b/src/shared/btrfs-util.h @@ -4,7 +4,7 @@ #include "sd-id128.h" #include "btrfs.h" /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" typedef struct BtrfsSubvolInfo { uint64_t subvol_id; diff --git a/src/shared/bus-get-properties.h b/src/shared/bus-get-properties.h index c6f0b73bd4..b3d77867a7 100644 --- a/src/shared/bus-get-properties.h +++ b/src/shared/bus-get-properties.h @@ -3,7 +3,7 @@ #include "sd-bus.h" -#include "forward.h" +#include "shared-forward.h" int bus_property_get_bool(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *reply, void *userdata, sd_bus_error *reterr_error); int bus_property_set_bool(sd_bus *bus, const char *path, const char *interface, const char *property, sd_bus_message *value, void *userdata, sd_bus_error *reterr_error); diff --git a/src/shared/bus-locator.h b/src/shared/bus-locator.h index 9b0ac39775..adb43f8a5e 100644 --- a/src/shared/bus-locator.h +++ b/src/shared/bus-locator.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct BusLocator { const char *destination; diff --git a/src/shared/bus-log-control-api.h b/src/shared/bus-log-control-api.h index 33453216ea..35f9251d31 100644 --- a/src/shared/bus-log-control-api.h +++ b/src/shared/bus-log-control-api.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" extern const BusObjectImplementation log_control_object; diff --git a/src/shared/bus-map-properties.h b/src/shared/bus-map-properties.h index e019266ac2..834374ce97 100644 --- a/src/shared/bus-map-properties.h +++ b/src/shared/bus-map-properties.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef int (*bus_property_set_t)(sd_bus *bus, const char *member, sd_bus_message *m, sd_bus_error *reterr_error, void *userdata); diff --git a/src/shared/bus-message-util.h b/src/shared/bus-message-util.h index 4e8fb4d4e5..1e6d25e8b2 100644 --- a/src/shared/bus-message-util.h +++ b/src/shared/bus-message-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int bus_message_read_id128(sd_bus_message *m, sd_id128_t *ret); diff --git a/src/shared/bus-object.h b/src/shared/bus-object.h index 85d8a4d9d9..a3dbae80ae 100644 --- a/src/shared/bus-object.h +++ b/src/shared/bus-object.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct BusObjectVtablePair { const sd_bus_vtable *vtable; diff --git a/src/shared/bus-polkit.h b/src/shared/bus-polkit.h index 86e499e03d..9ce8de4f02 100644 --- a/src/shared/bus-polkit.h +++ b/src/shared/bus-polkit.h @@ -4,7 +4,7 @@ #include "sd-json.h" #include "sd-varlink.h" -#include "forward.h" +#include "shared-forward.h" typedef enum PolkitFlags { POLKIT_ALLOW_INTERACTIVE = 1 << 0, /* Allow interactive auth (typically not required, because can be derived from bus message/link automatically) */ diff --git a/src/shared/bus-print-properties.h b/src/shared/bus-print-properties.h index 16433de9bc..507188771e 100644 --- a/src/shared/bus-print-properties.h +++ b/src/shared/bus-print-properties.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum BusPrintPropertyFlags { BUS_PRINT_PROPERTY_ONLY_VALUE = 1 << 0, /* e.g. systemctl --value */ diff --git a/src/shared/bus-unit-procs.h b/src/shared/bus-unit-procs.h index f2665ad79b..22406046f7 100644 --- a/src/shared/bus-unit-procs.h +++ b/src/shared/bus-unit-procs.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int unit_show_processes(sd_bus *bus, const char *unit, const char *cgroup_path, const char *prefix, unsigned n_columns, OutputFlags flags, sd_bus_error *reterr_error); diff --git a/src/shared/bus-unit-util.h b/src/shared/bus-unit-util.h index c07a704414..88095be27e 100644 --- a/src/shared/bus-unit-util.h +++ b/src/shared/bus-unit-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum ExecDirectoryFlags { EXEC_DIRECTORY_READ_ONLY = 1 << 0, /* Public API via DBUS, do not change */ diff --git a/src/shared/bus-util.h b/src/shared/bus-util.h index 1b9d9e447b..b14f93d1bb 100644 --- a/src/shared/bus-util.h +++ b/src/shared/bus-util.h @@ -4,7 +4,7 @@ #include "sd-bus.h" /* IWYU pragma: export */ #include "log.h" -#include "forward.h" +#include "shared-forward.h" typedef enum BusTransport { BUS_TRANSPORT_LOCAL, diff --git a/src/shared/bus-wait-for-jobs.h b/src/shared/bus-wait-for-jobs.h index bce4f25ac2..125a2e9ea8 100644 --- a/src/shared/bus-wait-for-jobs.h +++ b/src/shared/bus-wait-for-jobs.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct BusWaitForJobs BusWaitForJobs; diff --git a/src/shared/bus-wait-for-units.h b/src/shared/bus-wait-for-units.h index eed7fd1f4b..b563249897 100644 --- a/src/shared/bus-wait-for-units.h +++ b/src/shared/bus-wait-for-units.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct BusWaitForUnits BusWaitForUnits; diff --git a/src/shared/calendarspec.h b/src/shared/calendarspec.h index 2289d9cfed..ce76a7c1c6 100644 --- a/src/shared/calendarspec.h +++ b/src/shared/calendarspec.h @@ -4,7 +4,7 @@ /* A structure for specifying (possibly repetitive) points in calendar * time, a la cron */ -#include "forward.h" +#include "shared-forward.h" typedef struct CalendarComponent { int start; diff --git a/src/shared/cgroup-setup.h b/src/shared/cgroup-setup.h index 4cc5c9f4cc..33802c3624 100644 --- a/src/shared/cgroup-setup.h +++ b/src/shared/cgroup-setup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int cg_weight_parse(const char *s, uint64_t *ret); int cg_cpu_weight_parse(const char *s, uint64_t *ret); diff --git a/src/shared/cgroup-show.h b/src/shared/cgroup-show.h index 9dd81d5933..ecff0298ae 100644 --- a/src/shared/cgroup-show.h +++ b/src/shared/cgroup-show.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int show_cgroup_by_path(const char *path, const char *prefix, size_t n_columns, OutputFlags flags); int show_cgroup(const char *controller, const char *path, const char *prefix, size_t n_columns, OutputFlags flags); diff --git a/src/shared/chown-recursive.h b/src/shared/chown-recursive.h index 8bf8a80d6b..55605c4a76 100644 --- a/src/shared/chown-recursive.h +++ b/src/shared/chown-recursive.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int path_chown_recursive(const char *path, uid_t uid, gid_t gid, mode_t mask, int flags); diff --git a/src/shared/clean-ipc.h b/src/shared/clean-ipc.h index a1f8b9ec63..43f9ec6873 100644 --- a/src/shared/clean-ipc.h +++ b/src/shared/clean-ipc.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int clean_ipc_internal(uid_t uid, gid_t gid, bool rm); diff --git a/src/shared/color-util.h b/src/shared/color-util.h index 1816b7971c..ff1de1f90c 100644 --- a/src/shared/color-util.h +++ b/src/shared/color-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" void rgb_to_hsv(double r, double g, double b, double *ret_h, double *ret_s, double *ret_v); diff --git a/src/shared/common-signal.h b/src/shared/common-signal.h index 07bc4c5f00..fabe94370e 100644 --- a/src/shared/common-signal.h +++ b/src/shared/common-signal.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* All our long-running services should implement a SIGRTMIN+18 handler that can be used to trigger certain * actions that affect service runtime. The specific action is indicated via the "value integer" you can pass diff --git a/src/shared/compare-operator.h b/src/shared/compare-operator.h index aa19835fd0..6f934a4a88 100644 --- a/src/shared/compare-operator.h +++ b/src/shared/compare-operator.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define COMPARE_OPERATOR_CHARS "!<=>" #define COMPARE_OPERATOR_WITH_FNMATCH_CHARS COMPARE_OPERATOR_CHARS "$" diff --git a/src/shared/condition.h b/src/shared/condition.h index 90d896c85c..a258db6a8e 100644 --- a/src/shared/condition.h +++ b/src/shared/condition.h @@ -2,7 +2,7 @@ #pragma once #include "list.h" -#include "forward.h" +#include "shared-forward.h" typedef enum ConditionType { CONDITION_ARCHITECTURE, diff --git a/src/shared/conf-parser.h b/src/shared/conf-parser.h index 2f1b5ffecc..ecc432ec41 100644 --- a/src/shared/conf-parser.h +++ b/src/shared/conf-parser.h @@ -5,7 +5,7 @@ #include "alloc-util.h" #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #include "log.h" /* An abstract parser for simple, line based, shallow configuration files consisting of variable assignments only. */ diff --git a/src/shared/copy.h b/src/shared/copy.h index a818510e1c..d4b131d102 100644 --- a/src/shared/copy.h +++ b/src/shared/copy.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum CopyFlags { COPY_REFLINK = 1 << 0, /* Try to reflink */ diff --git a/src/shared/coredump-util.h b/src/shared/coredump-util.h index a39c9286eb..77010d2779 100644 --- a/src/shared/coredump-util.h +++ b/src/shared/coredump-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum CoredumpFilter { COREDUMP_FILTER_PRIVATE_ANONYMOUS = 0, diff --git a/src/shared/cpu-set-util.h b/src/shared/cpu-set-util.h index 29582d5409..a74e264e12 100644 --- a/src/shared/cpu-set-util.h +++ b/src/shared/cpu-set-util.h @@ -4,7 +4,7 @@ #include #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" /* This wraps the libc interface with a variable to keep the allocated size. */ typedef struct CPUSet { diff --git a/src/shared/creds-util.h b/src/shared/creds-util.h index 8991d0678c..d23afa6c13 100644 --- a/src/shared/creds-util.h +++ b/src/shared/creds-util.h @@ -4,7 +4,7 @@ #include "sd-id128.h" #include "fd-util.h" -#include "forward.h" +#include "shared-forward.h" #define CREDENTIAL_NAME_MAX FDNAME_MAX diff --git a/src/shared/cryptsetup-fido2.h b/src/shared/cryptsetup-fido2.h index 63d46cd97f..75203ae8af 100644 --- a/src/shared/cryptsetup-fido2.h +++ b/src/shared/cryptsetup-fido2.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int acquire_fido2_key( const char *volume_name, diff --git a/src/shared/cryptsetup-tpm2.h b/src/shared/cryptsetup-tpm2.h index f66a516887..a3d456af4f 100644 --- a/src/shared/cryptsetup-tpm2.h +++ b/src/shared/cryptsetup-tpm2.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int acquire_tpm2_key( const char *volume_name, diff --git a/src/shared/cryptsetup-util.h b/src/shared/cryptsetup-util.h index df897c208f..3c043292e6 100644 --- a/src/shared/cryptsetup-util.h +++ b/src/shared/cryptsetup-util.h @@ -2,7 +2,7 @@ #pragma once #include "dlfcn-util.h" -#include "forward.h" +#include "shared-forward.h" #if HAVE_LIBCRYPTSETUP #include /* IWYU pragma: export */ diff --git a/src/shared/daemon-util.h b/src/shared/daemon-util.h index 90d4a1689b..708a32985c 100644 --- a/src/shared/daemon-util.h +++ b/src/shared/daemon-util.h @@ -3,7 +3,7 @@ #include "sd-daemon.h" /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" #define NOTIFY_READY_MESSAGE "READY=1\n" "STATUS=Processing requests..." #define NOTIFY_STOPPING_MESSAGE "STOPPING=1\n" "STATUS=Shutting down..." diff --git a/src/shared/data-fd-util.h b/src/shared/data-fd-util.h index 605ba6b24e..11027d8ce8 100644 --- a/src/shared/data-fd-util.h +++ b/src/shared/data-fd-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int copy_data_fd(int fd); int memfd_clone_fd(int fd, const char *name, int mode); diff --git a/src/shared/dev-setup.h b/src/shared/dev-setup.h index 8844d751ac..573c7a5c0b 100644 --- a/src/shared/dev-setup.h +++ b/src/shared/dev-setup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int dev_setup(const char *prefix, uid_t uid, gid_t gid); diff --git a/src/shared/device-nodes.h b/src/shared/device-nodes.h index f57378c0f6..5b2e0432c1 100644 --- a/src/shared/device-nodes.h +++ b/src/shared/device-nodes.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int encode_devnode_name(const char *str, char *str_enc, size_t len); int allow_listed_char_for_devnode(char c, const char *additional); diff --git a/src/shared/discover-image.h b/src/shared/discover-image.h index 55476259d7..7ba44bfb79 100644 --- a/src/shared/discover-image.h +++ b/src/shared/discover-image.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" #include "os-util.h" typedef enum ImageType { diff --git a/src/shared/dissect-image.h b/src/shared/dissect-image.h index a050f10701..26ea449514 100644 --- a/src/shared/dissect-image.h +++ b/src/shared/dissect-image.h @@ -4,7 +4,7 @@ #include "sd-id128.h" #include "architecture.h" -#include "forward.h" +#include "shared-forward.h" #include "gpt.h" #include "list.h" diff --git a/src/shared/dns-domain.h b/src/shared/dns-domain.h index 6b8070d0ce..c7730f70aa 100644 --- a/src/shared/dns-domain.h +++ b/src/shared/dns-domain.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum DNSLabelFlags { DNS_LABEL_LDH = 1 << 0, /* Follow the "LDH" rule — only letters, digits, and internal hyphens. */ diff --git a/src/shared/dropin.h b/src/shared/dropin.h index ffd4757177..c40a700e34 100644 --- a/src/shared/dropin.h +++ b/src/shared/dropin.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int drop_in_file( const char *dir, diff --git a/src/shared/edit-util.h b/src/shared/edit-util.h index 5bcdaeba16..427533f67c 100644 --- a/src/shared/edit-util.h +++ b/src/shared/edit-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define DROPIN_MARKER_START "### Anything between here and the comment below will become the contents of the drop-in file" #define DROPIN_MARKER_END "### Edits below this comment will be discarded" diff --git a/src/shared/efi-api.h b/src/shared/efi-api.h index 206e6136de..6fb3efb88a 100644 --- a/src/shared/efi-api.h +++ b/src/shared/efi-api.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" /* Various calls for interfacing with EFI variables from the official UEFI specs. */ diff --git a/src/shared/efi-loader.h b/src/shared/efi-loader.h index 346f3b5d8b..5b614cd0a7 100644 --- a/src/shared/efi-loader.h +++ b/src/shared/efi-loader.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Various calls that interface with EFI variables implementing https://systemd.io/BOOT_LOADER_INTERFACE */ diff --git a/src/shared/elf-util.h b/src/shared/elf-util.h index 41859cd169..19c40c2107 100644 --- a/src/shared/elf-util.h +++ b/src/shared/elf-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int dlopen_dw(void); int dlopen_elf(void); diff --git a/src/shared/ethtool-util.h b/src/shared/ethtool-util.h index d7bb2d0a2d..84fbebdf1b 100644 --- a/src/shared/ethtool-util.h +++ b/src/shared/ethtool-util.h @@ -4,7 +4,7 @@ #include #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #define N_ADVERTISE 4 diff --git a/src/shared/exec-util.h b/src/shared/exec-util.h index d6af5de510..bb825e9969 100644 --- a/src/shared/exec-util.h +++ b/src/shared/exec-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef int (*gather_stdout_callback_t) (int fd, void *arg); diff --git a/src/shared/exit-status.h b/src/shared/exit-status.h index e9a122e31d..27b8d4664a 100644 --- a/src/shared/exit-status.h +++ b/src/shared/exit-status.h @@ -2,7 +2,7 @@ #pragma once #include "bitmap.h" -#include "forward.h" +#include "shared-forward.h" /* This defines pretty names for the LSB 'start' verb exit codes. Note that they shouldn't be confused with * the LSB 'status' verb exit codes which are defined very differently. For details see: diff --git a/src/shared/extension-util.h b/src/shared/extension-util.h index 08bdd7f33e..2cfe974ce0 100644 --- a/src/shared/extension-util.h +++ b/src/shared/extension-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Given an image name (for logging purposes), a set of os-release values from the host and a key-value pair * vector of extension-release variables, check that the distro and (system extension level or distro diff --git a/src/shared/factory-reset.h b/src/shared/factory-reset.h index 06903fca18..262c951502 100644 --- a/src/shared/factory-reset.h +++ b/src/shared/factory-reset.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum FactoryResetMode { FACTORY_RESET_UNSUPPORTED, /* feature not available on this OS */ diff --git a/src/shared/fdisk-util.h b/src/shared/fdisk-util.h index eb4b3231a0..98a2ed9948 100644 --- a/src/shared/fdisk-util.h +++ b/src/shared/fdisk-util.h @@ -5,7 +5,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" DEFINE_TRIVIAL_CLEANUP_FUNC_FULL(struct fdisk_context*, fdisk_unref_context, NULL); DEFINE_TRIVIAL_CLEANUP_FUNC_FULL(struct fdisk_partition*, fdisk_unref_partition, NULL); diff --git a/src/shared/fdset.h b/src/shared/fdset.h index 96a17c7835..a0d4e6d163 100644 --- a/src/shared/fdset.h +++ b/src/shared/fdset.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "iterator.h" FDSet* fdset_new(void); diff --git a/src/shared/fido2-util.h b/src/shared/fido2-util.h index 8eccf2cc0d..25b3a0732d 100644 --- a/src/shared/fido2-util.h +++ b/src/shared/fido2-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int fido2_generate_salt(struct iovec *ret_salt); int fido2_read_salt_file(const char *filename, uint64_t offset, const char *client, const char *node, struct iovec *ret_salt); diff --git a/src/shared/find-esp.h b/src/shared/find-esp.h index 1dd0f48600..ac62e6c51e 100644 --- a/src/shared/find-esp.h +++ b/src/shared/find-esp.h @@ -2,7 +2,7 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" int find_esp_and_warn_at(int rfd, const char *path, int unprivileged_mode, char **ret_path, uint32_t *ret_part, uint64_t *ret_pstart, uint64_t *ret_psize, sd_id128_t *ret_uuid, dev_t *ret_devid); int find_esp_and_warn(const char *root, const char *path, int unprivileged_mode, char **ret_path, uint32_t *ret_part, uint64_t *ret_pstart, uint64_t *ret_psize, sd_id128_t *ret_uuid, dev_t *ret_devid); diff --git a/src/shared/firewall-util.h b/src/shared/firewall-util.h index 595da38ef6..ee28aead8e 100644 --- a/src/shared/firewall-util.h +++ b/src/shared/firewall-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" int fw_nftables_add_masquerade( sd_netlink *nfnl, diff --git a/src/shared/fork-notify.h b/src/shared/fork-notify.h index a14d6fd02f..dd6ea9f15f 100644 --- a/src/shared/fork-notify.h +++ b/src/shared/fork-notify.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int fork_notify(char * const *cmdline, PidRef *ret_pidref); diff --git a/src/shared/format-table.h b/src/shared/format-table.h index 3365a8feb7..2222373eb3 100644 --- a/src/shared/format-table.h +++ b/src/shared/format-table.h @@ -3,7 +3,7 @@ #include "sd-json.h" -#include "forward.h" +#include "shared-forward.h" #include "log.h" #include "pager.h" diff --git a/src/shared/fstab-util.h b/src/shared/fstab-util.h index 59d909d44f..e3a5f66332 100644 --- a/src/shared/fstab-util.h +++ b/src/shared/fstab-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool fstab_enabled_full(int enabled); static inline bool fstab_enabled(void) { diff --git a/src/shared/generator.h b/src/shared/generator.h index 57c854e790..81ab190c1f 100644 --- a/src/shared/generator.h +++ b/src/shared/generator.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "main-func.h" int generator_open_unit_file_full(const char *dest, const char *source, const char *name, FILE **ret_file, char **ret_final_path, char **ret_temp_path); diff --git a/src/shared/geneve-util.h b/src/shared/geneve-util.h index b40c4ced0e..b5a4930443 100644 --- a/src/shared/geneve-util.h +++ b/src/shared/geneve-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef enum GeneveDF { NETDEV_GENEVE_DF_UNSET = GENEVE_DF_UNSET, diff --git a/src/shared/gpt.h b/src/shared/gpt.h index 0103ac2f4a..e8a3c5eece 100644 --- a/src/shared/gpt.h +++ b/src/shared/gpt.h @@ -5,7 +5,7 @@ #include "sd-id128.h" #include "architecture.h" -#include "forward.h" +#include "shared-forward.h" #include "sparse-endian.h" /* maximum length of gpt label */ diff --git a/src/shared/group-record.h b/src/shared/group-record.h index 765fc613ba..730938c3d9 100644 --- a/src/shared/group-record.h +++ b/src/shared/group-record.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "user-record.h" typedef struct GroupRecord { diff --git a/src/shared/hibernate-util.h b/src/shared/hibernate-util.h index 719e2c0554..0fe2b2e11b 100644 --- a/src/shared/hibernate-util.h +++ b/src/shared/hibernate-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* represents values for /sys/power/resume & /sys/power/resume_offset and the corresponding path */ typedef struct HibernationDevice { diff --git a/src/shared/hostname-setup.h b/src/shared/hostname-setup.h index d3cb59b3fc..9af57fad56 100644 --- a/src/shared/hostname-setup.h +++ b/src/shared/hostname-setup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum HostnameSource { HOSTNAME_STATIC, /* from /etc/hostname */ diff --git a/src/shared/hwdb-util.h b/src/shared/hwdb-util.h index 6e41b8b588..c1f14c446a 100644 --- a/src/shared/hwdb-util.h +++ b/src/shared/hwdb-util.h @@ -3,7 +3,7 @@ #include "sd-hwdb.h" /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" bool hwdb_should_reload(sd_hwdb *hwdb); int hwdb_update(const char *root, const char *hwdb_bin_dir, bool strict, bool compat); diff --git a/src/shared/id128-print.h b/src/shared/id128-print.h index 0048e95729..db3c176a34 100644 --- a/src/shared/id128-print.h +++ b/src/shared/id128-print.h @@ -4,7 +4,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef enum Id128PrettyPrintMode { ID128_PRINT_ID128, diff --git a/src/shared/idn-util.h b/src/shared/idn-util.h index 734ec9d999..27213fb6c2 100644 --- a/src/shared/idn-util.h +++ b/src/shared/idn-util.h @@ -8,7 +8,7 @@ # include #endif -#include "forward.h" +#include "shared-forward.h" #if HAVE_LIBIDN2 || HAVE_LIBIDN #include "dlfcn-util.h" diff --git a/src/shared/ima-util.h b/src/shared/ima-util.h index fb864f6063..6007e76891 100644 --- a/src/shared/ima-util.h +++ b/src/shared/ima-util.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool use_ima(void); diff --git a/src/shared/image-policy.h b/src/shared/image-policy.h index 6f5c1d23d6..6fdd8abe32 100644 --- a/src/shared/image-policy.h +++ b/src/shared/image-policy.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #include "gpt.h" typedef enum PartitionPolicyFlags { diff --git a/src/shared/import-util.h b/src/shared/import-util.h index 8779293cdf..9621cd884d 100644 --- a/src/shared/import-util.h +++ b/src/shared/import-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum ImportType { IMPORT_RAW, diff --git a/src/shared/in-addr-prefix-util.h b/src/shared/in-addr-prefix-util.h index b18609a121..6bb46b6815 100644 --- a/src/shared/in-addr-prefix-util.h +++ b/src/shared/in-addr-prefix-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" struct in_addr_prefix { diff --git a/src/shared/install-file.h b/src/shared/install-file.h index e72dac3e97..cb94e32cae 100644 --- a/src/shared/install-file.h +++ b/src/shared/install-file.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum InstallFileFlags { INSTALL_REPLACE = 1 << 0, /* Replace an existing inode */ diff --git a/src/shared/install-printf.h b/src/shared/install-printf.h index f88449ffe1..0d05badc47 100644 --- a/src/shared/install-printf.h +++ b/src/shared/install-printf.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int install_name_printf( RuntimeScope scope, diff --git a/src/shared/install.h b/src/shared/install.h index 39bded38b8..1d0b93d05c 100644 --- a/src/shared/install.h +++ b/src/shared/install.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "runtime-scope.h" #include "unit-file.h" diff --git a/src/shared/ioprio-util.h b/src/shared/ioprio-util.h index 468f178cd0..04d44c7700 100644 --- a/src/shared/ioprio-util.h +++ b/src/shared/ioprio-util.h @@ -3,7 +3,7 @@ #include /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" static inline int ioprio_prio_class(int value) { return IOPRIO_PRIO_CLASS(value); diff --git a/src/shared/ip-protocol-list.h b/src/shared/ip-protocol-list.h index cb8599787b..6ea91e4c27 100644 --- a/src/shared/ip-protocol-list.h +++ b/src/shared/ip-protocol-list.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" const char* ip_protocol_to_name(int id); int ip_protocol_from_name(const char *name); diff --git a/src/shared/ipvlan-util.h b/src/shared/ipvlan-util.h index c96201742b..fdfcb759ec 100644 --- a/src/shared/ipvlan-util.h +++ b/src/shared/ipvlan-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef enum IPVlanMode { NETDEV_IPVLAN_MODE_L2 = IPVLAN_MODE_L2, diff --git a/src/shared/journal-file-util.h b/src/shared/journal-file-util.h index 978ff1c160..d3ffe4e7a6 100644 --- a/src/shared/journal-file-util.h +++ b/src/shared/journal-file-util.h @@ -2,7 +2,7 @@ #pragma once #include "journal-file.h" /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" int journal_file_set_offline(JournalFile *f, bool wait); bool journal_file_is_offlining(JournalFile *f); diff --git a/src/shared/journal-importer.h b/src/shared/journal-importer.h index 13f699ae4d..ce954da483 100644 --- a/src/shared/journal-importer.h +++ b/src/shared/journal-importer.h @@ -4,7 +4,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" #include "iovec-wrapper.h" #include "time-util.h" diff --git a/src/shared/journal-util.h b/src/shared/journal-util.h index 2805ae1976..4e12e4b76f 100644 --- a/src/shared/journal-util.h +++ b/src/shared/journal-util.h @@ -3,7 +3,7 @@ #include "sd-journal.h" /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" int journal_access_blocked(sd_journal *j); int journal_access_check_and_warn(sd_journal *j, bool quiet, bool want_other_users); diff --git a/src/shared/kbd-util.h b/src/shared/kbd-util.h index 35ae976baa..28c63dc791 100644 --- a/src/shared/kbd-util.h +++ b/src/shared/kbd-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int keymap_directories(char ***ret); int get_keymaps(char ***ret); diff --git a/src/shared/kernel-config.h b/src/shared/kernel-config.h index 2c149ba3bd..faa05d34a6 100644 --- a/src/shared/kernel-config.h +++ b/src/shared/kernel-config.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int load_kernel_install_conf( const char *root, diff --git a/src/shared/kernel-image.h b/src/shared/kernel-image.h index 0474728050..b9f7cf353d 100644 --- a/src/shared/kernel-image.h +++ b/src/shared/kernel-image.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum KernelImageType { KERNEL_IMAGE_TYPE_UNKNOWN, diff --git a/src/shared/killall.h b/src/shared/killall.h index 1eb198acec..a39675b119 100644 --- a/src/shared/killall.h +++ b/src/shared/killall.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int broadcast_signal(int sig, bool wait_for_exit, bool send_sighup, usec_t timeout); diff --git a/src/shared/label-util.h b/src/shared/label-util.h index b1586dd81e..c7ed307dee 100644 --- a/src/shared/label-util.h +++ b/src/shared/label-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "label.h" /* IWYU pragma: export */ typedef enum LabelFixFlags { diff --git a/src/shared/libarchive-util.h b/src/shared/libarchive-util.h index 5eed91db0b..7d4ba3b6ba 100644 --- a/src/shared/libarchive-util.h +++ b/src/shared/libarchive-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_LIBARCHIVE #include /* IWYU pragma: export */ diff --git a/src/shared/libaudit-util.h b/src/shared/libaudit-util.h index f33258f9e1..759b1c7574 100644 --- a/src/shared/libaudit-util.h +++ b/src/shared/libaudit-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int dlopen_libaudit(void); diff --git a/src/shared/libcrypt-util.h b/src/shared/libcrypt-util.h index 25790f9ad3..27c5f055a3 100644 --- a/src/shared/libcrypt-util.h +++ b/src/shared/libcrypt-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int make_salt(char **ret); int hash_password_full(const char *password, void **cd_data, int *cd_size, char **ret); diff --git a/src/shared/libfido2-util.h b/src/shared/libfido2-util.h index c39cf73160..c5d3875a0d 100644 --- a/src/shared/libfido2-util.h +++ b/src/shared/libfido2-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define FIDO2_SALT_SIZE 32U diff --git a/src/shared/libmount-util.h b/src/shared/libmount-util.h index 17f8ebf0ad..f7fc39cd9b 100644 --- a/src/shared/libmount-util.h +++ b/src/shared/libmount-util.h @@ -5,7 +5,7 @@ #include /* IWYU pragma: export */ #include "dlfcn-util.h" -#include "forward.h" +#include "shared-forward.h" extern DLSYM_PROTOTYPE(mnt_free_iter); extern DLSYM_PROTOTYPE(mnt_free_table); diff --git a/src/shared/local-addresses.h b/src/shared/local-addresses.h index ed8aa055ce..089239dac6 100644 --- a/src/shared/local-addresses.h +++ b/src/shared/local-addresses.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" struct local_address { diff --git a/src/shared/locale-setup.h b/src/shared/locale-setup.h index fec9046bb7..8b71064cad 100644 --- a/src/shared/locale-setup.h +++ b/src/shared/locale-setup.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #include "locale-util.h" typedef struct LocaleContext { diff --git a/src/shared/logs-show.h b/src/shared/logs-show.h index 22b087d3e8..ecf6bf2859 100644 --- a/src/shared/logs-show.h +++ b/src/shared/logs-show.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef struct LogId { sd_id128_t id; /* boot ID or invocation ID */ diff --git a/src/shared/loop-util.h b/src/shared/loop-util.h index fe9b3f1053..d015c99751 100644 --- a/src/shared/loop-util.h +++ b/src/shared/loop-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Some helpers for setting up loopback block devices */ diff --git a/src/shared/machine-bind-user.h b/src/shared/machine-bind-user.h index c0a74a704f..2751bc315b 100644 --- a/src/shared/machine-bind-user.h +++ b/src/shared/machine-bind-user.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct MachineBindUserData { /* The host's user/group records */ diff --git a/src/shared/machine-credential.h b/src/shared/machine-credential.h index 244ebd6192..adef6a0605 100644 --- a/src/shared/machine-credential.h +++ b/src/shared/machine-credential.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct MachineCredential { char *id; diff --git a/src/shared/machine-id-setup.h b/src/shared/machine-id-setup.h index a5100766a4..b5f76713ce 100644 --- a/src/shared/machine-id-setup.h +++ b/src/shared/machine-id-setup.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef enum MachineIdSetupFlags { MACHINE_ID_SETUP_FORCE_TRANSIENT = 1 << 0, diff --git a/src/shared/machine-pool.h b/src/shared/machine-pool.h index 0719ba011f..feb3663b64 100644 --- a/src/shared/machine-pool.h +++ b/src/shared/machine-pool.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int setup_machine_directory(sd_bus_error *error, bool use_btrfs_subvol, bool use_btrfs_quota); diff --git a/src/shared/macvlan-util.h b/src/shared/macvlan-util.h index f2e5e458c3..78817d2ce6 100644 --- a/src/shared/macvlan-util.h +++ b/src/shared/macvlan-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef enum MacVlanMode { NETDEV_MACVLAN_MODE_PRIVATE = MACVLAN_MODE_PRIVATE, diff --git a/src/shared/main-func.h b/src/shared/main-func.h index ecd23fe601..95a2ccbf18 100644 --- a/src/shared/main-func.h +++ b/src/shared/main-func.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "static-destruct.h" void main_prepare(int argc, char *argv[]); diff --git a/src/shared/mkdir-label.h b/src/shared/mkdir-label.h index ef5722d035..c884190a0e 100644 --- a/src/shared/mkdir-label.h +++ b/src/shared/mkdir-label.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "mkdir.h" int mkdirat_label(int dirfd, const char *path, mode_t mode); diff --git a/src/shared/mkfs-util.h b/src/shared/mkfs-util.h index 2e83370d03..7ab78be98a 100644 --- a/src/shared/mkfs-util.h +++ b/src/shared/mkfs-util.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" typedef enum MakeFilesystemFlags { MKFS_QUIET = 1 << 0, /* Suppress mkfs command output */ diff --git a/src/shared/module-util.h b/src/shared/module-util.h index e98e0049b6..55c81612c3 100644 --- a/src/shared/module-util.h +++ b/src/shared/module-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_KMOD diff --git a/src/shared/mount-setup.h b/src/shared/mount-setup.h index 9e1787b2c5..0f0bbaff56 100644 --- a/src/shared/mount-setup.h +++ b/src/shared/mount-setup.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool mount_point_is_api(const char *path) _pure_; bool mount_point_ignore(const char *path) _pure_; diff --git a/src/shared/mount-util.h b/src/shared/mount-util.h index 902092be68..c5968dc565 100644 --- a/src/shared/mount-util.h +++ b/src/shared/mount-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct SubMount { char *path; diff --git a/src/shared/net-condition.h b/src/shared/net-condition.h index ff3f2a36b5..49be68a0c4 100644 --- a/src/shared/net-condition.h +++ b/src/shared/net-condition.h @@ -4,7 +4,7 @@ #include #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" typedef struct NetMatch { Set *hw_addr; diff --git a/src/shared/netif-naming-scheme.h b/src/shared/netif-naming-scheme.h index 504ffec535..0929f7ce63 100644 --- a/src/shared/netif-naming-scheme.h +++ b/src/shared/netif-naming-scheme.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* So here's the deal: net_id is supposed to be an exercise in providing stable names for network devices. However, we * also want to keep updating the naming scheme used in future versions of net_id. These two goals of course are diff --git a/src/shared/netif-sriov.h b/src/shared/netif-sriov.h index 7fc7393bd3..891496ffeb 100644 --- a/src/shared/netif-sriov.h +++ b/src/shared/netif-sriov.h @@ -5,7 +5,7 @@ #include #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" typedef enum SRIOVAttribute { SR_IOV_VF_MAC, diff --git a/src/shared/netif-util.h b/src/shared/netif-util.h index 5b2ba1d11d..cf956f42c6 100644 --- a/src/shared/netif-util.h +++ b/src/shared/netif-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool netif_has_carrier(uint8_t operstate, unsigned flags); int net_get_type_string(sd_device *device, uint16_t iftype, char **ret); diff --git a/src/shared/notify-recv.h b/src/shared/notify-recv.h index e260e7ef5e..5075739d6c 100644 --- a/src/shared/notify-recv.h +++ b/src/shared/notify-recv.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int notify_socket_prepare_full( sd_event *event, diff --git a/src/shared/nsflags.h b/src/shared/nsflags.h index 35bcb6a8c9..19d3fc195e 100644 --- a/src/shared/nsflags.h +++ b/src/shared/nsflags.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* The combination of all namespace flags defined by the kernel. The right type for this isn't clear. setns() and * unshare() expect these flags to be passed as (signed) "int", while clone() wants them as "unsigned long". The latter diff --git a/src/shared/nsresource.h b/src/shared/nsresource.h index 55937fd483..c06025761a 100644 --- a/src/shared/nsresource.h +++ b/src/shared/nsresource.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int nsresource_allocate_userns(const char *name, uint64_t size); int nsresource_register_userns(const char *name, int userns_fd); diff --git a/src/shared/nss-util.h b/src/shared/nss-util.h index a4a4b5d920..c182237368 100644 --- a/src/shared/nss-util.h +++ b/src/shared/nss-util.h @@ -7,7 +7,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" #include "signal-util.h" extern sd_json_dispatch_flags_t nss_json_dispatch_flags; diff --git a/src/shared/numa-util.h b/src/shared/numa-util.h index 1c3482a590..6e31c00f04 100644 --- a/src/shared/numa-util.h +++ b/src/shared/numa-util.h @@ -4,7 +4,7 @@ #include #include "cpu-set-util.h" -#include "forward.h" +#include "shared-forward.h" static inline bool mpol_is_valid(int t) { return t >= MPOL_DEFAULT && t <= MPOL_LOCAL; diff --git a/src/shared/open-file.h b/src/shared/open-file.h index 7c1621e629..d11cf471de 100644 --- a/src/shared/open-file.h +++ b/src/shared/open-file.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "list.h" typedef enum OpenFileFlag { diff --git a/src/shared/openssl-util.h b/src/shared/openssl-util.h index f6c697672b..0cead42367 100644 --- a/src/shared/openssl-util.h +++ b/src/shared/openssl-util.h @@ -2,7 +2,7 @@ #pragma once #include "ask-password-api.h" -#include "forward.h" +#include "shared-forward.h" #include "iovec-util.h" #include "sha256.h" diff --git a/src/shared/osc-context.h b/src/shared/osc-context.h index 8f80b2932b..8db6e263cb 100644 --- a/src/shared/osc-context.h +++ b/src/shared/osc-context.h @@ -3,7 +3,7 @@ #include "sd-id128.h" -#include "forward.h" +#include "shared-forward.h" int osc_context_open_boot(char **ret_seq); int osc_context_open_container(const char *name, char **ret_seq, sd_id128_t *ret_context_id); diff --git a/src/shared/output-mode.h b/src/shared/output-mode.h index 7ee17df938..c700f6ca5d 100644 --- a/src/shared/output-mode.h +++ b/src/shared/output-mode.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum OutputMode { OUTPUT_SHORT, diff --git a/src/shared/pager.h b/src/shared/pager.h index bbd92a2bba..3760cd702c 100644 --- a/src/shared/pager.h +++ b/src/shared/pager.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum PagerFlags { PAGER_DISABLE = 1 << 0, diff --git a/src/shared/pam-util.h b/src/shared/pam-util.h index a4d35faa11..8f31ffd2f8 100644 --- a/src/shared/pam-util.h +++ b/src/shared/pam-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_PAM #include diff --git a/src/shared/parse-argument.h b/src/shared/parse-argument.h index 0f44223af3..f1b2b63178 100644 --- a/src/shared/parse-argument.h +++ b/src/shared/parse-argument.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int parse_boolean_argument(const char *optname, const char *s, bool *ret); int parse_tristate_argument(const char *optname, const char *s, int *ret); diff --git a/src/shared/parse-helpers.h b/src/shared/parse-helpers.h index c686b9cebb..402147cbf3 100644 --- a/src/shared/parse-helpers.h +++ b/src/shared/parse-helpers.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum PathSimplifyWarnFlags { PATH_CHECK_FATAL = 1 << 0, /* If not set, then error message is appended with 'ignoring'. */ diff --git a/src/shared/password-quality-util-passwdqc.h b/src/shared/password-quality-util-passwdqc.h index bda3be544c..1a0dd68e3d 100644 --- a/src/shared/password-quality-util-passwdqc.h +++ b/src/shared/password-quality-util-passwdqc.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_PASSWDQC #include diff --git a/src/shared/password-quality-util-pwquality.h b/src/shared/password-quality-util-pwquality.h index 0d12c76ad7..6ef4088716 100644 --- a/src/shared/password-quality-util-pwquality.h +++ b/src/shared/password-quality-util-pwquality.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_PWQUALITY #include diff --git a/src/shared/pcre2-util.h b/src/shared/pcre2-util.h index b1c9f24f14..aa9b77dc19 100644 --- a/src/shared/pcre2-util.h +++ b/src/shared/pcre2-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if HAVE_PCRE2 diff --git a/src/shared/pkcs11-util.h b/src/shared/pkcs11-util.h index 43203ce6bb..2b0aaa974c 100644 --- a/src/shared/pkcs11-util.h +++ b/src/shared/pkcs11-util.h @@ -12,7 +12,7 @@ #include "ask-password-api.h" #include "dlfcn-util.h" -#include "forward.h" +#include "shared-forward.h" bool pkcs11_uri_valid(const char *uri); diff --git a/src/shared/plymouth-util.h b/src/shared/plymouth-util.h index 86c9ec6cb8..c73b44567c 100644 --- a/src/shared/plymouth-util.h +++ b/src/shared/plymouth-util.h @@ -2,7 +2,7 @@ #pragma once #include "errno-util.h" -#include "forward.h" +#include "shared-forward.h" int plymouth_connect(int flags); int plymouth_send_raw(const void *raw, size_t size, int flags); diff --git a/src/shared/polkit-agent.h b/src/shared/polkit-agent.h index 3ed13f9ba5..fb0be87605 100644 --- a/src/shared/polkit-agent.h +++ b/src/shared/polkit-agent.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int polkit_agent_open(void); void polkit_agent_close(void); diff --git a/src/shared/portable-util.h b/src/shared/portable-util.h index b19e470452..1d9f6d20a4 100644 --- a/src/shared/portable-util.h +++ b/src/shared/portable-util.h @@ -2,7 +2,7 @@ #pragma once #include "constants.h" -#include "forward.h" +#include "shared-forward.h" #define PORTABLE_PROFILE_DIRS CONF_PATHS_NULSTR("systemd/portable/profile") diff --git a/src/shared/pretty-print.h b/src/shared/pretty-print.h index 8ea711a09d..6b759dd346 100644 --- a/src/shared/pretty-print.h +++ b/src/shared/pretty-print.h @@ -6,7 +6,7 @@ #include "ansi-color.h" #include "fileio.h" -#include "forward.h" +#include "shared-forward.h" #include "glyph-util.h" #define CYLON_BUFFER_EXTRA (2*STRLEN(ANSI_RED) + STRLEN(ANSI_HIGHLIGHT_RED) + 2*STRLEN(ANSI_NORMAL)) diff --git a/src/shared/prompt-util.h b/src/shared/prompt-util.h index 70f8f0215d..2b81c1245d 100644 --- a/src/shared/prompt-util.h +++ b/src/shared/prompt-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" typedef enum PromptFlags { PROMPT_MAY_SKIP = 1 << 0, /* Question may be skipped */ diff --git a/src/shared/ptyfwd.h b/src/shared/ptyfwd.h index 1983a1cd16..31020952d3 100644 --- a/src/shared/ptyfwd.h +++ b/src/shared/ptyfwd.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct PTYForward PTYForward; diff --git a/src/shared/qrcode-util.h b/src/shared/qrcode-util.h index a635810bfe..9a624e29e1 100644 --- a/src/shared/qrcode-util.h +++ b/src/shared/qrcode-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int print_qrcode_full( FILE *out, diff --git a/src/shared/quota-util.h b/src/shared/quota-util.h index 2e82b94134..21c80011a7 100644 --- a/src/shared/quota-util.h +++ b/src/shared/quota-util.h @@ -4,7 +4,7 @@ #include /* IWYU pragma: export */ #include /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" /* Wrapper around the QCMD() macro of linux/quota.h that removes some undefined behaviour. A typical quota * command such as QCMD(Q_GETQUOTA, USRQUOTA) cannot be resolved on platforms where "int" is 32-bit, as it is diff --git a/src/shared/reboot-util.h b/src/shared/reboot-util.h index 276361aea8..eaa6614df0 100644 --- a/src/shared/reboot-util.h +++ b/src/shared/reboot-util.h @@ -4,7 +4,7 @@ #include /* IWYU pragma: export */ #include /* IWYU pragma: export */ -#include "forward.h" +#include "shared-forward.h" /* glibc defines the reboot() API call, which is a wrapper around the system call of the same name, but * without the extra "arg" parameter. Since we need that parameter for some calls, let's add a "raw" wrapper diff --git a/src/shared/recovery-key.h b/src/shared/recovery-key.h index ec7090a1c2..2206021fe4 100644 --- a/src/shared/recovery-key.h +++ b/src/shared/recovery-key.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* 256 bit keys = 32 bytes */ #define RECOVERY_KEY_MODHEX_RAW_LENGTH 32 diff --git a/src/shared/resize-fs.h b/src/shared/resize-fs.h index 8cfda56696..6f2cc0219e 100644 --- a/src/shared/resize-fs.h +++ b/src/shared/resize-fs.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "stat-util.h" int resize_fs(int fd, uint64_t sz, uint64_t *ret_size); diff --git a/src/shared/resolve-util.h b/src/shared/resolve-util.h index a8f7fd41ef..102644054b 100644 --- a/src/shared/resolve-util.h +++ b/src/shared/resolve-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" /* 127.0.0.53 in native endian (The IP address we listen on with the full DNS stub, i.e. that does LLMNR/mDNS, and stuff) */ #define INADDR_DNS_STUB ((in_addr_t) 0x7f000035U) diff --git a/src/shared/rm-rf.h b/src/shared/rm-rf.h index abad164e21..9353cafcbf 100644 --- a/src/shared/rm-rf.h +++ b/src/shared/rm-rf.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum RemoveFlags { REMOVE_ONLY_DIRECTORIES = 1 << 0, /* Only remove empty directories, no files */ diff --git a/src/shared/seccomp-util.h b/src/shared/seccomp-util.h index b0aa5b2a35..e853b9e225 100644 --- a/src/shared/seccomp-util.h +++ b/src/shared/seccomp-util.h @@ -2,7 +2,7 @@ #pragma once #include "errno-util.h" -#include "forward.h" +#include "shared-forward.h" #if HAVE_SECCOMP #include /* IWYU pragma: export */ diff --git a/src/shared/securebits-util.h b/src/shared/securebits-util.h index 19b836b4e7..dc61ecd57e 100644 --- a/src/shared/securebits-util.h +++ b/src/shared/securebits-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int secure_bits_to_string_alloc(int i, char **s); int secure_bits_from_string(const char *s); diff --git a/src/shared/selinux-util.h b/src/shared/selinux-util.h index 726cbbea08..e6432b3792 100644 --- a/src/shared/selinux-util.h +++ b/src/shared/selinux-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" #if HAVE_SELINUX #include diff --git a/src/shared/serialize.h b/src/shared/serialize.h index 45bd710d73..6e5e9216ba 100644 --- a/src/shared/serialize.h +++ b/src/shared/serialize.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int serialize_item(FILE *f, const char *key, const char *value); int serialize_item_escaped(FILE *f, const char *key, const char *value); diff --git a/src/shared/service-util.h b/src/shared/service-util.h index 462ba2b3fa..0529f30ad5 100644 --- a/src/shared/service-util.h +++ b/src/shared/service-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int service_parse_argv( const char *service, diff --git a/src/shared/shared-forward.h b/src/shared/shared-forward.h new file mode 100644 index 0000000000..a15e2769af --- /dev/null +++ b/src/shared/shared-forward.h @@ -0,0 +1,72 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ +#pragma once + +/* IWYU pragma: always_keep */ + +#include "sd-forward.h" /* IWYU pragma: export */ + +typedef int (*copy_progress_bytes_t)(uint64_t n_bytes, uint64_t bytes_per_second, void *userdata); +typedef int (*copy_progress_path_t)(const char *path, const struct stat *st, void *userdata); + +struct local_address; +struct in_addr_prefix; +struct in_addr_full; + +typedef enum AskPasswordFlags AskPasswordFlags; +typedef enum BootEntryTokenType BootEntryTokenType; +typedef enum BusPrintPropertyFlags BusPrintPropertyFlags; +typedef enum BusTransport BusTransport; +typedef enum CatFlags CatFlags; +typedef enum CertificateSourceType CertificateSourceType; +typedef enum DnsCacheMode DnsCacheMode; +typedef enum DnsOverTlsMode DnsOverTlsMode; +typedef enum DnssecMode DnssecMode; +typedef enum Fido2EnrollFlags Fido2EnrollFlags; +typedef enum KeySourceType KeySourceType; +typedef enum LabelFixFlags LabelFixFlags; +typedef enum MountInNamespaceFlags MountInNamespaceFlags; +typedef enum NamePolicy NamePolicy; +typedef enum OutputFlags OutputFlags; +typedef enum OutputMode OutputMode; +typedef enum PagerFlags PagerFlags; +typedef enum PatternCompileCase PatternCompileCase; +typedef enum RemoveFlags RemoveFlags; +typedef enum ResolveSupport ResolveSupport; +typedef enum TPM2Flags TPM2Flags; +typedef enum Tpm2Support Tpm2Support; +typedef enum Tpm2UserspaceEventType Tpm2UserspaceEventType; +typedef enum UnitFileFlags UnitFileFlags; +typedef enum UnitFilePresetMode UnitFilePresetMode; +typedef enum UnitFileState UnitFileState; +typedef enum UserDBFlags UserDBFlags; +typedef enum UserRecordLoadFlags UserRecordLoadFlags; +typedef enum UserStorage UserStorage; + +typedef struct Bitmap Bitmap; +typedef struct BPFProgram BPFProgram; +typedef struct BusObjectImplementation BusObjectImplementation; +typedef struct CalendarSpec CalendarSpec; +typedef struct Condition Condition; +typedef struct ConfigSection ConfigSection; +typedef struct ConfigTableItem ConfigTableItem; +typedef struct CPUSet CPUSet; +typedef struct FDSet FDSet; +typedef struct Fido2HmacSalt Fido2HmacSalt; +typedef struct GroupRecord GroupRecord; +typedef struct Image Image; +typedef struct ImagePolicy ImagePolicy; +typedef struct InstallInfo InstallInfo; +typedef struct LookupPaths LookupPaths; +typedef struct LoopDevice LoopDevice; +typedef struct MachineBindUserContext MachineBindUserContext; +typedef struct MachineCredentialContext MachineCredentialContext; +typedef struct MountOptions MountOptions; +typedef struct OpenFile OpenFile; +typedef struct Pkcs11EncryptedKey Pkcs11EncryptedKey; +typedef struct Table Table; +typedef struct Tpm2Context Tpm2Context; +typedef struct Tpm2Handle Tpm2Handle; +typedef struct Tpm2PCRValue Tpm2PCRValue; +typedef struct UnitInfo UnitInfo; +typedef struct UserRecord UserRecord; +typedef struct VeritySettings VeritySettings; diff --git a/src/shared/shift-uid.h b/src/shared/shift-uid.h index 59435c748d..d980efd699 100644 --- a/src/shared/shift-uid.h +++ b/src/shared/shift-uid.h @@ -2,6 +2,6 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" int path_patch_uid(const char *path, uid_t shift, uid_t range); diff --git a/src/shared/sleep-config.h b/src/shared/sleep-config.h index 9463a23d6d..129c9e6b47 100644 --- a/src/shared/sleep-config.h +++ b/src/shared/sleep-config.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum SleepOperation { SLEEP_SUSPEND, diff --git a/src/shared/smack-util.h b/src/shared/smack-util.h index b778889842..bb5b317747 100644 --- a/src/shared/smack-util.h +++ b/src/shared/smack-util.h @@ -7,7 +7,7 @@ Author: Auke Kok ***/ -#include "forward.h" +#include "shared-forward.h" typedef enum SmackAttr { SMACK_ATTR_ACCESS, diff --git a/src/shared/smbios11.h b/src/shared/smbios11.h index 1d097c0af4..8e6d0dfb32 100644 --- a/src/shared/smbios11.h +++ b/src/shared/smbios11.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int read_smbios11_field(unsigned i, size_t max_size, char **ret_data, size_t *ret_size); diff --git a/src/shared/socket-netlink.h b/src/shared/socket-netlink.h index c9b71d5100..f371967c69 100644 --- a/src/shared/socket-netlink.h +++ b/src/shared/socket-netlink.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "in-addr-util.h" int make_socket_fd(int log_level, const char* address, int type, int flags); diff --git a/src/shared/specifier.h b/src/shared/specifier.h index 3b9d43cd85..68cad23102 100644 --- a/src/shared/specifier.h +++ b/src/shared/specifier.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef int (*SpecifierCallback)(char specifier, const void *data, const char *root, const void *userdata, char **ret); diff --git a/src/shared/switch-root.h b/src/shared/switch-root.h index 2b8e143251..63da181791 100644 --- a/src/shared/switch-root.h +++ b/src/shared/switch-root.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum SwitchRootFlags { SWITCH_ROOT_DESTROY_OLD_ROOT = 1 << 0, /* rm -rf old root when switching – under the condition diff --git a/src/shared/test-tables.h b/src/shared/test-tables.h index 41b719ccce..a1e40addb6 100644 --- a/src/shared/test-tables.h +++ b/src/shared/test-tables.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "string-util.h" #define _test_table(type, name, lookup, reverse, size, sparse) \ diff --git a/src/shared/tests.h b/src/shared/tests.h index 5c933c4801..3f50b3dc54 100644 --- a/src/shared/tests.h +++ b/src/shared/tests.h @@ -5,7 +5,7 @@ #include "errno-list.h" #include "errno-util.h" -#include "forward.h" +#include "shared-forward.h" #include "log.h" #include "static-destruct.h" #include "signal-util.h" diff --git a/src/shared/tmpfile-util-label.h b/src/shared/tmpfile-util-label.h index 4189b28681..d8920cc697 100644 --- a/src/shared/tmpfile-util-label.h +++ b/src/shared/tmpfile-util-label.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* These functions are split out of tmpfile-util.h (and not for example just flags to the functions they * wrap) in order to optimize linking: this way, -lselinux is needed only for the callers of these functions diff --git a/src/shared/tomoyo-util.h b/src/shared/tomoyo-util.h index d5c0fe8e66..c539ca2d2b 100644 --- a/src/shared/tomoyo-util.h +++ b/src/shared/tomoyo-util.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool mac_tomoyo_use(void); diff --git a/src/shared/tpm2-event-log.h b/src/shared/tpm2-event-log.h index 76890fe158..50a8584c6e 100644 --- a/src/shared/tpm2-event-log.h +++ b/src/shared/tpm2-event-log.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "tpm2-util.h" /* Definitions as per "TCG PC Client Specific Platform Firmware Profile Specification" diff --git a/src/shared/tpm2-util.h b/src/shared/tpm2-util.h index 57674133bf..b051c8435e 100644 --- a/src/shared/tpm2-util.h +++ b/src/shared/tpm2-util.h @@ -2,7 +2,7 @@ #pragma once #include "bitfield.h" -#include "forward.h" +#include "shared-forward.h" #include "openssl-util.h" typedef enum TPM2Flags { diff --git a/src/shared/udev-util.h b/src/shared/udev-util.h index 95992f6345..6076f328f4 100644 --- a/src/shared/udev-util.h +++ b/src/shared/udev-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser.h" -#include "forward.h" +#include "shared-forward.h" int udev_parse_config_full(const ConfigTableItem config_table[]); int udev_parse_config(void); diff --git a/src/shared/unit-file.h b/src/shared/unit-file.h index bfb6b740cc..dd1cd33fda 100644 --- a/src/shared/unit-file.h +++ b/src/shared/unit-file.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "unit-def.h" typedef enum UnitFileState { diff --git a/src/shared/user-record-nss.h b/src/shared/user-record-nss.h index c2f2faf16c..835b1d686b 100644 --- a/src/shared/user-record-nss.h +++ b/src/shared/user-record-nss.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* Synthesize UserRecord and GroupRecord objects from NSS data */ diff --git a/src/shared/user-record-show.h b/src/shared/user-record-show.h index 3612fa3624..7952a73431 100644 --- a/src/shared/user-record-show.h +++ b/src/shared/user-record-show.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" const char* user_record_state_color(const char *state); diff --git a/src/shared/user-record.h b/src/shared/user-record.h index e4384e50b7..d0d95473eb 100644 --- a/src/shared/user-record.h +++ b/src/shared/user-record.h @@ -5,7 +5,7 @@ #include "bitfield.h" #include "rlimit-util.h" -#include "forward.h" +#include "shared-forward.h" typedef enum UserDisposition { USER_INTRINSIC, /* root and nobody */ diff --git a/src/shared/userdb-dropin.h b/src/shared/userdb-dropin.h index 170232f99d..a8131fb337 100644 --- a/src/shared/userdb-dropin.h +++ b/src/shared/userdb-dropin.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" /* This could be put together with CONF_PATHS_NULSTR, with the exception of the /run/host/ part in the * middle, which we use here, but not otherwise. */ diff --git a/src/shared/userdb.h b/src/shared/userdb.h index d56d9214a9..08d602ddf7 100644 --- a/src/shared/userdb.h +++ b/src/shared/userdb.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "group-record.h" #include "user-record.h" diff --git a/src/shared/utmp-wtmp.h b/src/shared/utmp-wtmp.h index 72e8ff375b..e1467eeaf3 100644 --- a/src/shared/utmp-wtmp.h +++ b/src/shared/utmp-wtmp.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if ENABLE_UTMP #include diff --git a/src/shared/varlink-serialize.h b/src/shared/varlink-serialize.h index 9bb47b9570..db5de52161 100644 --- a/src/shared/varlink-serialize.h +++ b/src/shared/varlink-serialize.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int varlink_server_serialize(sd_varlink_server *s, FILE *f, FDSet *fds); int varlink_server_deserialize_one(sd_varlink_server *s, const char *value, FDSet *fds); diff --git a/src/shared/vconsole-util.h b/src/shared/vconsole-util.h index 00ccd3bbf7..13aca45204 100644 --- a/src/shared/vconsole-util.h +++ b/src/shared/vconsole-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct X11Context { char *layout; diff --git a/src/shared/verb-log-control.h b/src/shared/verb-log-control.h index 71c5f6c58d..91432acce9 100644 --- a/src/shared/verb-log-control.h +++ b/src/shared/verb-log-control.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int verb_log_control_common(sd_bus *bus, const char *destination, const char *verb, const char *value); diff --git a/src/shared/verbs.h b/src/shared/verbs.h index abf1a35641..0fb6621af6 100644 --- a/src/shared/verbs.h +++ b/src/shared/verbs.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #define VERB_ANY (UINT_MAX) diff --git a/src/shared/vlan-util.h b/src/shared/vlan-util.h index 835e0f6cc2..b02001f238 100644 --- a/src/shared/vlan-util.h +++ b/src/shared/vlan-util.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" -#include "forward.h" +#include "shared-forward.h" #define VLANID_MAX 4094 #define VLANID_INVALID UINT16_MAX diff --git a/src/shared/volatile-util.h b/src/shared/volatile-util.h index b9cd6c283a..fd9c323fae 100644 --- a/src/shared/volatile-util.h +++ b/src/shared/volatile-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum VolatileMode { VOLATILE_NO, diff --git a/src/shared/vpick.h b/src/shared/vpick.h index 3075a4b047..3c23104ca9 100644 --- a/src/shared/vpick.h +++ b/src/shared/vpick.h @@ -4,7 +4,7 @@ #include #include "architecture.h" -#include "forward.h" +#include "shared-forward.h" typedef enum PickFlags { PICK_ARCHITECTURE = 1 << 0, /* Look for an architecture suffix */ diff --git a/src/shared/wall.h b/src/shared/wall.h index c622b6f652..d38e1ae472 100644 --- a/src/shared/wall.h +++ b/src/shared/wall.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if ENABLE_UTMP || ENABLE_LOGIND diff --git a/src/shared/watchdog.h b/src/shared/watchdog.h index f613689ca5..322614247b 100644 --- a/src/shared/watchdog.h +++ b/src/shared/watchdog.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" const char* watchdog_get_device(void); usec_t watchdog_get_last_ping(clockid_t clock); diff --git a/src/shared/web-util.h b/src/shared/web-util.h index 1bb8509da0..68f868ab0a 100644 --- a/src/shared/web-util.h +++ b/src/shared/web-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" bool http_url_is_valid(const char *url) _pure_; bool file_url_is_valid(const char *url) _pure_; diff --git a/src/shared/wifi-util.h b/src/shared/wifi-util.h index 973a49155a..f590dfffa1 100644 --- a/src/shared/wifi-util.h +++ b/src/shared/wifi-util.h @@ -4,7 +4,7 @@ #include -#include "forward.h" +#include "shared-forward.h" int wifi_get_interface(sd_netlink *genl, int ifindex, enum nl80211_iftype *ret_iftype, char **ret_ssid); int wifi_get_station(sd_netlink *genl, int ifindex, struct ether_addr *ret_bssid); diff --git a/src/shared/xml.h b/src/shared/xml.h index 1ef9de147d..8deca29dd7 100644 --- a/src/shared/xml.h +++ b/src/shared/xml.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" enum { XML_END, diff --git a/src/shutdown/detach-dm.h b/src/shutdown/detach-dm.h index 0db81350e0..50e52cf65f 100644 --- a/src/shutdown/detach-dm.h +++ b/src/shutdown/detach-dm.h @@ -5,6 +5,6 @@ Copyright © 2010 ProFUSION embedded systems ***/ -#include "forward.h" +#include "shared-forward.h" int dm_detach_all(bool *changed, bool last_try); diff --git a/src/shutdown/detach-loopback.h b/src/shutdown/detach-loopback.h index 18cb2f6cfc..16464a1b75 100644 --- a/src/shutdown/detach-loopback.h +++ b/src/shutdown/detach-loopback.h @@ -5,6 +5,6 @@ Copyright © 2010 ProFUSION embedded systems ***/ -#include "forward.h" +#include "shared-forward.h" int loopback_detach_all(bool *changed, bool last_try); diff --git a/src/shutdown/detach-md.h b/src/shutdown/detach-md.h index 8965a6ab65..656ea01bc7 100644 --- a/src/shutdown/detach-md.h +++ b/src/shutdown/detach-md.h @@ -5,6 +5,6 @@ Copyright © 2010 ProFUSION embedded systems ***/ -#include "forward.h" +#include "shared-forward.h" int md_detach_all(bool *changed, bool last_try); diff --git a/src/shutdown/detach-swap.h b/src/shutdown/detach-swap.h index 64e89076e7..8d267e5073 100644 --- a/src/shutdown/detach-swap.h +++ b/src/shutdown/detach-swap.h @@ -5,7 +5,7 @@ Copyright © 2010 ProFUSION embedded systems ***/ -#include "forward.h" +#include "shared-forward.h" #include "list.h" int swapoff_all(bool *changed); diff --git a/src/shutdown/umount.h b/src/shutdown/umount.h index 5fdaf76392..b168c40eef 100644 --- a/src/shutdown/umount.h +++ b/src/shutdown/umount.h @@ -5,7 +5,7 @@ Copyright © 2010 ProFUSION embedded systems ***/ -#include "forward.h" +#include "shared-forward.h" #include "list.h" int umount_all(bool *changed, bool last_try); diff --git a/src/systemctl/systemctl-list-machines.h b/src/systemctl/systemctl-list-machines.h index 660c50cab0..f1dd8353e1 100644 --- a/src/systemctl/systemctl-list-machines.h +++ b/src/systemctl/systemctl-list-machines.h @@ -2,7 +2,7 @@ #pragma once #include "bus-map-properties.h" -#include "forward.h" +#include "shared-forward.h" int verb_list_machines(int argc, char *argv[], void *userdata); diff --git a/src/systemctl/systemctl.h b/src/systemctl/systemctl.h index 5cbdfea48c..8d4b1a614d 100644 --- a/src/systemctl/systemctl.h +++ b/src/systemctl/systemctl.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" enum action { ACTION_SYSTEMCTL, diff --git a/src/sysupdate/sysupdate-forward.h b/src/sysupdate/sysupdate-forward.h index d6b83c0f73..a92de0878a 100644 --- a/src/sysupdate/sysupdate-forward.h +++ b/src/sysupdate/sysupdate-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef struct Context Context; typedef struct PartitionInfo PartitionInfo; diff --git a/src/sysupdate/sysupdate-update-set-flags.h b/src/sysupdate/sysupdate-update-set-flags.h index b0036e0b2e..27cfab8c7c 100644 --- a/src/sysupdate/sysupdate-update-set-flags.h +++ b/src/sysupdate/sysupdate-update-set-flags.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum UpdateSetFlags { UPDATE_NEWEST = 1 << 0, diff --git a/src/test/nss-test-util.h b/src/test/nss-test-util.h index efd65845c5..cc5c78670f 100644 --- a/src/test/nss-test-util.h +++ b/src/test/nss-test-util.h @@ -3,7 +3,7 @@ #include -#include "forward.h" +#include "shared-forward.h" const char* nss_status_to_string(enum nss_status status, char *buf, size_t buf_len); void* nss_open_handle(const char *dir, const char *module, int flags); diff --git a/src/test/test-dlopen.c b/src/test/test-dlopen.c index 91e1d2f8a3..b44c55fbeb 100644 --- a/src/test/test-dlopen.c +++ b/src/test/test-dlopen.c @@ -3,7 +3,7 @@ #include #include -#include "forward.h" +#include "shared-forward.h" int main(int argc, char **argv) { void *handles[argc - 1]; diff --git a/src/test/test-sizeof.c b/src/test/test-sizeof.c index 075cc8c5a0..21a7d74005 100644 --- a/src/test/test-sizeof.c +++ b/src/test/test-sizeof.c @@ -12,7 +12,7 @@ #define __STDC_WANT_IEC_60559_TYPES_EXT__ #include -#include "forward.h" +#include "shared-forward.h" /* Print information about various types. Useful when diagnosing * gcc diagnostics on an unfamiliar architecture. */ diff --git a/src/timedate/hwclock-util.h b/src/timedate/hwclock-util.h index ad24dad3a7..9e83d290e7 100644 --- a/src/timedate/hwclock-util.h +++ b/src/timedate/hwclock-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int hwclock_get(struct tm *tm); int hwclock_set(const struct tm *tm); diff --git a/src/timesync/timesyncd-forward.h b/src/timesync/timesyncd-forward.h index 7a63e38f54..8df2e02111 100644 --- a/src/timesync/timesyncd-forward.h +++ b/src/timesync/timesyncd-forward.h @@ -2,7 +2,7 @@ #pragma once #include "conf-parser-forward.h" /* IWYU pragma: export */ -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef enum ServerType ServerType; diff --git a/src/tmpfiles/offline-passwd.h b/src/tmpfiles/offline-passwd.h index d031ef74c9..d2ae211f5e 100644 --- a/src/tmpfiles/offline-passwd.h +++ b/src/tmpfiles/offline-passwd.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int name_to_uid_offline(const char *root, const char *user, uid_t *ret_uid, Hashmap **cache); int name_to_gid_offline(const char *root, const char *group, gid_t *ret_gid, Hashmap **cache); diff --git a/src/udev/fido_id/fido_id_desc.h b/src/udev/fido_id/fido_id_desc.h index 90ae6cbdf1..df22a420fd 100644 --- a/src/udev/fido_id/fido_id_desc.h +++ b/src/udev/fido_id/fido_id_desc.h @@ -2,6 +2,6 @@ #pragma once -#include "forward.h" +#include "shared-forward.h" int is_fido_security_token_desc(const uint8_t *desc, size_t desc_len); diff --git a/src/udev/mtd_probe/mtd_probe.h b/src/udev/mtd_probe/mtd_probe.h index fe1f28d12f..08a793952e 100644 --- a/src/udev/mtd_probe/mtd_probe.h +++ b/src/udev/mtd_probe/mtd_probe.h @@ -22,7 +22,7 @@ #include -#include "forward.h" +#include "shared-forward.h" /* Full oob structure as written on the flash */ struct sm_oob { diff --git a/src/udev/net/link-config.h b/src/udev/net/link-config.h index 9342c92482..b7d59a22d9 100644 --- a/src/udev/net/link-config.h +++ b/src/udev/net/link-config.h @@ -6,7 +6,7 @@ #include "cpu-set-util.h" #include "ether-addr-util.h" #include "ethtool-util.h" -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "net-condition.h" diff --git a/src/udev/udev-builtin.h b/src/udev/udev-builtin.h index 62d43f8c79..5f600d6a43 100644 --- a/src/udev/udev-builtin.h +++ b/src/udev/udev-builtin.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "udev-event.h" typedef struct UdevBuiltin { diff --git a/src/udev/udev-error.h b/src/udev/udev-error.h index 96f9134e68..c1db12960b 100644 --- a/src/udev/udev-error.h +++ b/src/udev/udev-error.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int device_add_errno(sd_device *dev, int error); int device_add_exit_status(sd_device *dev, int status); diff --git a/src/udev/udev-forward.h b/src/udev/udev-forward.h index 3d0079f183..f5e9be6a1f 100644 --- a/src/udev/udev-forward.h +++ b/src/udev/udev-forward.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" /* IWYU pragma: export */ +#include "shared-forward.h" /* IWYU pragma: export */ typedef struct UdevCtrl UdevCtrl; typedef struct UdevEvent UdevEvent; diff --git a/src/udev/udev-manager.h b/src/udev/udev-manager.h index 2a384dcfaa..9bb9363240 100644 --- a/src/udev/udev-manager.h +++ b/src/udev/udev-manager.h @@ -3,7 +3,7 @@ #include "sd-event.h" -#include "forward.h" +#include "shared-forward.h" #include "list.h" #include "udev-config.h" #include "udev-forward.h" diff --git a/src/udev/udev-node.h b/src/udev/udev-node.h index 8a0a72f0e8..904421c0ec 100644 --- a/src/udev/udev-node.h +++ b/src/udev/udev-node.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int udev_node_apply_permissions( sd_device *dev, diff --git a/src/udev/udev-trace.h b/src/udev/udev-trace.h index a8ec6dabe9..10d1e27345 100644 --- a/src/udev/udev-trace.h +++ b/src/udev/udev-trace.h @@ -8,7 +8,7 @@ #include "device-private.h" #include "device-util.h" #include "errno-util.h" -#include "forward.h" +#include "shared-forward.h" /* Each trace point can have different number of additional arguments. Note that when the macro is used only * additional arguments are listed in the macro invocation! diff --git a/src/udev/udevadm-util.h b/src/udev/udevadm-util.h index 906479825c..af6b51519f 100644 --- a/src/udev/udevadm-util.h +++ b/src/udev/udevadm-util.h @@ -3,7 +3,7 @@ #include "sd-device.h" -#include "forward.h" +#include "shared-forward.h" #include "udev-def.h" int find_device(const char *id, const char *prefix, sd_device **ret); diff --git a/src/udev/udevadm.h b/src/udev/udevadm.h index 58c57fee10..f75fbb416f 100644 --- a/src/udev/udevadm.h +++ b/src/udev/udevadm.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" int cat_main(int argc, char *argv[], void *userdata); int info_main(int argc, char *argv[], void *userdata); diff --git a/src/userdb/userdbd-manager.h b/src/userdb/userdbd-manager.h index 40ff0ed121..717c10d17d 100644 --- a/src/userdb/userdbd-manager.h +++ b/src/userdb/userdbd-manager.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #include "ratelimit.h" #define USERDB_WORKERS_MIN 3 diff --git a/src/vmspawn/vmspawn-mount.h b/src/vmspawn/vmspawn-mount.h index 531288a9ed..9221519018 100644 --- a/src/vmspawn/vmspawn-mount.h +++ b/src/vmspawn/vmspawn-mount.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct RuntimeMount { bool read_only; diff --git a/src/vmspawn/vmspawn-register.h b/src/vmspawn/vmspawn-register.h index 2adfabdc03..c55adcf48d 100644 --- a/src/vmspawn/vmspawn-register.h +++ b/src/vmspawn/vmspawn-register.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ -#include "forward.h" +#include "shared-forward.h" int register_machine( sd_bus *bus, diff --git a/src/vmspawn/vmspawn-scope.h b/src/vmspawn/vmspawn-scope.h index 00e73566c3..dea8ede30c 100644 --- a/src/vmspawn/vmspawn-scope.h +++ b/src/vmspawn/vmspawn-scope.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct SocketServicePair { char **exec_start_pre; diff --git a/src/vmspawn/vmspawn-settings.h b/src/vmspawn/vmspawn-settings.h index 1267dd0701..072102eeec 100644 --- a/src/vmspawn/vmspawn-settings.h +++ b/src/vmspawn/vmspawn-settings.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef enum ConsoleMode { CONSOLE_INTERACTIVE, /* ptyfwd */ diff --git a/src/vmspawn/vmspawn-util.h b/src/vmspawn/vmspawn-util.h index a1aa811aaf..d68000ee6b 100644 --- a/src/vmspawn/vmspawn-util.h +++ b/src/vmspawn/vmspawn-util.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" #if defined(__x86_64__) || defined(__i386__) || defined(__arm__) || defined(__aarch64__) # define ARCHITECTURE_SUPPORTS_SMBIOS 1 diff --git a/src/xdg-autostart-generator/xdg-autostart-service.h b/src/xdg-autostart-generator/xdg-autostart-service.h index 83a692f708..f6eff9f44a 100644 --- a/src/xdg-autostart-generator/xdg-autostart-service.h +++ b/src/xdg-autostart-generator/xdg-autostart-service.h @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once -#include "forward.h" +#include "shared-forward.h" typedef struct XdgAutostartService { char *name;