Fix upgrades from non-alternativized versions
This commit is contained in:
parent
15ab40e41d
commit
9c9fe94dd0
14
groff.spec
14
groff.spec
@ -3,7 +3,7 @@
|
|||||||
Summary: A document formatting system
|
Summary: A document formatting system
|
||||||
Name: groff
|
Name: groff
|
||||||
Version: 1.22.3
|
Version: 1.22.3
|
||||||
Release: 22%{?dist}
|
Release: 23%{?dist}
|
||||||
License: GPLv3+ and GFDL and BSD and MIT
|
License: GPLv3+ and GFDL and BSD and MIT
|
||||||
URL: http://www.gnu.org/software/groff/
|
URL: http://www.gnu.org/software/groff/
|
||||||
Source: ftp://ftp.gnu.org/gnu/groff/groff-%{version}.tar.gz
|
Source: ftp://ftp.gnu.org/gnu/groff/groff-%{version}.tar.gz
|
||||||
@ -156,6 +156,10 @@ popd
|
|||||||
# /bin/sed moved to /usr/bin/sed in Fedora
|
# /bin/sed moved to /usr/bin/sed in Fedora
|
||||||
sed --in-place 's|#! /bin/sed -f|#! /usr/bin/sed -f|' %{buildroot}%{_datadir}/groff/%{version}/font/devps/generate/symbol.sed
|
sed --in-place 's|#! /bin/sed -f|#! /usr/bin/sed -f|' %{buildroot}%{_datadir}/groff/%{version}/font/devps/generate/symbol.sed
|
||||||
|
|
||||||
|
%pre
|
||||||
|
# remove alternativized files if they are not symlinks
|
||||||
|
[ -L %{_mandir}/man7/roff.7.gz ] || rm -f %{_mandir}/man7/roff.7.gz
|
||||||
|
|
||||||
%post
|
%post
|
||||||
# set up the alternatives files
|
# set up the alternatives files
|
||||||
%{_sbindir}/update-alternatives --install %{_mandir}/man7/roff.7.gz roff.7.gz %{_mandir}/man7/roff.%{name}.7.gz 300 \
|
%{_sbindir}/update-alternatives --install %{_mandir}/man7/roff.7.gz roff.7.gz %{_mandir}/man7/roff.%{name}.7.gz 300 \
|
||||||
@ -173,6 +177,11 @@ if [ $1 -ge 1 ]; then
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
%pre base
|
||||||
|
# remove alternativized files if they are not symlinks
|
||||||
|
[ -L %{_bindir}/soelim ] || rm -f %{_bindir}/soelim
|
||||||
|
[ -L %{_mandir}/man1/soelim.1.gz ] || rm -f %{_mandir}/man1/soelim.1.gz
|
||||||
|
|
||||||
%post base
|
%post base
|
||||||
# set up the alternatives files
|
# set up the alternatives files
|
||||||
%{_sbindir}/update-alternatives --install %{_bindir}/soelim soelim %{_bindir}/soelim.%{name} 300 \
|
%{_sbindir}/update-alternatives --install %{_bindir}/soelim soelim %{_bindir}/soelim.%{name} 300 \
|
||||||
@ -462,6 +471,9 @@ fi
|
|||||||
%doc %{_pkgdocdir}/pdf/
|
%doc %{_pkgdocdir}/pdf/
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Feb 28 2020 Nikola Forró <nforro@redhat.com> - 1.22.3-23
|
||||||
|
- Fix upgrades from non-alternativized versions
|
||||||
|
|
||||||
* Wed Feb 26 2020 Nikola Forró <nforro@redhat.com> - 1.22.3-22
|
* Wed Feb 26 2020 Nikola Forró <nforro@redhat.com> - 1.22.3-22
|
||||||
- Use alternatives for soelim and roff.7
|
- Use alternatives for soelim and roff.7
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user