diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2021-05-16 16:45:51 +0200 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2021-05-19 03:25:26 +0200 |
commit | d0f8006993deb976071ccdef823c61bdd1b9bbfe (patch) | |
tree | 4dbc4221889d26cc3b14891bc42011596fc61ff7 /src/rpm | |
parent | meson: use jinja2 in src/timesync/ (diff) | |
download | systemd-d0f8006993deb976071ccdef823c61bdd1b9bbfe.tar.xz systemd-d0f8006993deb976071ccdef823c61bdd1b9bbfe.zip |
rpm: use %_bindir not @bindir@
We were using both in various places. To keep things simple, let
rpm do the substitution.
Diffstat (limited to 'src/rpm')
-rw-r--r-- | src/rpm/macros.systemd.in | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/rpm/macros.systemd.in b/src/rpm/macros.systemd.in index 244c274d29..0d27c1703a 100644 --- a/src/rpm/macros.systemd.in +++ b/src/rpm/macros.systemd.in @@ -46,9 +46,9 @@ OrderWithRequires(postun): systemd \ %systemd_post() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# systemd_post}} \ -if [ $1 -eq 1 ] && [ -x @bindir@/systemctl ]; then \ +if [ $1 -eq 1 ] && [ -x %{_bindir}/systemctl ]; then \ # Initial installation \ - @bindir@/systemctl --no-reload preset %{?*} || : \ + %{_bindir}/systemctl --no-reload preset %{?*} || : \ fi \ %{nil} @@ -56,21 +56,21 @@ fi \ %systemd_preun() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# systemd_preun}} \ -if [ $1 -eq 0 ] && [ -x @bindir@/systemctl ]; then \ +if [ $1 -eq 0 ] && [ -x %{_bindir}/systemctl ]; then \ # Package removal, not upgrade \ if [ -d /run/systemd/system ]; then \ - @bindir@/systemctl --no-reload disable --now %{?*} || : \ + %{_bindir}/systemctl --no-reload disable --now %{?*} || : \ else \ - @bindir@/systemctl --no-reload disable %{?*} || : \ + %{_bindir}/systemctl --no-reload disable %{?*} || : \ fi \ fi \ %{nil} %systemd_user_preun() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# systemd_user_preun}} \ -if [ $1 -eq 0 ] && [ -x @bindir@/systemctl ]; then \ +if [ $1 -eq 0 ] && [ -x %{_bindir}/systemctl ]; then \ # Package removal, not upgrade \ - @bindir@/systemctl --global disable %{?*} || : \ + %{_bindir}/systemctl --global disable %{?*} || : \ fi \ %{nil} @@ -84,10 +84,10 @@ fi \ %systemd_postun_with_restart() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# systemd_postun_with_restart}} \ -if [ $1 -ge 1 ] && [ -x @bindir@/systemctl ]; then \ +if [ $1 -ge 1 ] && [ -x %{_bindir}/systemctl ]; then \ # Package upgrade, not uninstall \ for unit in %{?*}; do \ - @bindir@/systemctl set-property $unit Markers=+needs-restart || : \ + %{_bindir}/systemctl set-property $unit Markers=+needs-restart || : \ done \ fi \ %{nil} @@ -105,17 +105,17 @@ fi \ # Deprecated. Use %tmpfiles_create_package instead %tmpfiles_create() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# tmpfiles_create}} \ -[ -x @bindir@/systemd-tmpfiles ] && @bindir@/systemd-tmpfiles --create %{?*} || : \ +[ -x %{_bindir}/systemd-tmpfiles ] && %{_bindir}/systemd-tmpfiles --create %{?*} || : \ %{nil} # Deprecated. Use %sysusers_create_package instead %sysusers_create() \ %{expand:%%{?__systemd_someargs_%#:%%__systemd_someargs_%# sysusers_create}} \ -[ -x @bindir@/systemd-sysusers ] && @bindir@/systemd-sysusers %{?*} || : \ +[ -x %{_bindir}/systemd-sysusers ] && %{_bindir}/systemd-sysusers %{?*} || : \ %{nil} %sysusers_create_inline() \ -[ -x @bindir@/systemd-sysusers ] && @bindir@/systemd-sysusers - <<SYSTEMD_INLINE_EOF || : \ +[ -x %{_bindir}/systemd-sysusers ] && %{_bindir}/systemd-sysusers - <<SYSTEMD_INLINE_EOF || : \ %{?*} \ SYSTEMD_INLINE_EOF\ %{nil} |