Sophie

Sophie

distrib > Fedora > 13 > x86_64 > media > os-src > by-pkgid > 5c591e2043552ed7330127454ac99bc9 > files > 3

emacs-goodies-31.4-1.fc13.src.rpm

%global pkg emacs-goodies
%global pkgname Emacs-goodies
%global goodies_dir %{buildroot}%{emacs_lispdir}/goodies/
%global gnus_dir %{buildroot}%{emacs_lispdir}/gnus-bonus/
%global installinfo /sbin/install-info

%if %($(pkg-config emacs) ; echo $?)
%global emacs_version 21.1
%global emacs_lispdir %{_datadir}/emacs/site-lisp
%global emacs_startdir %{_datadir}/emacs/site-lisp/site-start.d
%else
%global emacs_version %(pkg-config emacs --modversion)
%global emacs_lispdir %(pkg-config emacs --variable sitepkglispdir)
%global emacs_startdir %(pkg-config emacs --variable sitestartdir)
%endif


Name:		%{pkg}
Version:	31.4
Release:	1%{?dist}
Summary:	Miscellaneous add-ons for Emacs

Group:		Applications/Editors
License:	GPLv2+ and GPLv3
URL:		http://packages.debian.org/sid/lisp/emacs-goodies-el
Source0:	http://ftp.de.debian.org/debian/pool/main/e/emacs-goodies-el/emacs-goodies-el_31.4.tar.gz
Source1:	gnus-bonus-init.el
#Patch which adjusts debian specific information to fedora in texi file
Patch0:		emacs-goodies-el.texi.patch
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:	noarch
BuildRequires:	emacs emacs-el texinfo
Requires:	emacs(bin) >= %{emacs_version}
		
%description
This is %{pkgname} %{version}, provides add-ons for GNU Emacs and gnus.

%package el
Summary:	Elisp source files for %{pkgname}
Group:		Applications/Editors
Requires:	%{name} = %{version}-%{release}

%description el
This package contains the elisp source files for 
use with %{pkgname}.

%prep
%setup -q -n %{pkg}-el-%{version}
%patch0 -p1 -b .fix
%{__cp} debian/patches/* .
while read -r line
do
	patch -p1 <$line.dpatch
done < 00list
%{__rm} -rf elisp/debian-el/
%{__rm} -rf elisp/dpkg-dev-el/
%{__rm} -rf elisp/devscripts-el/

%build
%{__mkdir} -p elisp/%{pkg}-el/info
cd elisp/%{pkg}-el/
%{__chmod} +x %{pkg}-loaddefs.make
./%{pkg}-loaddefs.make
emacs --no-site-file --batch --eval '(progn (setq load-path (cons "." load-path)))' -f batch-byte-compile *.el
makeinfo emacs-goodies-el.texi
iconv -f iso8859-1 -t utf-8 info/emacs-goodies > info/emacs-goodies.utf
%{__mv} info/emacs-goodies.utf info/emacs-goodies
cd ../gnus-bonus-el/
emacs --no-site-file --batch --eval '(progn (setq load-path (cons "." load-path)))' -f batch-byte-compile *.el

%install
rm -rf %{buildroot}
%{__install} -pm 755 -d %{goodies_dir}
%{__install} -pm 755 -d %{buildroot}%{emacs_startdir}
%{__install} -pm 644 elisp/%{pkg}-el/%{pkg}-loaddefs.el %{buildroot}%{emacs_startdir}
%{__install} -pm 644 elisp/%{pkg}-el/*.elc %{goodies_dir}
%{__install} -pm 644 elisp/%{pkg}-el/*.el %{goodies_dir}
%{__install} -pm 755 -d %{gnus_dir}
%{__install} -pm 644 elisp/gnus-bonus-el/*.elc %{gnus_dir}
%{__install} -pm 644 elisp/gnus-bonus-el/*.el %{gnus_dir}
%{__install} -pm 644 %{SOURCE1} %{buildroot}%{emacs_startdir}
%{__install} -pm 755 -d %{buildroot}%{_infodir}/
%{__install} -pm 644 elisp/%{pkg}-el/info/%{pkg} %{buildroot}%{_infodir}/

%clean
%{__rm} -rf %{buildroot}


%post
%{installinfo} %{_infodir}/%{pkg} %{_infodir}/dir


%preun
if [ "$1" = 0 ]; then
    %{installinfo} --delete %{_infodir}/%{pkg} %{_infodir}/dir
fi


%files
%defattr(-,root,root,-)
%{emacs_lispdir}/goodies/*.elc
%{emacs_startdir}/emacs-goodies-loaddefs.el
%{emacs_startdir}/gnus-bonus-init.el
%{emacs_lispdir}/gnus-bonus/*.elc
%{_infodir}/%{pkg}.gz
%dir %{emacs_lispdir}/goodies
%dir %{emacs_lispdir}/gnus-bonus

%files el
%defattr(-,root,root,-)
%doc COPYING-GPL-v2 COPYING-GPL-v3
%{emacs_lispdir}/goodies/*.el
%{emacs_lispdir}/gnus-bonus/*.el

%changelog
* Wed Jan 13 2010 Arun SAG  <sagarun [AT] gmail dot com> - 31.4-1
- Removed patch1 as it is integrated into source by the upstream
- Made gnus to be autoloaded using source1
- Updated to version  31.4

* Wed Dec 16 2009 Arun SAG <sagarun [AT] gmail dot com> - 31.2-3
- License adjusted to GPLv2+ and GPLv3

* Mon Dec 14 2009 Arun SAG <sagarun [AT] gmail dot com> - 31.2-2
- Comment on  patches added

* Fri Dec 4 2009 Arun SAG <sagarun [AT] gmail dot com> - 31.2-1
- Updated to version 31.2-1

* Thu Nov 26 2009 Arun SAG <sagarun [AT] gmail dot com> - 31.1-1
- Updated to version 31.1-1

* Sun Nov 15 2009 Arun SAG <sagarun [AT] gmail dot com> - 30.11-1
- Updated to version 30.11-1

* Fri Oct 30 2009 Arun SAG <sagarun [AT] gmail dot com> - 30.8-2
- Upstream patches are applied

* Thu Oct 22 2009 Arun SAG <sagarun [AT] gmail dot com> - 30.8-1
- Updated to 30.8-1
- License corrected to GPLv2+

* Tue Sep 15 2009 Arun SAG <sagarun [AT] gmail dot com> - 30.5-1
- Initial release 30.5-1