]> git.pld-linux.org Git - packages/hlint.git/blob - hlint.spec
- added BRs
[packages/hlint.git] / hlint.spec
1 Summary:        Haskell Source code suggestions
2 Name:           hlint
3 Version:        1.8.3
4 Release:        0.1
5 License:        GPL
6 Group:          Development/Languages
7 Source0:        http://hackage.haskell.org/packages/archive/%{name}/%{version}/%{name}-%{version}.tar.gz
8 # Source0-md5:  af5a287804f0ed1ba41728febf74296f
9 URL:            http://community.haskell.org/~ndm/hlint/
10 BuildRequires:  cpphs
11 BuildRequires:  ghc >= 6.12.3
12 BuildRequires:  ghc-haskell-src-exts
13 BuildRequires:  ghc-transformers
14 BuildRequires:  ghc-uniplate
15 %requires_releq ghc
16 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17
18 %define         ghcdir          ghc-%(/usr/bin/ghc --numeric-version)
19
20 %description
21 HLint gives suggestions on how to improve your source code.
22
23 %prep
24 %setup -q
25
26 %build
27 runhaskell Setup.hs configure -v2 \
28         --prefix=%{_prefix} \
29         --libdir=%{_libdir} \
30         --libexecdir=%{_libexecdir} \
31         --docdir=%{_docdir}/%{name}-%{version}
32
33 runhaskell Setup.hs build
34 runhaskell Setup.hs haddock --executables
35
36 %install
37 rm -rf $RPM_BUILD_ROOT
38 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
39
40 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
41
42 # work around automatic haddock docs installation
43 rm -rf %{name}-%{version}-doc
44 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
45
46 runhaskell Setup.hs register \
47         --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
48
49 %clean
50 rm -rf $RPM_BUILD_ROOT
51
52 %post
53 /usr/bin/ghc-pkg recache
54
55 %postun
56 /usr/bin/ghc-pkg recache
57
58 %files
59 %defattr(644,root,root,755)
60 %doc NEWS
61 %doc %{name}-%{version}-doc/html
62 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
63 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
This page took 0.06287 seconds and 4 git commands to generate.