1
0
forked from pool/alex

- Add man page

- Save HTML data only, not Makfile, etc.
- Add pdf file of documentation

OBS-URL: https://build.opensuse.org/package/show/devel:languages:haskell/alex?expand=0&rev=22
This commit is contained in:
Herbert Graeber 2009-04-17 13:05:50 +00:00 committed by Git OBS Bridge
parent f827981552
commit 23dbfe8ab6

View File

@ -27,6 +27,7 @@ BuildRequires: libxslt
BuildRequires: sgml-skel
BuildRequires: docbook-xsl-stylesheets
BuildRequires: docbook-utils
BuildRequires: fop
BuildRequires: licenses
Prefix: /usr
@ -59,14 +60,20 @@ This is the documentation for Alex, a lexical analyser generator for Haskell.
pushd doc
autoreconf
./configure --prefix=%{_prefix} --libdir=%{_libdir}
make html
make html pdf
popd
%install
rm -rf $RPM_BUILD_ROOT
%cabal_install
mkdir -p %{buildroot}%{_datadir}/doc/%{name}
cp -r doc %{buildroot}%{_datadir}/doc/%{name}
mkdir -p %{buildroot}%{_mandir}/man1
sed '
s|/@VERSION@|%{version}|
s|@DOCDIR@|%{_datadir}/doc/%{name}|
s|@DATADIR@|%{_datadir}/alex|
' < doc/alex.1.in | gzip >%{buildroot}%{_mandir}/man1/%{name}.1.gz
mkdir -p %{buildroot}%{_datadir}/doc/%{name}/html
cp -r doc/%{name} %{buildroot}%{_datadir}/doc/%{name}/html
cp -r doc/%{name}.pdf %{buildroot}%{_datadir}/doc/%{name}
for FILE in LICENSE ; do
MD5SUM=$(md5sum $FILE | sed 's/ .*//')
if test -f /usr/share/doc/licenses/md5/$MD5SUM ; then
@ -75,13 +82,10 @@ for FILE in LICENSE ; do
done
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%doc ANNOUNCE LICENSE README TODO examples
%doc %{_mandir}/man1/%{name}.1.gz
%{_bindir}/%{name}
%{_datadir}/%{name}-%{version}
@ -92,6 +96,11 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Thu Apr 17 2009 Herbert Graeber <herbert@links2linux.de> - 2.3.1
- Add man page
- Save HTML data only, not Makfile, etc.
- Add pdf file of documentation
* Thu Apr 16 2009 Herbert Graeber <herbert@links2linux.de> - 2.3.1
- Fix location of documentation