From: Jan Engelhardt Date: Fri, 8 Feb 2019 14:35:55 +0000 (+0100) Subject: rpm: use sh compatible redirects X-Git-Tag: v241~20 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a6fe3b48941cebcb64a691db162ef2b9148bbccb;p=thirdparty%2Fsystemd.git rpm: use sh compatible redirects &> is bash-specific. Switch to something that will work with dash and pbosh. --- diff --git a/src/core/macros.systemd.in b/src/core/macros.systemd.in index 9ccad5ebfe8..d9e7f573ba2 100644 --- a/src/core/macros.systemd.in +++ b/src/core/macros.systemd.in @@ -43,7 +43,7 @@ OrderWithRequires(postun): systemd \ %systemd_post() \ if [ $1 -eq 1 ] ; then \ # Initial installation \ - systemctl --no-reload preset %{?*} &>/dev/null || : \ + systemctl --no-reload preset %{?*} >/dev/null 2>&1 || : \ fi \ %{nil} @@ -52,14 +52,14 @@ fi \ %systemd_preun() \ if [ $1 -eq 0 ] ; then \ # Package removal, not upgrade \ - systemctl --no-reload disable --now %{?*} &>/dev/null || : \ + systemctl --no-reload disable --now %{?*} >/dev/null 2>&1 || : \ fi \ %{nil} %systemd_user_preun() \ if [ $1 -eq 0 ] ; then \ # Package removal, not upgrade \ - systemctl --global disable %{?*} &>/dev/null || : \ + systemctl --global disable %{?*} >/dev/null 2>&1 || : \ fi \ %{nil} @@ -70,7 +70,7 @@ fi \ %systemd_postun_with_restart() \ if [ $1 -ge 1 ] ; then \ # Package upgrade, not uninstall \ - systemctl try-restart %{?*} &>/dev/null || : \ + systemctl try-restart %{?*} >/dev/null 2>&1 || : \ fi \ %{nil} @@ -84,16 +84,16 @@ fi \ # Deprecated. Use %tmpfiles_create_package instead %tmpfiles_create() \ -systemd-tmpfiles --create %{?*} &>/dev/null || : \ +systemd-tmpfiles --create %{?*} >/dev/null 2>&1 || : \ %{nil} # Deprecated. Use %sysusers_create_package instead %sysusers_create() \ -systemd-sysusers %{?*} &>/dev/null || : \ +systemd-sysusers %{?*} >/dev/null 2>&1 || : \ %{nil} %sysusers_create_inline() \ -systemd-sysusers - </dev/null || : \ +systemd-sysusers - </dev/null 2>&1 || : \ %{?*} \ SYSTEMD_INLINE_EOF \ %{nil} @@ -112,7 +112,7 @@ SYSTEMD_INLINE_EOF \ # %files # %{_sysusersdir}/%{name}.conf %sysusers_create_package() \ -systemd-sysusers --replace=%_sysusersdir/%1.conf - </dev/null || : \ +systemd-sysusers --replace=%_sysusersdir/%1.conf - </dev/null 2>&1 || : \ %(cat %2) \ SYSTEMD_INLINE_EOF \ %{nil} @@ -131,15 +131,15 @@ SYSTEMD_INLINE_EOF \ # %files # %{_tmpfilesdir}/%{name}.conf %tmpfiles_create_package() \ -systemd-tmpfiles --replace=%_tmpfilesdir/%1.conf --create - </dev/null || : \ +systemd-tmpfiles --replace=%_tmpfilesdir/%1.conf --create - </dev/null 2>&1 || : \ %(cat %2) \ SYSTEMD_INLINE_EOF \ %{nil} %sysctl_apply() \ -@rootlibexecdir@/systemd-sysctl %{?*} &>/dev/null || : \ +@rootlibexecdir@/systemd-sysctl %{?*} >/dev/null 2>&1 || : \ %{nil} %binfmt_apply() \ -@rootlibexecdir@/systemd-binfmt %{?*} &>/dev/null || : \ +@rootlibexecdir@/systemd-binfmt %{?*} >/dev/null 2>&1 || : \ %{nil}