diff --git a/files.systemd b/files.systemd index 8be3d610..56241dc4 100644 --- a/files.systemd +++ b/files.systemd @@ -380,8 +380,10 @@ %{_mandir}/man8/systemd-tmpfiles.8.gz %{_mandir}/man8/systemd-update-done.8.gz %{_mandir}/man8/systemd-update-done.service.8.gz +%if %{with utmp} %{_mandir}/man8/systemd-update-utmp.8.gz %{_mandir}/man8/systemd-update-utmp.service.8.gz +%endif %{_mandir}/man8/systemd-user-sessions.8.gz %{_mandir}/man8/systemd-user-sessions.service.8.gz %{_mandir}/man8/systemd-userdbd.8.gz @@ -420,7 +422,9 @@ %{_systemd_util_dir}/systemd-timedated %{_systemd_util_dir}/systemd-update-done %{_systemd_util_dir}/systemd-update-helper +%if %{with utmp} %{_systemd_util_dir}/systemd-update-utmp +%endif %{_systemd_util_dir}/systemd-user-runtime-dir %{_systemd_util_dir}/systemd-user-sessions %if %{without bootstrap} @@ -566,7 +570,9 @@ %{_unitdir}/sysinit.target.wants/systemd-sysusers.service %{_unitdir}/sysinit.target.wants/systemd-tmpfiles-setup.service %{_unitdir}/sysinit.target.wants/systemd-update-done.service +%if %{with utmp} %{_unitdir}/sysinit.target.wants/systemd-update-utmp.service +%endif %{_unitdir}/syslog.socket %{_unitdir}/system-update-cleanup.service %{_unitdir}/system-update-pre.target @@ -605,7 +611,9 @@ %{_unitdir}/systemd-tmpfiles-clean.timer %{_unitdir}/systemd-tmpfiles-setup.service %{_unitdir}/systemd-update-done.service +%if %{with utmp} %{_unitdir}/systemd-update-utmp.service +%endif %{_unitdir}/systemd-user-sessions.service %if %{without bootstrap} %{_unitdir}/systemd-userdbd.service diff --git a/files.sysvcompat b/files.sysvcompat index 6ce72cf6..70277b64 100644 --- a/files.sysvcompat +++ b/files.sysvcompat @@ -13,7 +13,9 @@ %{_mandir}/man8/systemd-initctl.socket.8.gz %{_mandir}/man8/systemd-rc-local-generator.8.gz %{_mandir}/man8/systemd-sysv-generator.8.gz +%if %{with utmp} %{_mandir}/man8/systemd-update-utmp-runlevel.service.8.gz +%endif %{_mandir}/man8/telinit.8.gz %{_sbindir}/runlevel %{_sbindir}/telinit @@ -21,10 +23,14 @@ %{_systemd_util_dir}/systemd-sysv-install %{_systemdgeneratordir}/systemd-rc-local-generator %{_systemdgeneratordir}/systemd-sysv-generator +%if %{with utmp} %{_unitdir}/graphical.target.wants/systemd-update-utmp-runlevel.service %{_unitdir}/multi-user.target.wants/systemd-update-utmp-runlevel.service +%endif %{_unitdir}/rc-local.service +%if %{with utmp} %{_unitdir}/rescue.target.wants/systemd-update-utmp-runlevel.service +%endif %{_unitdir}/runlevel0.target %{_unitdir}/runlevel1.target %{_unitdir}/runlevel2.target @@ -35,7 +41,9 @@ %{_unitdir}/sockets.target.wants/systemd-initctl.socket %{_unitdir}/systemd-initctl.service %{_unitdir}/systemd-initctl.socket +%if %{with utmp} %{_unitdir}/systemd-update-utmp-runlevel.service +%endif %if %{with split_usr} /sbin/runlevel /sbin/telinit diff --git a/systemd.changes b/systemd.changes index 5af909d7..2d614e26 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Aug 24 11:32:52 UTC 2023 - Thorsten Kukuk + +- Make utmp support per project configureable [jsc#PED-3144] +- Make apparmor and selinux per project configureable [jsc#PED-2736] + ------------------------------------------------------------------- Thu Aug 24 10:42:20 UTC 2023 - Franck Bui diff --git a/systemd.spec b/systemd.spec index b96bd85b..a0155b79 100644 --- a/systemd.spec +++ b/systemd.spec @@ -39,6 +39,7 @@ %global with_bootstrap 1 %else %global mini %nil +%bcond_without apparmor %bcond_without coredump %bcond_without homed %bcond_without importd @@ -52,9 +53,11 @@ %else %bcond_with sd_boot %endif +%bcond_without selinux %bcond_without sysvcompat %bcond_without experimental %bcond_without testsuite +%bcond_without utmp %endif # The following features are kept to ease migrations toward SLE. Their default @@ -74,7 +77,9 @@ BuildRequires: bpftool BuildRequires: clang BuildRequires: docbook-xsl-stylesheets BuildRequires: kbd +%if %{with apparmor} BuildRequires: libapparmor-devel +%endif BuildRequires: libgcrypt-devel BuildRequires: libxslt-tools BuildRequires: polkit @@ -90,7 +95,9 @@ BuildRequires: pkgconfig(liblzma) BuildRequires: pkgconfig(libpcre2-8) BuildRequires: pkgconfig(libqrencode) BuildRequires: pkgconfig(libseccomp) >= 2.3.1 +%if %{with selinux} BuildRequires: pkgconfig(libselinux) >= 2.1.9 +%endif BuildRequires: pkgconfig(libzstd) %endif BuildRequires: fdupes @@ -557,9 +564,11 @@ Recommends: tpm2.0-tools %if %{with resolved} # Optional dep for knot needed by TEST-75-RESOLVED Recommends: knot +%if %{with selinux} # Optional deps needed by TEST-06-SELINUX (otherwise skipped) Recommends: selinux-policy-devel Recommends: selinux-policy-targeted +%endif # The following deps on libs are for test-dlopen-so whereas the pkgconfig ones # are used by test-funtions to find the libs on the host and install them in the # image, see install_missing_libraries() for details. @@ -703,6 +712,7 @@ export CFLAGS="%{optflags} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" -Dclock-valid-range-usec-max=946728000000000 \ -Dadm-group=false \ -Dwheel-group=false \ + -Dutmp=%{when utmp} \ -Ddefault-hierarchy=unified \ -Ddefault-kill-user-processes=false \ -Dpamconfdir=no \ @@ -729,7 +739,7 @@ export CFLAGS="%{optflags} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" \ -Dpstore=true \ \ - -Dapparmor=%{when_not bootstrap} \ + -Dapparmor=%{when apparmor} \ -Dbpf-framework=%{when_not bootstrap} \ -Defi=%{when_not bootstrap} \ -Delfutils=%{when_not bootstrap} \ @@ -741,7 +751,7 @@ export CFLAGS="%{optflags} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2" -Dnss-myhostname=%{when_not bootstrap} \ -Dnss-systemd=%{when_not bootstrap} \ -Dseccomp=%{when_not bootstrap} \ - -Dselinux=%{when_not bootstrap} \ + -Dselinux=%{when selinux} \ -Dtpm=%{when_not bootstrap} \ -Dtpm2=%{when_not bootstrap} \ -Dtranslations=%{when_not bootstrap} \