]> git.pld-linux.org Git - SPECS.git/blob - ghc-th-orphans.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / ghc-th-orphans.spec
1 #
2 # Conditional build:
3 %bcond_without  prof    # profiling library
4 #
5 %define         pkgname th-orphans
6 Summary:        Orphan instances for TH datatypes
7 Summary(pl.UTF-8):      Osierocone instancje typów danych TH
8 Name:           ghc-%{pkgname}
9 Version:        0.13.3
10 Release:        0.1
11 License:        BSD
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
26 %if %{with prof}
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
36 %endif
37 BuildRequires:  rpmbuild(macros) >= 1.608
38 %requires_eq    ghc
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)
49
50 # debuginfo is not useful for ghc
51 %define         _enable_debug_packages  0
52
53 # don't compress haddock files
54 %define         _noautocompressdoc      *.haddock
55
56 %description
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.
60
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.
65
66 %package prof
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
79
80 %description prof
81 Profiling %{pkgname} library for GHC.  Should be installed when
82 GHC's profiling subsystem is needed.
83
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.
87
88 %prep
89 %setup -q -n %{pkgname}-%{version}
90
91 %build
92 runhaskell Setup.hs configure -v2 \
93         %{?with_prof:--enable-library-profiling} \
94         --prefix=%{_prefix} \
95         --libdir=%{_libdir} \
96         --libexecdir=%{_libexecdir} \
97         --docdir=%{_docdir}/%{name}-%{version}
98
99 runhaskell Setup.hs build
100 runhaskell Setup.hs haddock --executables
101
102 %install
103 rm -rf $RPM_BUILD_ROOT
104 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
105
106 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
107
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}
112
113 runhaskell Setup.hs register \
114         --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
115
116 %clean
117 rm -rf $RPM_BUILD_ROOT
118
119 %post
120 %ghc_pkg_recache
121
122 %postun
123 %ghc_pkg_recache
124
125 %files
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
136
137 %files prof
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
This page took 0.760125 seconds and 3 git commands to generate.