]> git.pld-linux.org Git - packages/ghc-enumerator.git/blob - ghc-enumerator.spec
2fa1c29380746f144523de0603a5621ad8477103
[packages/ghc-enumerator.git] / ghc-enumerator.spec
1 %define         pkgname enumerator
2 Summary:        Reliable, high-performance processing with left-fold enumerators
3 Name:           ghc-%{pkgname}
4 Version:        0.4.19
5 Release:        3
6 License:        MIT
7 Group:          Development/Languages
8 Source0:        http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
9 # Source0-md5:  0f7a3c97af5cc0b7901a7899fe22e867
10 URL:            http://hackage.haskell.org/package/enumerator/
11 BuildRequires:  ghc >= 6.12.3
12 BuildRequires:  ghc-prof
13 BuildRequires:  rpmbuild(macros) >= 1.608
14 %requires_releq ghc
15 Requires(post,postun):  /usr/bin/ghc-pkg
16 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17
18 # debuginfo is not useful for ghc
19 %define         _enable_debug_packages  0
20
21 # don't compress haddoc files
22 %define         _noautocompressdoc      *.haddock
23
24 %description
25 This library contains an enumerator implementation for Haskell,
26 designed to be both simple and efficient.
27
28 %package prof
29 Summary:        Profiling %{pkgname} library for GHC
30 Summary(pl.UTF-8):      Biblioteka profilująca %{pkgname} dla GHC.
31 Group:          Development/Libraries
32 Requires:       %{name} = %{version}-%{release}
33
34 %description prof
35 Profiling %{pkgname} library for GHC.  Should be installed when
36 GHC's profiling subsystem is needed.
37
38 %description prof -l pl.UTF-8
39 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
40 kiedy potrzebujemy systemu profilującego z GHC.
41
42 %prep
43 %setup -q -n %{pkgname}-%{version}
44
45 %build
46 runhaskell Setup.hs configure -v2 --enable-library-profiling \
47         --prefix=%{_prefix} \
48         --libdir=%{_libdir} \
49         --libexecdir=%{_libexecdir} \
50         --docdir=%{_docdir}/%{name}-%{version}
51
52 runhaskell Setup.hs build
53 runhaskell Setup.hs haddock --executables
54
55 %install
56 rm -rf $RPM_BUILD_ROOT
57 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
58
59 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
60
61 # work around automatic haddock docs installation
62 %{__rm} -rf %{name}-%{version}-doc
63 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
64 %{__rm} -rf $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
65
66 runhaskell Setup.hs register \
67         --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
68
69 %clean
70 rm -rf $RPM_BUILD_ROOT
71
72 %post
73 %ghc_pkg_recache
74
75 %postun
76 %ghc_pkg_recache
77
78 %files
79 %defattr(644,root,root,755)
80 %doc %{name}-%{version}-doc/*
81 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
82 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
83 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.o
84 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
85 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
86
87 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data
88 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/*.hi
89 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Enumerator
90 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Enumerator/*.hi
91
92 %files prof
93 %defattr(644,root,root,755)
94 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
95 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/*.p_hi
96 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Data/Enumerator/*.p_hi
This page took 0.095034 seconds and 2 git commands to generate.