]> git.pld-linux.org Git - SPECS.git/blob - haddock.spec
SPECS updated Sun 1 Aug 20:28:02 CEST 2021
[SPECS.git] / haddock.spec
1 #
2 # Conditional build:
3 %bcond_with     bootstrap       # use foreign (non-rpm) ghc
4 #
5 Summary:        A documentation tool for annotated Haskell source code
6 Summary(pl.UTF-8):      Generator dokumentacji z oznaczonych źródeł w Haskellu
7 Name:           haddock
8 Version:        0.8
9 Release:        5
10 License:        BSD-like w/o adv. clause
11 Group:          Development/Tools
12 Source0:        http://haskell.org/haddock/%{name}-%{version}-src.tar.gz
13 # Source0-md5:  0a1bb64e7642f64d2560dc258c570c1d
14 URL:            http://haskell.org/haddock/
15 BuildRequires:  alex
16 BuildRequires:  autoconf
17 BuildRequires:  docbook-dtd42-xml
18 BuildRequires:  docbook-style-xsl
19 %{!?with_bootstrap:BuildRequires:       ghc >= 6.6}
20 BuildRequires:  gmp-devel
21 BuildRequires:  happy
22 BuildRequires:  libxslt-progs
23 #For generating documentation in PDF: fop or xmltex
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %description
27 Haddock is a tool for automatically generating documentation from
28 annotated Haskell source code. It is primary intended for documenting
29 libraries, but it should be useful for any kind of Haskell code.
30
31 Haddock lets you write documentation annotations next to the
32 definitions of functions and types in the source code, in a syntax
33 that is easy on the eye when writing the source code (no heavyweight
34 mark-up). The documentation generated by Haddock is fully hyperlinked
35 -- click on a type name in a type signature to go straight to the
36 definition, and documentation, for that type.
37
38 Haddock can generate documentation in multiple formats; currently HTML
39 is implemented, and there is partial support for generating DocBook.
40 The generated HTML uses stylesheets, so you need a fairly up-to-date
41 browser to view it properly (Mozilla, Konqueror, Opera, and IE 6
42 should all be ok).
43
44 %description -l pl.UTF-8
45 Haddock to narzędzie do automatycznego generowania dokumentacji z
46 odpowiednio oznaczonych źródeł w Haskellu. Jest przeznaczony przede
47 wszystkim do dokumentowania bibliotek, ale można go użyć do dowolnego
48 kodu w Haskellu.
49
50 Haddock pozwala pisać adnotacje z dokumentacją obok definicji funkcji
51 i typów w kodzie źródłowym, w składni przyjemnej dla oka (bez ciężkich
52 znaczników). Dokumentacja wygenerowana przez Haddock jest w pełni
53 hipertekstowa -- można kliknąć na nazwę typu w sygnaturze typu, żeby
54 przejść prosto do definicji i dokumentacji tego typu.
55
56 Haddock może generować dokumentację w wielu formatach; na razie
57 zaimplementowany jest HTML i jest częściowe wsparcie generowania
58 DocBooka. Wygenerowany HTML używa arkuszy stylów, więc będzie
59 potrzebna dość nowa przeglądarka, żeby go poprawnie oglądać (np.
60 Mozilla, Konqueror, Opera albo IE 6).
61
62 %prep
63 %setup -q
64
65 %build
66 %{?with_bootstrap:PATH=$PATH:/usr/local/bin}
67 runhaskell Setup.lhs configure --prefix=%{_prefix}
68 runhaskell Setup.lhs build
69
70 cd doc
71 test -f configure || autoreconf
72 ./configure
73 %{__make} html
74 cd ..
75
76 %install
77 rm -rf $RPM_BUILD_ROOT
78 %{?with_bootstrap:PATH=$PATH:/usr/local/bin}
79 runhaskell Setup.lhs copy --destdir=$RPM_BUILD_ROOT
80
81 install -d $RPM_BUILD_ROOT%{_examplesdir}
82 cp -a examples $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
83
84 %clean
85 rm -rf $RPM_BUILD_ROOT
86
87 %files
88 %defattr(644,root,root,755)
89 %doc CHANGES README TODO doc/haddock haskell.vim
90 %attr(755,root,root) %{_bindir}/haddock
91 %{_datadir}/%{name}-%{version}
92 %{_examplesdir}/%{name}-%{version}
This page took 0.043578 seconds and 3 git commands to generate.