]> git.pld-linux.org Git - packages/ghc-regex-pcre.git/blob - ghc-regex-pcre.spec
- added description
[packages/ghc-regex-pcre.git] / ghc-regex-pcre.spec
1 %define         pkgname regex-pcre
2 Summary:        Replaces/Enhances Text.Regex
3 Name:           ghc-%{pkgname}
4 Version:        0.94.4
5 Release:        1
6 License:        BSD
7 Group:          Development/Languages
8 Source0:        http://hackage.haskell.org/packages/archive/%{pkgname}/%{version}/%{pkgname}-%{version}.tar.gz
9 # Source0-md5:  be3794c67959f2b3b840bd026ef0b9ea
10 URL:            http://hackage.haskell.org/package/regex-pcre/
11 BuildRequires:  ghc >= 6.12.3
12 BuildRequires:  ghc-prof
13 BuildRequires:  rpmbuild(macros) >= 1.608
14 %requires_releq ghc
15 Requires(post,postun):  /usr/bin/ghc-pkg
16 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17
18 # debuginfo is not useful for ghc
19 %define         _enable_debug_packages  0
20
21 # don't compress haddoc files
22 %define         _noautocompressdoc      *.haddock
23
24 %description
25 The PCRE backend to accompany regex-base, see www.pcre.org.
26
27 %package prof
28 Summary:        Profiling %{pkgname} library for GHC
29 Summary(pl.UTF-8):      Biblioteka profilująca %{pkgname} dla GHC.
30 Group:          Development/Libraries
31 Requires:       %{name} = %{version}-%{release}
32
33 %description prof
34 Profiling %{pkgname} library for GHC.  Should be installed when
35 GHC's profiling subsystem is needed.
36
37 %description prof -l pl.UTF-8
38 Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
39 kiedy potrzebujemy systemu profilującego z GHC.
40
41 %prep
42 %setup -q -n %{pkgname}-%{version}
43
44 %build
45 runhaskell Setup.hs configure -v2 --enable-library-profiling \
46         --prefix=%{_prefix} \
47         --libdir=%{_libdir} \
48         --libexecdir=%{_libexecdir} \
49         --docdir=%{_docdir}/%{name}-%{version}
50
51 runhaskell Setup.hs build
52 runhaskell Setup.hs haddock --executables
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
57
58 runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
59
60 # work around automatic haddock docs installation
61 %{__rm} -rf %{name}-%{version}-doc
62 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
63 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
64
65 runhaskell Setup.hs register \
66         --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
67
68 %clean
69 rm -rf $RPM_BUILD_ROOT
70
71 %post
72 %ghc_pkg_recache
73
74 %postun
75 %ghc_pkg_recache
76
77 %files
78 %defattr(644,root,root,755)
79 %doc %{name}-%{version}-doc/*
80 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
81 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
82 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.o
83 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
84 %exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
85
86 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text
87 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex
88 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE
89 %dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE/ByteString
90 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/*.hi
91 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE/*.hi
92 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE/ByteString/*.hi
93
94 %files prof
95 %defattr(644,root,root,755)
96 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
97 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/*.p_hi
98 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE/*.p_hi
99 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/Text/Regex/PCRE/ByteString/*.p_hi
This page took 0.029479 seconds and 4 git commands to generate.