Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/mksh.git#5be3ff8a31e083af1d995ae236340405ae46118e
This commit is contained in:
DistroBaker 2021-02-02 23:37:27 +00:00
parent 3496a93afa
commit 15eae25f85

View File

@ -1,25 +1,19 @@
%if 0%{?fedora} < 17 && 0%{?rhel} < 7
%global _bindir /bin
%endif
Summary: MirBSD enhanced version of the Korn Shell
Name: mksh
Version: 59c
Release: 1%{?dist}
Release: 2%{?dist}
# BSD (setmode.c), ISC (strlcpy.c), MirOS (the rest)
License: MirOS and ISC and BSD
URL: https://www.mirbsd.org/mksh.htm
Source0: https://www.mirbsd.org/MirOS/dist/mir/%{name}/%{name}-R%{version}.tgz
Source1: dot-mkshrc
Source2: rtchecks.expected
%if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
Conflicts: filesystem < 3
Provides: /bin/ksh
Provides: /bin/lksh
Provides: /bin/mksh
Provides: /bin/rlksh
Provides: /bin/rmksh
%endif
Requires(post): grep
Requires(post): %{_sbindir}/alternatives
Requires(preun): %{_sbindir}/alternatives
@ -114,10 +108,8 @@ do
done
%post
%if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
grep -q "^/bin/%{name}$" %{_sysconfdir}/shells 2>/dev/null || \
echo "/bin/%{name}" >> %{_sysconfdir}/shells
%endif
grep -q "^%{_bindir}/%{name}$" %{_sysconfdir}/shells 2>/dev/null || \
echo "%{_bindir}/%{name}" >> %{_sysconfdir}/shells
@ -131,9 +123,7 @@ fi
%postun
if [ ! -x %{_bindir}/%{name} ]; then
%if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
sed -e 's@^/bin/%{name}$@POSTUNREMOVE@' -e '/^POSTUNREMOVE$/d' -i %{_sysconfdir}/shells
%endif
sed -e 's@^%{_bindir}/%{name}$@POSTUNREMOVE@' -e '/^POSTUNREMOVE$/d' -i %{_sysconfdir}/shells
fi
@ -153,6 +143,9 @@ fi
%{_mandir}/man1/rmksh.1*
%changelog
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 59c-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Mon Nov 02 2020 Robert Scheck <robert@fedoraproject.org> 59c-1
- Upgrade to 59c (#1893414)
- Add alternatives switching for ksh (#1879002)