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