]> git.pld-linux.org Git - SPECS.git/blob - ghc-haskeline.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / ghc-haskeline.spec
1 %define         pkgname haskeline
2 Summary:        A command-line interface for user input, written in Haskell
3 Name:           ghc-%{pkgname}
4 Version:        0.7.0.3
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:  3a78043dc80b5510202e71e77c0a9923
10 URL:            http://hackage.haskell.org/package/haskeline/
11 BuildRequires:  ghc >= 6.12.3
12 BuildRequires:  ghc-mtl
13 BuildRequires:  ghc-utf8-string >= 0.3.6
14 BuildRequires:  gmp-devel
15 BuildRequires:  rpmbuild(macros) >= 1.608
16 Requires:       ghc-mtl
17 Requires:       ghc-utf8-string >= 0.3.6
18 %requires_eq    ghc
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 # debuginfo is not useful for ghc
22 %define         _enable_debug_packages  0
23
24 %description
25 Haskeline provides a user interface for line input in command-line
26 programs. This library is similar in purpose to readline, but since it
27 is written in Haskell it is (hopefully) more easily used in other
28 Haskell programs.
29
30 %package doc
31 Summary:        HTML documentation for %{pkgname}
32 Summary(pl.UTF-8):      Dokumentacja w formacie HTML dla %{pkgname}
33 Group:          Documentation
34
35 %description doc
36 HTML documentation for %{pkgname}.
37
38 %description doc -l pl.UTF-8
39 Dokumentacja w formacie HTML dla %{pkgname}.
40
41 %prep
42 %setup -q -n %{pkgname}-%{version}
43
44 %build
45 runhaskell Setup.hs configure -v2 \
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}/html %{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 CHANGES
80 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
81 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
82
83 %files doc
84 %defattr(644,root,root,755)
85 %doc %{name}-%{version}-doc/*
This page took 1.018646 seconds and 3 git commands to generate.