From d44a9379ae80870560c9e7d56b3142d6693784be Mon Sep 17 00:00:00 2001 From: luofeng14 Date: Sun, 4 Feb 2024 02:47:42 +0000 Subject: [PATCH] support clang build Signed-off-by: luofeng14 --- systemd.spec | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/systemd.spec b/systemd.spec index 3b8e12f..3ed2ec5 100644 --- a/systemd.spec +++ b/systemd.spec @@ -25,7 +25,7 @@ Name: systemd Url: https://www.freedesktop.org/wiki/Software/systemd Version: 255 -Release: 6 +Release: 7 License: MIT and LGPLv2+ and GPLv2+ Summary: System and Service Manager @@ -302,7 +302,9 @@ Systemd PAM module registers the session with systemd-logind. %endif %build - +%if "%{?toolchain}" == "clang" + CFLAGS="${CFLAGS:-%{?build_cflags}} -Wno-error=incompatible-pointer-types-discards-qualifiers"; export CFLAGS; +%endif CONFIGURE_OPTS=( -Dsysvinit-path=/etc/rc.d/init.d -Drc-local=/etc/rc.d/rc.local @@ -1635,6 +1637,12 @@ fi %{_libdir}/security/pam_systemd_loadkey.so %changelog +* Mon Mar 18 2024 luofeng - 255-7 +- Type:enhencement +- CVE:NA +- SUG:NA +- DESC:support clang build + * Mon Mar 18 2024 huyubiao - 255-6 - switch systemd back to cgroup v1 to prevent the docker.service startup failure -- Gitee