1 %define pkgname timezone-olson
2 Summary: A Haskell binding to the timezone-olson graphics library
7 Group: Development/Languages
8 Source0: http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
9 # Source0-md5: 0ad826b14671e87c35ce0c638b4ff1be
10 URL: http://hackage.haskell.org/package/timezone-olson/
11 BuildRequires: ghc >= 6.12.3
12 BuildRequires: ghc-extensible-exceptions < 0.2
13 BuildRequires: ghc-extensible-exceptions >= 0.1.0
14 BuildRequires: ghc-timezone-series < 0.2
15 BuildRequires: ghc-timezone-series >= 0.1.0
16 BuildRequires: rpmbuild(macros) >= 1.608
18 Requires: ghc-extensible-exceptions < 0.2
19 Requires: ghc-extensible-exceptions >= 0.1.0
20 Requires: ghc-timezone-series < 0.2
21 Requires: ghc-timezone-series >= 0.1.0
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 # debuginfo is not useful for ghc
25 %define _enable_debug_packages 0
28 A Haskell binding to the timezone-olson graphics library.
31 Summary: HTML documentation for %{pkgname}
32 Summary(pl.UTF-8): Dokumentacja w formacie HTML dla %{pkgname}
36 HTML documentation for %{pkgname}.
38 %description doc -l pl.UTF-8
39 Dokumentacja w formacie HTML dla %{pkgname}.
42 %setup -q -n %{pkgname}-%{version}
45 runhaskell Setup.hs configure -v2 \
48 --libexecdir=%{_libexecdir} \
49 --docdir=%{_docdir}/%{name}-%{version}
51 runhaskell Setup.hs build
52 runhaskell Setup.hs haddock --executables
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
58 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
60 # work around automatic haddock docs installation
61 rm -rf %{name}-%{version}-doc
62 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/html %{name}-%{version}-doc
63 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
65 runhaskell Setup.hs register \
66 --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
69 rm -rf $RPM_BUILD_ROOT
78 %defattr(644,root,root,755)
79 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
80 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
83 %defattr(644,root,root,755)
84 %doc %{name}-%{version}-doc/*