Adding the post-install and pre-uninstall rules for the Info document,

plus some tweaks.  (Patch was tested by Kamil Dudka.)


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@5240 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
Benno Schulenberg 2015-06-04 18:05:27 +00:00
parent a1c4da8b04
commit 0424243e3c
2 changed files with 19 additions and 5 deletions

View File

@ -1,5 +1,7 @@
2015-06-04 Benno Schulenberg <bensberg@justemail.net> 2015-06-04 Benno Schulenberg <bensberg@justemail.net>
* src/nano.h: Fix compilation with --enable-tiny. * src/nano.h: Fix compilation with --enable-tiny.
* nano.spec.in: Add the post-install and pre-uninstall rules for the
Info document, plus some tweaks. (Patch was tested by Kamil Dudka.)
2015-06-02 Benno Schulenberg <bensberg@justemail.net> 2015-06-02 Benno Schulenberg <bensberg@justemail.net>
* doc/man/nanorc.5, doc/texinfo/nano.texi: Tweak some wordings, and * doc/man/nanorc.5, doc/texinfo/nano.texi: Tweak some wordings, and

View File

@ -2,20 +2,24 @@
%define version @VERSION@ %define version @VERSION@
%define release 1 %define release 1
Summary : Pico editor clone with enhancements
Name : %{name} Name : %{name}
Version : %{version} Version : %{version}
Release : %{release} Release : %{release}
Summary : a user-friendly editor, a Pico clone with enhancements
License : GPLv3+ License : GPLv3+
Group : Applications/Editors Group : Applications/Editors
URL : http://www.nano-editor.org/ URL : http://www.nano-editor.org/
Source : http://www.nano-editor.org/dist/v2.3/%{name}-%{version}.tar.gz Source : http://www.nano-editor.org/dist/v2.4/%{name}-%{version}.tar.gz
BuildRoot : %{_tmppath}/%{name}-%{version}-root BuildRoot : %{_tmppath}/%{name}-%{version}-root
BuildRequires : autoconf, automake, gettext-devel, ncurses-devel, texinfo BuildRequires : autoconf, automake, gettext-devel, ncurses-devel, texinfo
Requires(post) : info
Requires(preun) : info
%description %description
GNU nano is a small and friendly text editor. It aims to emulate the GNU nano is a small and friendly text editor. It aims to emulate the
Pico text editor while also offering a few enhancements. Pico text editor while also offering several enhancements.
%prep %prep
%setup -q %setup -q
@ -26,8 +30,16 @@ make
%install %install
make DESTDIR="%{buildroot}" install make DESTDIR="%{buildroot}" install
#ln -s nano %{buildroot}%{_bindir}/pico #ln -s nano %{buildroot}/%{_bindir}/pico
rm -f %{buildroot}%{_infodir}/dir rm -f %{buildroot}/%{_infodir}/dir
%post
/sbin/install-info %{_infodir}/%{name}.info %{_infodir}/dir || :
%preun
if [ $1 = 0 ] ; then
/sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir || :
fi
%files %files
%defattr(-,root,root) %defattr(-,root,root)