]> git.pld-linux.org Git - packages/ghc-cmark-gfm.git/blame - ghc-cmark-gfm.spec
rebuild with ghc 8.10.7
[packages/ghc-cmark-gfm.git] / ghc-cmark-gfm.spec
CommitLineData
000289f0
JR
1#
2# Conditional build:
3%bcond_without prof # profiling library
4#
5%define pkgname cmark-gfm
6Summary: Fast, accurate GitHub Flavored Markdown parser and renderer
7Name: ghc-%{pkgname}
8Version: 0.2.1
03759fcb 9Release: 2
000289f0
JR
10License: BSD
11Group: Development/Languages
12#Source0Download: http://hackage.haskell.org/package/cmark-gfm
13Source0: http://hackage.haskell.org/package/%{pkgname}-%{version}/%{pkgname}-%{version}.tar.gz
14# Source0-md5: 152d0e1bae76dc1c29ff9edf221dcf4f
15URL: http://hackage.haskell.org/package/cmark-gfm
16BuildRequires: ghc >= 6.12.3
17%if %{with prof}
18BuildRequires: ghc-prof
19%endif
20BuildRequires: rpmbuild(macros) >= 1.608
21%requires_eq ghc
22Requires(post,postun): /usr/bin/ghc-pkg
23BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25# debuginfo is not useful for ghc
26%define _enable_debug_packages 0
27
28# don't compress haddock files
29%define _noautocompressdoc *.haddock
30
31%description
32his package provides Haskell bindings for libcmark-gfm, the reference
33parser for GitHub Flavored Markdown, a fully specified variant of
34Markdown. It includes sources for libcmark-gfm (0.29.0.gfm.0) and does
35not require prior installation of the C library.
36
37%package prof
38Summary: Profiling %{pkgname} library for GHC
39Summary(pl.UTF-8): Biblioteka profilująca %{pkgname} dla GHC
40Group: Development/Libraries
41Requires: %{name} = %{version}-%{release}
42
43%description prof
44Profiling %{pkgname} library for GHC. Should be installed when
45GHC's profiling subsystem is needed.
46
47%description prof -l pl.UTF-8
48Biblioteka profilująca %{pkgname} dla GHC. Powinna być zainstalowana
49kiedy potrzebujemy systemu profilującego z GHC.
50
51%prep
52%setup -q -n %{pkgname}-%{version}
53
54%build
55runhaskell Setup.hs configure -v2 \
56 %{?with_prof:--enable-library-profiling} \
57 --prefix=%{_prefix} \
58 --libdir=%{_libdir} \
59 --libexecdir=%{_libexecdir} \
60 --docdir=%{_docdir}/%{name}-%{version}
61
62runhaskell Setup.hs build
63runhaskell Setup.hs haddock --executables
64
65%install
66rm -rf $RPM_BUILD_ROOT
67install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
68
69runhaskell Setup.hs copy --destdir=$RPM_BUILD_ROOT
70
71# work around automatic haddock docs installation
72%{__rm} -rf %{name}-%{version}-doc
73cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
74%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
75
76runhaskell Setup.hs register \
77 --gen-pkg-config=$RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
78
79%clean
80rm -rf $RPM_BUILD_ROOT
81
82%post
83%ghc_pkg_recache
84
85%postun
86%ghc_pkg_recache
87
88%files
89%defattr(644,root,root,755)
90%doc README.md changelog %{name}-%{version}-doc/*
91%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
92%dir %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
93%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.so
94%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.a
95%exclude %{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
96
97%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.hi
98%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.dyn_hi
99
100%if %{with prof}
101%files prof
102%defattr(644,root,root,755)
103%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*_p.a
104%{_libdir}/%{ghcdir}/%{pkgname}-%{version}/*.p_hi
105%endif
This page took 0.07474 seconds and 4 git commands to generate.