]> git.pld-linux.org Git - SPECS.git/blob - ghc-haskell-src-exts.spec
SPECS updated Sun 1 Aug 20:28:02 CEST 2021
[SPECS.git] / ghc-haskell-src-exts.spec
1 #
2 # Conditional build:
3 %bcond_without  prof    # profiling library
4 #
5 %define         pkgname haskell-src-exts
6 Summary:        Manipulating Haskell source: abstract syntax, lexer, parser, and pretty-printer
7 Summary(pl.UTF-8):      Operacje na źródłach w Haskellu: abstraksyjna składnia, analiza leksykalna i składniowa, wypisywanie
8 Name:           ghc-%{pkgname}
9 Version:        1.23.0
10 Release:        1
11 License:        BSD
12 Group:          Development/Languages
13 #Source0Download: http://hackage.haskell.org/package/haskell-src-exts
14 Source0:        http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
15 # Source0-md5:  d21622063b81240b6804e31f7d9f2498
16 URL:            http://hackage.haskell.org/package/haskell-src-exts
17 BuildRequires:  cpphs >= 1.3
18 BuildRequires:  ghc >= 6.12.3
19 BuildRequires:  ghc-array >= 0.1
20 BuildRequires:  ghc-base >= 4.5
21 BuildRequires:  ghc-base < 5
22 BuildRequires:  ghc-pretty >= 1.0
23 %if %{with prof}
24 BuildRequires:  cpphs-prof >= 1.3
25 BuildRequires:  ghc-prof >= 6.12.3
26 BuildRequires:  ghc-array-prof >= 0.1
27 BuildRequires:  ghc-base-prof >= 4.5
28 BuildRequires:  ghc-base-prof < 5
29 BuildRequires:  ghc-pretty-prof >= 1.0
30 %endif
31 BuildRequires:  rpmbuild(macros) >= 1.608
32 %requires_eq    ghc
33 Requires(post,postun):  /usr/bin/ghc-pkg
34 Requires:       cpphs >= 1.3
35 Requires:       ghc-array >= 0.1
36 Requires:       ghc-base >= 4.5
37 Requires:       ghc-base < 5
38 Requires:       ghc-pretty >= 1.0
39 Obsoletes:      ghc-haskell-src-exts-doc
40 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42 # debuginfo is not useful for ghc
43 %define         _enable_debug_packages  0
44
45 # don't compress haddock files
46 %define         _noautocompressdoc      *.haddock
47
48 %description
49 Haskell-Source with Extensions (HSE, haskell-src-exts) is an extension
50 of the standard haskell-src package, and handles most registered
51 syntactic extensions to Haskell, including:
52
53 * Multi-parameter type classes with functional dependencies
54 * Indexed type families (including associated types)
55 * Empty data declarations
56 * GADTs
57 * Implicit parameters
58 * Template Haskell 
59
60 and a few more. All extensions implemented in GHC are supported.
61 Apart from these standard extensions, it also handles regular patterns
62 as per the HaRP extension as well as HSX-style embedded XML syntax.
63
64 %description -l pl.UTF-8
65 Haskell-Source with Extensions (HSE, haskell-src-exts) to rozszerzenie
66 standardowego pakietu haskell-src, obsługujące większość
67 zarejestrowanych rozszerzeń składniowych do Haskella, w tym:
68
69 - wieloparametrowe klasy typów z zależnościami funkcyjnymi
70 - rodziny typów indeksowanych (w tym asocjacyjnych)
71 - deklaracje pustych danych
72 - GADT
73 - parametry implikowane
74 - Template Haskell
75
76 i kilka innych. Obsługiwane są wszystkie rozszerzenia zaimplementowane
77 w GHC. Poza tymi rozszerzeniami, pakiet obsługuje wzorce regularne
78 zgodne z rozszerzeniem HaRP, a także składnię osadzonego XML-a w stylu
79 HSX.
80
81 %package prof
82 Summary:        Profiling %{pkgname} library for GHC
83 Summary(pl.UTF-8):      Biblioteka profilująca %{pkgname} dla GHC.
84 Group:          Development/Libraries
85 Requires:       %{name} = %{version}-%{release}
86 Requires:       cpphs-prof >= 1.3
87 Requires:       ghc-array-prof >= 0.1
88 Requires:       ghc-base-prof >= 4.5
89 Requires:       ghc-base-prof < 5
90 Requires:       ghc-pretty-prof >= 1.0
91
92 %description prof
93 Profiling %{pkgname} library for GHC. Should be installed when GHC's
94 profiling subsystem is needed.
95
96 %description prof -l pl.UTF-8
97 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
98 kiedy potrzebujemy systemu profilującego z GHC.
99
100 %prep
101 %setup -q -n %{pkgname}-%{version}
102
103 %build
104 runhaskell Setup.hs configure -v2 \
105         %{?with_prof:--enable-library-profiling} \
106         --prefix=%{_prefix} \
107         --libdir=%{_libdir} \
108         --libexecdir=%{_libexecdir} \
109         --docdir=%{_docdir}/%{name}-%{version}
110
111 runhaskell Setup.hs build
112 runhaskell Setup.hs haddock --executables
113
114 %install
115 rm -rf $RPM_BUILD_ROOT
116 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
117
118 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
119
120 # work around automatic haddock docs installation
121 %{__rm} -rf %{name}-%{version}-doc
122 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
123 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
124
125 runhaskell Setup.hs register \
126         --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
127
128 %clean
129 rm -rf $RPM_BUILD_ROOT
130
131 %post
132 %ghc_pkg_recache
133
134 %postun
135 %ghc_pkg_recache
136
137 %files
138 %defattr(644,root,root,755)
139 %doc CHANGELOG %{name}-%{version}-doc/*
140 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
141 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
142 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHShaskell-src-exts-%{version}-*.so
143 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHShaskell-src-exts-%{version}-*.a
144 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHShaskell-src-exts-%{version}-*_p.a
145 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language
146 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell
147 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/*.hi
148 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/*.dyn_hi
149 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/Exts
150 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/Exts/*.hi
151 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/Exts/*.dyn_hi
152 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Preprocessor
153 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Preprocessor/*.hi
154 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Preprocessor/*.dyn_hi
155
156 %if %{with prof}
157 %files prof
158 %defattr(644,root,root,755)
159 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/libHShaskell-src-exts-%{version}-*_p.a
160 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/*.p_hi
161 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Haskell/Exts/*.p_hi
162 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Language/Preprocessor/*.p_hi
163 %endif
This page took 0.319947 seconds and 3 git commands to generate.