]> git.pld-linux.org Git - packages/ghc-monad-control.git/blob - ghc-monad-control.spec
824c0ab2aed0d08f5e0faebb937ae7db200a36b7
[packages/ghc-monad-control.git] / ghc-monad-control.spec
1 #
2 # Conditional build:
3 %bcond_without  prof    # profiling library
4 #
5 %define         pkgname monad-control
6 Summary:        Generic control operations
7 Summary(pl.UTF-8):      Ogólne operacje sterujące
8 Name:           ghc-%{pkgname}
9 Version:        1.0.2.3
10 Release:        1
11 License:        BSD
12 Group:          Development/Languages
13 #Source0Download: http://hackage.haskell.org/package/monad-control
14 Source0:        http://hackage.haskell.org/package/monad-control-%{version}/%{pkgname}-%{version}.tar.gz
15 # Source0-md5:  4b7ba1532ac949818947d08f2aa88d0c
16 URL:            http://hackage.haskell.org/package/monad-control
17 BuildRequires:  ghc >= 6.12.3
18 BuildRequires:  ghc-base >= 3
19 BuildRequires:  ghc-base-unicode-symbols >= 0.1.1
20 BuildRequires:  ghc-transformers >= 0.2
21 BuildRequires:  ghc-transformers-base >= 0.4.1
22 %if %{with prof}
23 BuildRequires:  ghc-prof >= 6.12.3
24 BuildRequires:  ghc-base-prof >= 3
25 BuildRequires:  ghc-base-unicode-symbols-prof >= 0.1.1
26 BuildRequires:  ghc-transformers-prof >= 0.2
27 BuildRequires:  ghc-transformers-base-prof >= 0.4.1
28 %endif
29 BuildRequires:  rpmbuild(macros) >= 1.608
30 Requires(post,postun):  /usr/bin/ghc-pkg
31 %requires_eq    ghc
32 Requires:       ghc-base >= 3
33 Requires:       ghc-base-unicode-symbols >= 0.1.1
34 Requires:       ghc-transformers >= 0.2
35 Requires:       ghc-transformers-base >= 0.4.1
36 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37
38 # debuginfo is not useful for ghc
39 %define         _enable_debug_packages  0
40
41 %description
42 This package defines the type class MonadBaseControl, a subset of
43 MonadBase into which generic control operations such as catch can be
44 lifted from IO or any other base monad. Instances are based on monad
45 transformers in MonadTransControl, which includes all standard monad
46 transformers in the transformers library except ContT.
47
48 %description -l pl.UTF-8
49 Ten pakiet definiuje klasę typu MonadBaseControl, będącą podzbiorem
50 MonadBase, do której można podnieść ogólne operacje sterujące (takie
51 jak catch) z IO lub dowolnej innej podstawowej monady. Instancje są
52 oparte na transformatorach monad w MonadTransControl, która dołącza
53 wszystkie standardowe transformatory monad z biblioteki transformers z
54 wyjątkiem ContT.
55
56 %package prof
57 Summary:        Profiling %{pkgname} library for GHC
58 Summary(pl.UTF-8):      Biblioteka profilująca %{pkgname} dla GHC
59 Group:          Development/Libraries
60 Requires:       %{name} = %{version}-%{release}
61 Requires:       ghc-base-prof >= 3
62 Requires:       ghc-base-unicode-symbols-prof >= 0.1.1
63 Requires:       ghc-transformers-prof >= 0.2
64 Requires:       ghc-transformers-base-prof >= 0.4.1
65
66 %description prof
67 Profiling %{pkgname} library for GHC. Should be installed when
68 GHC's profiling subsystem is needed.
69
70 %description prof -l pl.UTF-8
71 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
72 kiedy potrzebujemy systemu profilującego z GHC.
73
74 %package doc
75 Summary:        HTML documentation for ghc %{pkgname} package
76 Summary(pl.UTF-8):      Dokumentacja w formacie HTML dla pakietu ghc %{pkgname}
77 Group:          Documentation
78
79 %description doc
80 HTML documentation for ghc %{pkgname} package.
81
82 %description doc -l pl.UTF-8
83 Dokumentacja w formacie HTML dla pakietu ghc %{pkgname}.
84
85 %prep
86 %setup -q -n %{pkgname}-%{version}
87
88 %build
89 runhaskell Setup.hs configure -v2 \
90         %{?with_prof:--enable-library-profiling} \
91         --prefix=%{_prefix} \
92         --libdir=%{_libdir} \
93         --libexecdir=%{_libexecdir} \
94         --docdir=%{_docdir}/%{name}-%{version}
95
96 runhaskell Setup.hs build
97 runhaskell Setup.hs haddock --executables
98
99 %install
100 rm -rf $RPM_BUILD_ROOT
101 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
102
103 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
104
105 # work around automatic haddock docs installation
106 %{__rm} -rf %{name}-%{version}-doc
107 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/html %{name}-%{version}-doc
108 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
109
110 runhaskell Setup.hs register \
111         --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
112
113 %clean
114 rm -rf $RPM_BUILD_ROOT
115
116 %post
117 %ghc_pkg_recache
118
119 %postun
120 %ghc_pkg_recache
121
122 %files
123 %defattr(644,root,root,755)
124 %doc CHANGELOG LICENSE README.markdown
125 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
126 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
127 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSmonad-control-%{version}-*.so
128 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSmonad-control-%{version}-*.a
129 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSmonad-control-%{version}-*_p.a
130 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control
131 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control/Monad
132 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control/Monad/Trans
133 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control/Monad/Trans/Control.hi
134 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control/Monad/Trans/Control.dyn_hi
135
136 %if %{with prof}
137 %files prof
138 %defattr(644,root,root,755)
139 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSmonad-control-%{version}-*_p.a
140 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Control/Monad/Trans/Control.p_hi
141 %endif
142
143 %files doc
144 %defattr(644,root,root,755)
145 %doc %{name}-%{version}-doc/*
This page took 0.082299 seconds and 2 git commands to generate.