From b54c350a0771579444bccbc0dc7795d0bd176413 Mon Sep 17 00:00:00 2001 From: "Chandan Kumar (raukadah)" Date: Mon, 16 Dec 2019 16:12:14 +0530 Subject: Use systemd/sd-daemon.h headers for systemd presence Finding systemd devel packages using libsystemd does not work as in RHEL based distro the package name is systemd-devel and for deb/ubunutu it is libsystemd. It is also giving false result when podman rpm is built with systemd but hack/systemd_tag.sh does not return anything. Install systemd-devel package in build_rpm.sh script Moving to systemd/sd-daemon.h header files which comes from devel packages fixes the issue. Signed-off-by: Chandan Kumar (raukadah) --- hack/systemd_tag.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'hack') diff --git a/hack/systemd_tag.sh b/hack/systemd_tag.sh index c59cad559..19a7bf6a6 100755 --- a/hack/systemd_tag.sh +++ b/hack/systemd_tag.sh @@ -1,4 +1,7 @@ #!/usr/bin/env bash -if pkg-config --exists libsystemd; then - echo systemd +cc -E - > /dev/null 2> /dev/null << EOF +#include +EOF +if test $? -eq 0 ; then + echo systemd fi -- cgit v1.2.3-54-g00ecf