host-libcap \
host-gperf
+HOST_SYSTEMD_NINJA_ENV = DESTDIR=$(HOST_DIR)
+
# Fix RPATH After installation
# * systemd provides a install_rpath instruction to meson because the binaries
# need to link with libsystemd which is not in a standard path
# * the original path had been tweaked by buildroot via LDFLAGS to add
# $(HOST_DIR)/lib
# * thus re-tweak rpath after the installation for all binaries that need it
-HOST_SYSTEMD_HOST_TOOLS = \
- systemd-analyze \
- systemd-machine-id-setup \
- systemd-mount \
- systemd-nspawn \
- systemctl \
- udevadm
-
-HOST_SYSTEMD_NINJA_ENV = DESTDIR=$(HOST_DIR)
+HOST_SYSTEMD_HOST_TOOLS = busctl journalctl systemctl systemd-* udevadm
define HOST_SYSTEMD_FIX_RPATH
- $(foreach f,$(HOST_SYSTEMD_HOST_TOOLS), \
- $(HOST_DIR)/bin/patchelf --set-rpath $(HOST_DIR)/lib:$(HOST_DIR)/lib/systemd $(HOST_DIR)/bin/$(f)
- )
+ for f in $(addprefix $(HOST_DIR)/bin/,$(HOST_SYSTEMD_HOST_TOOLS)); do \
+ [ -e $$f ] || continue; \
+ $(HOST_DIR)/bin/patchelf --set-rpath $(HOST_DIR)/lib:$(HOST_DIR)/lib/systemd $${f} \
+ || exit 1; \
+ done
endef
HOST_SYSTEMD_POST_INSTALL_HOOKS += HOST_SYSTEMD_FIX_RPATH