]> git.pld-linux.org Git - packages/ghc-tar.git/blob - ghc-tar.spec
aff5658fc1f10753ac9401c2c37b56748d3e0289
[packages/ghc-tar.git] / ghc-tar.spec
1 %define         pkgname tar
2 Summary:        Library for working with ".tar" archive files
3 Name:           ghc-%{pkgname}
4 Version:        0.4.0.1
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:  a037976a434d6a55cad3e07f54686ffd
10 URL:            http://hackage.haskell.org/package/tar/
11 BuildRequires:  ghc >= 6.12.3
12 BuildRequires:  rpmbuild(macros) >= 1.608
13 %requires_eq    ghc
14 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
15
16 # debuginfo is not useful for ghc
17 %define         _enable_debug_packages  0
18
19 %description
20 This library is for working with ".tar" archive files. It can read
21 and write a range of common variations of archive format including
22 V7, USTAR, POSIX and GNU formats. It provides support for packing
23 and unpacking portable archives. This makes it suitable for
24 distribution but not backup because details like file ownership and
25 exact permissions are not preserved.
26
27 %package doc
28 Summary:        HTML documentation for %{pkgname}
29 Summary(pl.UTF-8):      Dokumentacja w formacie HTML dla %{pkgname}
30 Group:          Documentation
31
32 %description doc
33 HTML documentation for %{pkgname}.
34
35 %description doc -l pl.UTF-8
36 Dokumentacja w formacie HTML dla %{pkgname}.
37
38 %prep
39 %setup -q -n %{pkgname}-%{version}
40
41 %build
42 runhaskell Setup.lhs configure -v2 \
43         --prefix=%{_prefix} \
44         --libdir=%{_libdir} \
45         --libexecdir=%{_libexecdir} \
46         --docdir=%{_docdir}/%{name}-%{version}
47
48 runhaskell Setup.lhs build
49 runhaskell Setup.lhs haddock --executables
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53 install -d $RPM_BUILD_ROOT%{_libdir}/%{ghcdir}/package.conf.d
54
55 runhaskell Setup.lhs copy --destdir=$RPM_BUILD_ROOT
56
57 # work around automatic haddock docs installation
58 %{__rm} -rf %{name}-%{version}-doc
59 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}/html %{name}-%{version}-doc
60 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
61
62 runhaskell Setup.lhs register \
63         --gen-pkg-config=$RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
64
65 %clean
66 rm -rf $RPM_BUILD_ROOT
67
68 %post
69 %ghc_pkg_recache
70
71 %postun
72 %ghc_pkg_recache
73
74 %files
75 %defattr(644,root,root,755)
76 %{_libdir}/%{ghcdir}/package.conf.d/%{pkgname}.conf
77 %{_libdir}/%{ghcdir}/%{pkgname}-%{version}
78
79 %files doc
80 %defattr(644,root,root,755)
81 %doc %{name}-%{version}-doc/*
This page took 0.083001 seconds and 2 git commands to generate.