3 %bcond_without prof # profiling library
5 %define pkgname th-orphans
6 Summary: Orphan instances for TH datatypes
7 Summary(pl.UTF-8): Osierocone instancje typów danych TH
12 Group: Development/Languages
13 #Source0Download: http://hackage.haskell.org/package/th-orphans
14 Source0: http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
15 # Source0-md5: d56c8222885e82e47076a27224fd4ced
16 URL: http://hackage.haskell.org/package/th-orphans
17 BuildRequires: ghc >= 6.12.3
18 BuildRequires: ghc-base >= 4.3
19 BuildRequires: ghc-base < 5
20 BuildRequires: ghc-generic-deriving >= 1.9
21 BuildRequires: ghc-template-haskell
22 BuildRequires: ghc-th-lift >= 0.7.1
23 BuildRequires: ghc-th-lift-instances
24 BuildRequires: ghc-th-reify-many >= 0.1
25 BuildRequires: ghc-th-reify-many < 0.2
27 BuildRequires: ghc-base-prof >= 4.3
28 BuildRequires: ghc-base-prof < 5
29 BuildRequires: ghc-generic-deriving-prof >= 1.9
30 BuildRequires: ghc-prof >= 6.12.3
31 BuildRequires: ghc-template-haskell-prof
32 BuildRequires: ghc-th-lift-instances-prof
33 BuildRequires: ghc-th-lift-prof >= 0.7.1
34 BuildRequires: ghc-th-reify-many-prof >= 0.1
35 BuildRequires: ghc-th-reify-many-prof < 0.2
37 BuildRequires: rpmbuild(macros) >= 1.608
39 Requires(post,postun): /usr/bin/ghc-pkg
40 Requires: ghc-base >= 4.3
41 Requires: ghc-base < 5
42 Requires: ghc-generic-deriving >= 1.9
43 Requires: ghc-template-haskell
44 Requires: ghc-th-lift >= 0.7.1
45 Requires: ghc-th-lift-instances
46 Requires: ghc-th-reify-many >= 0.1
47 Requires: ghc-th-reify-many < 0.2
48 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50 # debuginfo is not useful for ghc
51 %define _enable_debug_packages 0
53 # don't compress haddock files
54 %define _noautocompressdoc *.haddock
57 Orphan instances for TH datatypes. In particular, instances for Ord
58 and Lift, as well as a few missing Show / Eq. These instances used to
59 live in haskell-src-meta, and that's where the version number started.
61 %description -l pl.UTF-8
62 Osierocone instancje typów danych TH - w szczególności instancje Ord i
63 Lift, a także kilka brakujących Show / Eq. Instancje te były wcześniej
64 w haskell-src-meta, i w tym pakiecie zaczęła się numeracja wersji.
67 Summary: Profiling %{pkgname} library for GHC
68 Summary(pl.UTF-8): Biblioteka profilująca %{pkgname} dla GHC.
69 Group: Development/Libraries
70 Requires: %{name} = %{version}-%{release}
71 Requires: ghc-base-prof >= 4.3
72 Requires: ghc-base-prof < 5
73 Requires: ghc-generic-deriving-prof >= 1.9
74 Requires: ghc-template-haskell-prof
75 Requires: ghc-th-lift-instances-prof
76 Requires: ghc-th-lift-prof >= 0.7.1
77 Requires: ghc-th-reify-many-prof >= 0.1
78 Requires: ghc-th-reify-many-prof < 0.2
81 Profiling %{pkgname} library for GHC. Should be installed when
82 GHC's profiling subsystem is needed.
84 %description prof -l pl.UTF-8
85 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
86 kiedy potrzebujemy systemu profilującego z GHC.
89 %setup -q -n %{pkgname}-%{version}
92 runhaskell Setup.hs configure -v2 \
93 %{?with_prof:--enable-library-profiling} \
96 --libexecdir=%{_libexecdir} \
97 --docdir=%{_docdir}/%{name}-%{version}
99 runhaskell Setup.hs build
100 runhaskell Setup.hs haddock --executables
103 rm -rf $RPM_BUILD_ROOT
104 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
106 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
108 # work around automatic haddock docs installation
109 %{__rm} -rf %{name}-%{version}-doc
110 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
111 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
113 runhaskell Setup.hs register \
114 --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
117 rm -rf $RPM_BUILD_ROOT
126 %defattr(644,root,root,755)
127 %doc %{name}-%{version}-doc/*
128 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
129 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
130 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/HSth-orphans-%{version}.o
131 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSth-orphans-%{version}.a
132 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language
133 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell
134 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/TH
135 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/TH/*.hi
138 %defattr(644,root,root,755)
139 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHSth-orphans-%{version}_p.a
140 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/TH/*.p_hi