diff --git a/bash-completion.changes b/bash-completion.changes index 846ed98..a6b0aa9 100644 --- a/bash-completion.changes +++ b/bash-completion.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Dec 15 09:37:52 UTC 2016 - werner@suse.de + +- Detect if the completions for mount/umount have to be removed + for modern util-linux package but without using suse_version + ------------------------------------------------------------------- Thu Dec 15 07:49:36 UTC 2016 - werner@suse.de diff --git a/bash-completion.spec b/bash-completion.spec index 685537c..56c294f 100644 --- a/bash-completion.spec +++ b/bash-completion.spec @@ -59,6 +59,7 @@ BuildRequires: libxslt-tools BuildRequires: pkg-config %if %build_core BuildRequires: cmake +BuildRequires: util-linux Requires: bash %endif BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -132,16 +133,18 @@ rm -vf %{buildroot}%{_datadir}/bash-completion/completions/hexdump rm -vf %{buildroot}%{_datadir}/bash-completion/completions/hwclock rm -vf %{buildroot}%{_datadir}/bash-completion/completions/ionice rm -vf %{buildroot}%{_datadir}/bash-completion/completions/look -%if 0%{?suse_version} <= 1320 -rm -vf %{buildroot}%{_datadir}/bash-completion/completions/mount -%endif +if test -e %{_datadir}/bash-completion/completions/mount +then + rm -vf %{buildroot}%{_datadir}/bash-completion/completions/mount +fi rm -vf %{buildroot}%{_datadir}/bash-completion/completions/newgrp rm -vf %{buildroot}%{_datadir}/bash-completion/completions/renice rm -vf %{buildroot}%{_datadir}/bash-completion/completions/rtcwake rm -vf %{buildroot}%{_datadir}/bash-completion/completions/su -%if 0%{?suse_version} <= 1320 -rm -vf %{buildroot}%{_datadir}/bash-completion/completions/umount -%endif +if test -e %{_datadir}/bash-completion/completions/umount +then + rm -vf %{buildroot}%{_datadir}/bash-completion/completions/umount +fi %endif %build_core %if %build_doc pushd doc