1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/mercurial/mercurial.spec Fri Mar 11 21:30:26 2011 +0100 1.3 @@ -0,0 +1,87 @@ 1.4 +Summary: A fast, lightweight Source Control Management system 1.5 +Name: mercurial 1.6 +Version: snapshot 1.7 +Release: 0 1.8 +License: GPLv2+ 1.9 +Group: Development/Tools 1.10 +URL: http://mercurial.selenic.com/ 1.11 +Source0: http://mercurial.selenic.com/release/%{name}-%{version}.tar.gz 1.12 +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root 1.13 + 1.14 +# From the README: 1.15 +# 1.16 +# Note: some distributions fails to include bits of distutils by 1.17 +# default, you'll need python-dev to install. You'll also need a C 1.18 +# compiler and a 3-way merge tool like merge, tkdiff, or kdiff3. 1.19 +# 1.20 +# python-devel provides an adequate python-dev. The merge tool is a 1.21 +# run-time dependency. 1.22 +# 1.23 +BuildRequires: python >= 2.4, python-devel, make, gcc, python-docutils >= 0.5, gettext 1.24 +Provides: hg = %{version}-%{release} 1.25 +Requires: python >= 2.4 1.26 +# The hgk extension uses the wish tcl interpreter, but we don't enforce it 1.27 +#Requires: tk 1.28 + 1.29 +%define pythonver %(python -c 'import sys;print ".".join(map(str, sys.version_info[:2]))') 1.30 +%define emacs_lispdir %{_datadir}/emacs/site-lisp 1.31 + 1.32 +%description 1.33 +Mercurial is a fast, lightweight source control management system designed 1.34 +for efficient handling of very large distributed projects. 1.35 + 1.36 +%prep 1.37 +%setup -q 1.38 + 1.39 +%build 1.40 +make all 1.41 + 1.42 +%install 1.43 +rm -rf $RPM_BUILD_ROOT 1.44 +make install DESTDIR=$RPM_BUILD_ROOT PREFIX=%{_prefix} MANDIR=%{_mandir} 1.45 + 1.46 +install -m 755 contrib/hgk $RPM_BUILD_ROOT%{_bindir} 1.47 +install -m 755 contrib/hg-ssh $RPM_BUILD_ROOT%{_bindir} 1.48 + 1.49 +bash_completion_dir=$RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d 1.50 +mkdir -p $bash_completion_dir 1.51 +install -m 644 contrib/bash_completion $bash_completion_dir/mercurial.sh 1.52 + 1.53 +zsh_completion_dir=$RPM_BUILD_ROOT%{_datadir}/zsh/site-functions 1.54 +mkdir -p $zsh_completion_dir 1.55 +install -m 644 contrib/zsh_completion $zsh_completion_dir/_mercurial 1.56 + 1.57 +mkdir -p $RPM_BUILD_ROOT%{emacs_lispdir} 1.58 +install -m 644 contrib/mercurial.el $RPM_BUILD_ROOT%{emacs_lispdir} 1.59 +install -m 644 contrib/mq.el $RPM_BUILD_ROOT%{emacs_lispdir} 1.60 + 1.61 +mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/mercurial/hgrc.d 1.62 +install -m 644 contrib/mergetools.hgrc $RPM_BUILD_ROOT%{_sysconfdir}/mercurial/hgrc.d/mergetools.rc 1.63 + 1.64 +%clean 1.65 +rm -rf $RPM_BUILD_ROOT 1.66 + 1.67 +%files 1.68 +%defattr(-,root,root,-) 1.69 +%doc CONTRIBUTORS COPYING doc/README doc/hg*.txt doc/hg*.html *.cgi contrib/*.fcgi 1.70 +%doc %attr(644,root,root) %{_mandir}/man?/hg* 1.71 +%doc %attr(644,root,root) contrib/*.svg contrib/sample.hgrc 1.72 +%dir %{_datadir}/zsh/ 1.73 +%dir %{_datadir}/zsh/site-functions/ 1.74 +%{_datadir}/zsh/site-functions/_mercurial 1.75 +%dir %{_datadir}/emacs/site-lisp/ 1.76 +%{_datadir}/emacs/site-lisp/mercurial.el 1.77 +%{_datadir}/emacs/site-lisp/mq.el 1.78 +%{_bindir}/hg 1.79 +%{_bindir}/hgk 1.80 +%{_bindir}/hg-ssh 1.81 +%dir %{_sysconfdir}/bash_completion.d/ 1.82 +%config(noreplace) %{_sysconfdir}/bash_completion.d/mercurial.sh 1.83 +%dir %{_sysconfdir}/mercurial 1.84 +%dir %{_sysconfdir}/mercurial/hgrc.d 1.85 +%config(noreplace) %{_sysconfdir}/mercurial/hgrc.d/mergetools.rc 1.86 +%if "%{?pythonver}" != "2.4" 1.87 +%{_libdir}/python%{pythonver}/site-packages/%{name}-*-py%{pythonver}.egg-info 1.88 +%endif 1.89 +%{_libdir}/python%{pythonver}/site-packages/%{name} 1.90 +%{_libdir}/python%{pythonver}/site-packages/hgext