]> git.pld-linux.org Git - packages/ghc-snap-core.git/blob - ghc-snap-core.spec
- Th provides ghc-haskell-platform with hashable 1.1.x: temporarily stick to old BRs
[packages/ghc-snap-core.git] / ghc-snap-core.spec
1 # TODO: switch to hashable >= 1.2.1 deps when it becomes available in Th
2 # (1.2.0.x are not supported; only 1.1.* or >= 1.2.1)
3 #
4 # Conditional build:
5 %bcond_without  prof    # profiling library
6 #
7 %define         pkgname snap-core
8 Summary:        Snap: A Haskell Web Framework (core interfaces and types)
9 Summary(pl.UTF-8):      Snap - szkielet WWW dla Haskella (główne interfejsy i typy)
10 Name:           ghc-%{pkgname}
11 Version:        0.9.5.0
12 Release:        1
13 License:        BSD
14 Group:          Development/Languages
15 #Source0Download: http://hackage.haskell.org/package/snap-core
16 Source0:        http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
17 # Source0-md5:  e347d1aeee7a2990d211b9d1556c125d
18 Patch0:         %{name}-deps.patch
19 URL:            http://hackage.haskell.org/package/snap-core
20 BuildRequires:  ghc >= 6.12.3
21 BuildRequires:  ghc-HUnit >= 1.2
22 BuildRequires:  ghc-HUnit < 2
23 BuildRequires:  ghc-MonadCatchIO-transformers >= 0.2.1
24 BuildRequires:  ghc-MonadCatchIO-transformers < 0.4
25 BuildRequires:  ghc-attoparsec >= 0.10
26 BuildRequires:  ghc-attoparsec < 0.11
27 BuildRequires:  ghc-attoparsec-enumerator >= 0.3
28 BuildRequires:  ghc-attoparsec-enumerator < 0.4
29 BuildRequires:  ghc-base >= 4
30 BuildRequires:  ghc-base < 5
31 BuildRequires:  ghc-blaze-builder >= 0.2.1.4
32 BuildRequires:  ghc-blaze-builder < 0.4
33 BuildRequires:  ghc-blaze-builder-enumerator >= 0.2
34 BuildRequires:  ghc-blaze-builder-enumerator < 0.3
35 BuildRequires:  ghc-bytestring >= 0.9
36 BuildRequires:  ghc-bytestring < 0.11
37 BuildRequires:  ghc-case-insensitive >= 0.3
38 BuildRequires:  ghc-case-insensitive < 1.2
39 BuildRequires:  ghc-containers >= 0.3
40 BuildRequires:  ghc-containers < 1.0
41 BuildRequires:  ghc-deepseq >= 1.1
42 BuildRequires:  ghc-deepseq < 1.4
43 BuildRequires:  ghc-directory >= 1
44 BuildRequires:  ghc-directory < 2
45 BuildRequires:  ghc-enumerator >= 0.4.15
46 BuildRequires:  ghc-enumerator < 0.5
47 BuildRequires:  ghc-filepath >= 1.1
48 BuildRequires:  ghc-filepath < 2.0
49 BuildRequires:  ghc-hashable >= 1.1
50 #BuildRequires: ghc-hashable >= 1.2.1
51 BuildRequires:  ghc-hashable < 1.3
52 BuildRequires:  ghc-mtl >= 2.0
53 BuildRequires:  ghc-mtl < 2.2
54 BuildRequires:  ghc-random >= 1
55 BuildRequires:  ghc-random < 2
56 BuildRequires:  ghc-regex-posix >= 0.95
57 BuildRequires:  ghc-regex-posix < 1
58 BuildRequires:  ghc-text >= 0.11
59 BuildRequires:  ghc-time >= 1.0
60 BuildRequires:  ghc-time < 1.5
61 BuildRequires:  ghc-unix >= 2.4
62 BuildRequires:  ghc-unix < 3.0
63 BuildRequires:  ghc-unix-compat >= 0.2
64 BuildRequires:  ghc-unix-compat < 0.5
65 BuildRequires:  ghc-unordered-containers >= 0.1.4.3
66 BuildRequires:  ghc-unordered-containers < 0.3
67 BuildRequires:  ghc-vector >= 0.6
68 BuildRequires:  ghc-vector < 0.11
69 BuildRequires:  ghc-zlib-enum >= 0.2.1
70 BuildRequires:  ghc-zlib-enum < 0.3
71 %if %{with prof}
72 BuildRequires:  ghc-prof >= 6.12.3
73 BuildRequires:  ghc-HUnit-prof >= 1.2
74 BuildRequires:  ghc-HUnit-prof < 2
75 BuildRequires:  ghc-MonadCatchIO-transformers-prof >= 0.2.1
76 BuildRequires:  ghc-MonadCatchIO-transformers-prof < 0.4
77 BuildRequires:  ghc-attoparsec-prof >= 0.10
78 BuildRequires:  ghc-attoparsec-prof < 0.11
79 BuildRequires:  ghc-attoparsec-enumerator-prof >= 0.3
80 BuildRequires:  ghc-attoparsec-enumerator-prof < 0.4
81 BuildRequires:  ghc-base-prof >= 4
82 BuildRequires:  ghc-base-prof < 5
83 BuildRequires:  ghc-blaze-builder-prof >= 0.2.1.4
84 BuildRequires:  ghc-blaze-builder-prof < 0.4
85 BuildRequires:  ghc-blaze-builder-enumerator-prof >= 0.2
86 BuildRequires:  ghc-blaze-builder-enumerator-prof < 0.3
87 BuildRequires:  ghc-bytestring-prof >= 0.9
88 BuildRequires:  ghc-bytestring-prof < 0.11
89 BuildRequires:  ghc-case-insensitive-prof >= 0.3
90 BuildRequires:  ghc-case-insensitive-prof < 1.2
91 BuildRequires:  ghc-containers-prof >= 0.3
92 BuildRequires:  ghc-containers-prof < 1.0
93 BuildRequires:  ghc-deepseq-prof >= 1.1
94 BuildRequires:  ghc-deepseq-prof < 1.4
95 BuildRequires:  ghc-directory-prof >= 1
96 BuildRequires:  ghc-directory-prof < 2
97 BuildRequires:  ghc-enumerator-prof >= 0.4.15
98 BuildRequires:  ghc-enumerator-prof < 0.5
99 BuildRequires:  ghc-filepath-prof >= 1.1
100 BuildRequires:  ghc-filepath-prof < 2.0
101 BuildRequires:  ghc-hashable-prof >= 1.1
102 #BuildRequires: ghc-hashable-prof >= 1.2.1
103 BuildRequires:  ghc-hashable-prof < 1.3
104 BuildRequires:  ghc-mtl-prof >= 2.0
105 BuildRequires:  ghc-mtl-prof < 2.2
106 BuildRequires:  ghc-random-prof >= 1
107 BuildRequires:  ghc-random-prof < 2
108 BuildRequires:  ghc-regex-posix-prof >= 0.95
109 BuildRequires:  ghc-regex-posix-prof < 1
110 BuildRequires:  ghc-text-prof >= 0.11
111 BuildRequires:  ghc-time-prof >= 1.0
112 BuildRequires:  ghc-time-prof < 1.5
113 BuildRequires:  ghc-unix-prof >= 2.4
114 BuildRequires:  ghc-unix-prof < 3.0
115 BuildRequires:  ghc-unix-compat-prof >= 0.2
116 BuildRequires:  ghc-unix-compat-prof < 0.5
117 BuildRequires:  ghc-unordered-containers-prof >= 0.1.4.3
118 BuildRequires:  ghc-unordered-containers-prof < 0.3
119 BuildRequires:  ghc-vector-prof >= 0.6
120 BuildRequires:  ghc-vector-prof < 0.11
121 BuildRequires:  ghc-zlib-enum-prof >= 0.2.1
122 BuildRequires:  ghc-zlib-enum-prof < 0.3
123 %endif
124 BuildRequires:  rpmbuild(macros) >= 1.608
125 Requires(post,postun):  /usr/bin/ghc-pkg
126 %requires_releq ghc
127 Requires:       ghc-HUnit >= 1.2
128 Requires:       ghc-HUnit < 2
129 Requires:       ghc-MonadCatchIO-transformers >= 0.2.1
130 Requires:       ghc-MonadCatchIO-transformers < 0.4
131 Requires:       ghc-attoparsec >= 0.10
132 Requires:       ghc-attoparsec < 0.11
133 Requires:       ghc-attoparsec-enumerator >= 0.3
134 Requires:       ghc-attoparsec-enumerator < 0.4
135 Requires:       ghc-base >= 4
136 Requires:       ghc-base < 5
137 Requires:       ghc-blaze-builder >= 0.2.1.4
138 Requires:       ghc-blaze-builder < 0.4
139 Requires:       ghc-blaze-builder-enumerator >= 0.2
140 Requires:       ghc-blaze-builder-enumerator < 0.3
141 Requires:       ghc-bytestring >= 0.9
142 Requires:       ghc-bytestring < 0.11
143 Requires:       ghc-case-insensitive >= 0.3
144 Requires:       ghc-case-insensitive < 1.2
145 Requires:       ghc-containers >= 0.3
146 Requires:       ghc-containers < 1.0
147 Requires:       ghc-deepseq >= 1.1
148 Requires:       ghc-deepseq < 1.4
149 Requires:       ghc-directory >= 1
150 Requires:       ghc-directory < 2
151 Requires:       ghc-enumerator >= 0.4.15
152 Requires:       ghc-enumerator < 0.5
153 Requires:       ghc-filepath >= 1.1
154 Requires:       ghc-filepath < 2.0
155 Requires:       ghc-hashable >= 1.1
156 #Requires:      ghc-hashable >= 1.2.1
157 Requires:       ghc-hashable < 1.3
158 Requires:       ghc-mtl >= 2.0
159 Requires:       ghc-mtl < 2.2
160 Requires:       ghc-random >= 1
161 Requires:       ghc-random < 2
162 Requires:       ghc-regex-posix >= 0.95
163 Requires:       ghc-regex-posix < 1
164 Requires:       ghc-text >= 0.11
165 Requires:       ghc-time >= 1.0
166 Requires:       ghc-time < 1.5
167 Requires:       ghc-unix >= 2.4
168 Requires:       ghc-unix < 3.0
169 Requires:       ghc-unix-compat >= 0.2
170 Requires:       ghc-unix-compat < 0.5
171 Requires:       ghc-unordered-containers >= 0.1.4.3
172 Requires:       ghc-unordered-containers < 0.3
173 Requires:       ghc-vector >= 0.6
174 Requires:       ghc-vector < 0.11
175 Requires:       ghc-zlib-enum >= 0.2.1
176 Requires:       ghc-zlib-enum < 0.3
177 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
178
179 # debuginfo is not useful for ghc
180 %define         _enable_debug_packages  0
181
182 # don't compress haddock files
183 %define         _noautocompressdoc      *.haddock
184
185 %description
186 Snap is a simple and fast web development framework and server written
187 in Haskell. For more information you can visit the Snap project
188 website at <http://snapframework.com/>.
189
190 %description -l pl.UTF-8
191 Snap to prosty i szybki szkielet programistyczny oraz serwer WWW,
192 napisany w Haskellu. Więcej informacji można znaleźć na stronie
193 projektu: <http://snapframework.com/>.
194
195 %package prof
196 Summary:        Profiling %{pkgname} library for GHC
197 Summary(pl.UTF-8):      Biblioteka profilująca %{pkgname} dla GHC.
198 Group:          Development/Libraries
199 Requires:       %{name} = %{version}-%{release}
200 Requires:       ghc-HUnit-prof >= 1.2
201 Requires:       ghc-HUnit-prof < 2
202 Requires:       ghc-MonadCatchIO-transformers-prof >= 0.2.1
203 Requires:       ghc-MonadCatchIO-transformers-prof < 0.4
204 Requires:       ghc-attoparsec-prof >= 0.10
205 Requires:       ghc-attoparsec-prof < 0.11
206 Requires:       ghc-attoparsec-enumerator-prof >= 0.3
207 Requires:       ghc-attoparsec-enumerator-prof < 0.4
208 Requires:       ghc-base-prof >= 4
209 Requires:       ghc-base-prof < 5
210 Requires:       ghc-blaze-builder-prof >= 0.2.1.4
211 Requires:       ghc-blaze-builder-prof < 0.4
212 Requires:       ghc-blaze-builder-enumerator-prof >= 0.2
213 Requires:       ghc-blaze-builder-enumerator-prof < 0.3
214 Requires:       ghc-bytestring-prof >= 0.9
215 Requires:       ghc-bytestring-prof < 0.11
216 Requires:       ghc-case-insensitive-prof >= 0.3
217 Requires:       ghc-case-insensitive-prof < 1.2
218 Requires:       ghc-containers-prof >= 0.3
219 Requires:       ghc-containers-prof < 1.0
220 Requires:       ghc-deepseq-prof >= 1.1
221 Requires:       ghc-deepseq-prof < 1.4
222 Requires:       ghc-directory-prof >= 1
223 Requires:       ghc-directory-prof < 2
224 Requires:       ghc-enumerator-prof >= 0.4.15
225 Requires:       ghc-enumerator-prof < 0.5
226 Requires:       ghc-filepath-prof >= 1.1
227 Requires:       ghc-filepath-prof < 2.0
228 Requires:       ghc-hashable-prof >= 1.1
229 #Requires:      ghc-hashable-prof >= 1.2.1
230 Requires:       ghc-hashable-prof < 1.3
231 Requires:       ghc-mtl-prof >= 2.0
232 Requires:       ghc-mtl-prof < 2.2
233 Requires:       ghc-random-prof >= 1
234 Requires:       ghc-random-prof < 2
235 Requires:       ghc-regex-posix-prof >= 0.95
236 Requires:       ghc-regex-posix-prof < 1
237 Requires:       ghc-text-prof >= 0.11
238 Requires:       ghc-time-prof >= 1.0
239 Requires:       ghc-time-prof < 1.5
240 Requires:       ghc-unix-prof >= 2.4
241 Requires:       ghc-unix-prof < 3.0
242 Requires:       ghc-unix-compat-prof >= 0.2
243 Requires:       ghc-unix-compat-prof < 0.5
244 Requires:       ghc-unordered-containers-prof >= 0.1.4.3
245 Requires:       ghc-unordered-containers-prof < 0.3
246 Requires:       ghc-vector-prof >= 0.6
247 Requires:       ghc-vector-prof < 0.11
248 Requires:       ghc-zlib-enum-prof >= 0.2.1
249 Requires:       ghc-zlib-enum-prof < 0.3
250
251 %description prof
252 Profiling %{pkgname} library for GHC. Should be installed when GHC's
253 profiling subsystem is needed.
254
255 %description prof -l pl.UTF-8
256 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
257 kiedy potrzebujemy systemu profilującego z GHC.
258
259 %prep
260 %setup -q -n %{pkgname}-%{version}
261 %patch0 -p1
262
263 %build
264 runhaskell Setup.hs configure -v2 \
265         %{?with_prof:--enable-library-profiling} \
266         --prefix=%{_prefix} \
267         --libdir=%{_libdir} \
268         --libexecdir=%{_libexecdir} \
269         --docdir=%{_docdir}/%{name}-%{version}
270
271 runhaskell Setup.hs build
272 runhaskell Setup.hs haddock --executables
273
274 %install
275 rm -rf $RPM_BUILD_ROOT
276 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
277
278 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
279
280 # work around automatic haddock docs installation
281 %{__rm} -rf %{name}-%{version}-doc
282 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
283 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
284
285 runhaskell Setup.hs register \
286         --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
287
288 %clean
289 rm -rf $RPM_BUILD_ROOT
290
291 %post
292 %ghc_pkg_recache
293
294 %postun
295 %ghc_pkg_recache
296
297 %files
298 %defattr(644,root,root,755)
299 %doc CONTRIBUTORS README* %{name}-%{version}-doc/*
300 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
301 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
302 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/HSsnap-core-%{version}.o
303 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSsnap-core-%{version}.a
304 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap
305 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/*.hi
306 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal
307 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/*.hi
308 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Http
309 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Http/*.hi
310 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Iteratee
311 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Iteratee/*.hi
312 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Parsing
313 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Parsing/*.hi
314 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Test
315 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Test/*.hi
316 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Types
317 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Types/*.hi
318 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Util
319 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Util/*.hi
320
321 %files prof
322 %defattr(644,root,root,755)
323 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSsnap-core-%{version}_p.a
324 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/*.p_hi
325 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/*.p_hi
326 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Http/*.p_hi
327 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Iteratee/*.p_hi
328 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Parsing/*.p_hi
329 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Internal/Test/*.p_hi
330 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Types/*.p_hi
331 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Snap/Util/*.p_hi
This page took 0.095579 seconds and 3 git commands to generate.