]> git.pld-linux.org Git - packages/darcs.git/blob - darcs.spec
707e4f17135c71bad5fb43b6cc838f28d1880481
[packages/darcs.git] / darcs.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # build without tests
4 #
5 Summary:        David's Advanced Revision Control System - yet another replacement for CVS
6 Summary(pl.UTF-8):      David's Advanced Revision Control System - jeszcze jeden zamiennik CVS-a
7 Name:           darcs
8 Version:        2.5.2
9 Release:        0.1
10 License:        GPL v2
11 Group:          Development/Version Control
12 Source0:        http://darcs.net/releases/%{name}-%{version}.tar.gz
13 # Source0-md5:  491b6ca01dec245a16112ad2c7e07dc1
14 Patch0:         %{name}-ghc72.patch
15 Patch1:         %{name}-relax-regex-libs-deps.patch
16 Patch2:         %{name}-tests-ghc72.patch
17 URL:            http://darcs.net/
18 BuildRequires:  curl-devel >= 7.19.1
19 BuildRequires:  ghc >= 6.12.3
20 BuildRequires:  ghc-hashed-storage >= 0.5
21 BuildRequires:  ghc-haskeline >= 0.6.1
22 BuildRequires:  ghc-mmap >= 1:0.5
23 BuildRequires:  ghc-terminfo >= 0.3
24 BuildRequires:  ghc-utf8-string >= 0.3
25 BuildRequires:  ghc-zlib >= 0.5.1.0
26 BuildRequires:  gmp-devel
27 BuildRequires:  pkgconfig
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 %define         ghcdir          ghc-%(/usr/bin/ghc --numeric-version)
31
32 %description
33 David's Advanced Revision Control System is yet another replacement
34 for CVS. It is written in Haskell, and has been used on Linux, MacOS
35 X, FreeBSD, OpenBSD and Microsoft Windows. Darcs includes a CGI
36 script, which can be used to view the contents of your repository.
37
38 %description -l pl.UTF-8
39 David's Advanced Revision Control System (zaawansowany system kontroli
40 wersji Davida) to jeszcze jeden zamiennik CVS-a. Jest napisany w
41 Haskellu, dotychczas był używany na Linuksie, MacOS-ie X, FreeBSD,
42 OpenBSD i Microsoft Windows. Darcs zawiera skrypt CGI, który może być
43 używany do oglądania zawartości repozytorium.
44
45 %package -n bash-completion-darcs
46 Summary:        bash-completion for darcs
47 Summary(pl.UTF-8):      bashowe uzupełnianie nazw dla darcsa
48 Group:          Applications/Shells
49 Requires:       bash-completion
50
51 %description -n bash-completion-darcs
52 This package provides bash-completion for darcs.
53
54 %description -n bash-completion-darcs -l pl.UTF-8
55 Pakiet ten dostarcza bashowe uzupełnianie nazw dla darcsa.
56
57 %prep
58 %setup -q
59 %patch0 -p1
60 %patch1 -p1
61 %patch2 -p1
62
63 %build
64 runhaskell Setup.lhs configure -v2 \
65         --prefix=%{_prefix} \
66         --libdir=%{_libdir} \
67         --libexecdir=%{_libexecdir} \
68         --docdir=%{_docdir}/%{name}-%{version} \
69         --flags="curl curl-pipelining terminfo color mmap"
70
71 runhaskell Setup.lhs build
72 %{?with_tests:runhaskell Setup.lhs test}
73
74 runhaskell Setup.lhs haddock --executables \
75         --css=doc/darcs.css
76
77 %install
78 rm -rf $RPM_BUILD_ROOT
79
80 runhaskell Setup.lhs copy --destdir=$RPM_BUILD_ROOT
81
82 # work around automatic haddock docs installation
83 rm -rf %{name}-%{version}-doc
84 cp -a $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version} %{name}-%{version}-doc
85
86 # bash completion
87 install -d $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d
88 install -p contrib/darcs_completion $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d/%{name}
89
90 # we only want the binary
91 rm -r $RPM_BUILD_ROOT/%{_libdir}/%{ghcdir}
92
93 %clean
94 rm -rf $RPM_BUILD_ROOT
95
96 %files
97 %defattr(644,root,root,755)
98 %doc NEWS README
99 %doc %{name}-%{version}-doc/html
100 %attr(755,root,root) %{_bindir}/*
101 %{_mandir}/man1/*
102
103 %files -n bash-completion-darcs
104 %defattr(644,root,root,755)
105 %{_sysconfdir}/bash_completion.d/%{name}
This page took 0.029157 seconds and 2 git commands to generate.