From 397c17e983607b2b7b42d42b7204c4635b50fbdb66069fdb2a592c15088c8a01 Mon Sep 17 00:00:00 2001 From: Franck Bui Date: Thu, 11 Jun 2020 08:53:53 +0000 Subject: [PATCH] Accepting request 813288 from home:fbui:systemd:openSUSE-Factory - Fix build when resolved is disabled While at it sort the build conditionals. OBS-URL: https://build.opensuse.org/request/show/813288 OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=1101 --- systemd-mini.changes | 7 +++++++ systemd-mini.spec | 41 ++++++++++++++++++++++------------------- systemd.changes | 7 +++++++ systemd.spec | 41 ++++++++++++++++++++++------------------- 4 files changed, 58 insertions(+), 38 deletions(-) diff --git a/systemd-mini.changes b/systemd-mini.changes index c85941eb..a0694e21 100644 --- a/systemd-mini.changes +++ b/systemd-mini.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri May 29 14:32:41 UTC 2020 - Franck Bui + +- Fix build when resolved is disabled + + While at it sort the build conditionals. + ------------------------------------------------------------------- Thu May 28 09:30:33 UTC 2020 - Franck Bui diff --git a/systemd-mini.spec b/systemd-mini.spec index 5f5aca7f..71c1af45 100644 --- a/systemd-mini.spec +++ b/systemd-mini.spec @@ -31,25 +31,25 @@ %bcond_with gnuefi %if 0%{?bootstrap} %bcond_with coredump -%bcond_with sysvcompat -%bcond_with machined %bcond_with importd +%bcond_with journal_remote +%bcond_with machined %bcond_with networkd %bcond_with portabled %bcond_with resolved -%bcond_with journal_remote +%bcond_with sysvcompat %else %bcond_without coredump -%bcond_without sysvcompat -%bcond_without machined -%bcond_without importd -%bcond_without networkd -%bcond_without portabled -%bcond_without resolved -%bcond_without journal_remote %ifarch %{ix86} x86_64 %bcond_without gnuefi %endif +%bcond_without importd +%bcond_without journal_remote +%bcond_without machined +%bcond_without networkd +%bcond_without portabled +%bcond_without resolved +%bcond_without sysvcompat %endif %bcond_with parentpathid @@ -861,15 +861,18 @@ fi # This includes all hacks needed when upgrading from SysV. %{_prefix}/lib/systemd/scripts/upgrade-from-pre-210.sh || : -# Migrate i18n settings that could be previously configured in -# /etc/sysconfig but now is defined only in the systemd official -# places (/etc/locale.conf, /etc/vconsole.conf, etc...). This is done -# only once usually during package updates but might be also needed -# during installations when we upgrade from a distro using SysV init. -test -e %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done || { +# Migrate old i18n settings previously configured in /etc/sysconfig to +# the new locations used by systemd (/etc/locale.conf, +# /etc/vconsole.conf, ...). Recent version of systemd parse the new +# locations only. +# +# This is needed both at package updates and package installations +# because we might be upgrading from a system which was running SysV +# init (systemd package is being installed). +if ! test -e %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done; then %{_prefix}/lib/systemd/scripts/migrate-sysconfig-i18n.sh && touch %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done || : -} +fi %postun %systemd_postun @@ -1569,8 +1572,6 @@ fi %{_unitdir}/systemd-networkd.service %{_unitdir}/systemd-networkd.socket %{_unitdir}/systemd-networkd-wait-online.service -%{_prefix}/lib/systemd/systemd-resolved -%{_unitdir}/systemd-resolved.service %endif %if %{with resolved} %{_bindir}/resolvectl @@ -1580,6 +1581,8 @@ fi %{_datadir}/dbus-1/system-services/org.freedesktop.resolve1.service %{_datadir}/polkit-1/actions/org.freedesktop.resolve1.policy %{_prefix}/lib/systemd/resolv.conf +%{_prefix}/lib/systemd/systemd-resolved +%{_unitdir}/systemd-resolved.service %endif %endif diff --git a/systemd.changes b/systemd.changes index c85941eb..a0694e21 100644 --- a/systemd.changes +++ b/systemd.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri May 29 14:32:41 UTC 2020 - Franck Bui + +- Fix build when resolved is disabled + + While at it sort the build conditionals. + ------------------------------------------------------------------- Thu May 28 09:30:33 UTC 2020 - Franck Bui diff --git a/systemd.spec b/systemd.spec index 0e2921e5..3f937fcf 100644 --- a/systemd.spec +++ b/systemd.spec @@ -29,25 +29,25 @@ %bcond_with gnuefi %if 0%{?bootstrap} %bcond_with coredump -%bcond_with sysvcompat -%bcond_with machined %bcond_with importd +%bcond_with journal_remote +%bcond_with machined %bcond_with networkd %bcond_with portabled %bcond_with resolved -%bcond_with journal_remote +%bcond_with sysvcompat %else %bcond_without coredump -%bcond_without sysvcompat -%bcond_without machined -%bcond_without importd -%bcond_without networkd -%bcond_without portabled -%bcond_without resolved -%bcond_without journal_remote %ifarch %{ix86} x86_64 %bcond_without gnuefi %endif +%bcond_without importd +%bcond_without journal_remote +%bcond_without machined +%bcond_without networkd +%bcond_without portabled +%bcond_without resolved +%bcond_without sysvcompat %endif %bcond_with parentpathid @@ -859,15 +859,18 @@ fi # This includes all hacks needed when upgrading from SysV. %{_prefix}/lib/systemd/scripts/upgrade-from-pre-210.sh || : -# Migrate i18n settings that could be previously configured in -# /etc/sysconfig but now is defined only in the systemd official -# places (/etc/locale.conf, /etc/vconsole.conf, etc...). This is done -# only once usually during package updates but might be also needed -# during installations when we upgrade from a distro using SysV init. -test -e %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done || { +# Migrate old i18n settings previously configured in /etc/sysconfig to +# the new locations used by systemd (/etc/locale.conf, +# /etc/vconsole.conf, ...). Recent version of systemd parse the new +# locations only. +# +# This is needed both at package updates and package installations +# because we might be upgrading from a system which was running SysV +# init (systemd package is being installed). +if ! test -e %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done; then %{_prefix}/lib/systemd/scripts/migrate-sysconfig-i18n.sh && touch %{_prefix}/lib/systemd/scripts/.migrate-sysconfig-i18n.sh~done || : -} +fi %postun %systemd_postun @@ -1567,8 +1570,6 @@ fi %{_unitdir}/systemd-networkd.service %{_unitdir}/systemd-networkd.socket %{_unitdir}/systemd-networkd-wait-online.service -%{_prefix}/lib/systemd/systemd-resolved -%{_unitdir}/systemd-resolved.service %endif %if %{with resolved} %{_bindir}/resolvectl @@ -1578,6 +1579,8 @@ fi %{_datadir}/dbus-1/system-services/org.freedesktop.resolve1.service %{_datadir}/polkit-1/actions/org.freedesktop.resolve1.policy %{_prefix}/lib/systemd/resolv.conf +%{_prefix}/lib/systemd/systemd-resolved +%{_unitdir}/systemd-resolved.service %endif %endif