##// END OF EJS Templates
Make RPM spec in contrib more aligned with the one from Fedora...
Mads Kiilerich -
r8942:51038bb5 default
parent child Browse files
Show More
@@ -2,10 +2,10 b' Summary: Mercurial -- a distributed SCM'
2 Name: mercurial
2 Name: mercurial
3 Version: snapshot
3 Version: snapshot
4 Release: 0
4 Release: 0
5 License: GPL
5 License: GPLv2
6 Group: Development/Tools
6 Group: Development/Tools
7 Source: http://mercurial.selenic.com/release/%{name}-%{version}.tar.gz
7 URL: http://mercurial.selenic.com/
8 URL: http://mercurial.selenic.com
8 Source0: http://mercurial.selenic.com/release/%{name}-%{version}.tar.gz
9 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
9 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
10
10
11 # From the README:
11 # From the README:
@@ -18,10 +18,10 b' BuildRoot: %{_tmppath}/%{name}-%{version'
18 # run-time dependency.
18 # run-time dependency.
19 #
19 #
20 BuildRequires: python >= 2.4, python-devel, make, gcc, asciidoc, xmlto
20 BuildRequires: python >= 2.4, python-devel, make, gcc, asciidoc, xmlto
21 Provides: hg = %{version}-%{release}
21
22
22 %define pythonver %(python -c 'import sys;print ".".join(map(str, sys.version_info[:2]))')
23 %define pythonver %(python -c 'import sys;print ".".join(map(str, sys.version_info[:2]))')
23 %define pythonlib %{_libdir}/python%{pythonver}/site-packages/%{name}
24 %define emacs_lispdir %{_datadir}/emacs/site-lisp
24 %define hgext %{_libdir}/python%{pythonver}/site-packages/hgext
25
25
26 %description
26 %description
27 Mercurial is a fast, lightweight source control management system designed
27 Mercurial is a fast, lightweight source control management system designed
@@ -45,23 +45,26 b' install contrib/git-viz/{hg-viz,git-rev-'
45
45
46 bash_completion_dir=$RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d
46 bash_completion_dir=$RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d
47 mkdir -p $bash_completion_dir
47 mkdir -p $bash_completion_dir
48 install contrib/bash_completion $bash_completion_dir/mercurial.sh
48 install -m 644 contrib/bash_completion $bash_completion_dir/mercurial.sh
49
49
50 zsh_completion_dir=$RPM_BUILD_ROOT%{_datadir}/zsh/site-functions
50 zsh_completion_dir=$RPM_BUILD_ROOT%{_datadir}/zsh/site-functions
51 mkdir -p $zsh_completion_dir
51 mkdir -p $zsh_completion_dir
52 install contrib/zsh_completion $zsh_completion_dir/_mercurial
52 install -m 644 contrib/zsh_completion $zsh_completion_dir/_mercurial
53
53
54 lisp_dir=$RPM_BUILD_ROOT%{_datadir}/emacs/site-lisp
54 mkdir -p $RPM_BUILD_ROOT%{emacs_lispdir}
55 mkdir -p $lisp_dir
55 install contrib/mercurial.el $RPM_BUILD_ROOT%{emacs_lispdir}
56 install contrib/mercurial.el $lisp_dir
56
57 mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/mercurial/hgrc.d
58 install contrib/mergetools.hgrc $RPM_BUILD_ROOT%{_sysconfdir}/mercurial/hgrc.d/mergetools.rc
57
59
58 %clean
60 %clean
59 rm -rf $RPM_BUILD_ROOT
61 rm -rf $RPM_BUILD_ROOT
60
62
61 %files
63 %files
62 %defattr(-,root,root,-)
64 %defattr(-,root,root,-)
63 %doc CONTRIBUTORS COPYING doc/README doc/hg*.txt doc/hg*.html doc/ja *.cgi
65 %doc CONTRIBUTORS COPYING doc/README doc/hg*.txt doc/hg*.html doc/ja *.cgi contrib/*.fcgi
64 %{_mandir}/man?/hg*.gz
66 %doc %attr(644,root,root) %{_mandir}/man?/hg*.gz
67 %doc %attr(644,root,root) contrib/*.svg contrib/sample.hgrc
65 %{_sysconfdir}/bash_completion.d/mercurial.sh
68 %{_sysconfdir}/bash_completion.d/mercurial.sh
66 %{_datadir}/zsh/site-functions/_mercurial
69 %{_datadir}/zsh/site-functions/_mercurial
67 %{_datadir}/emacs/site-lisp/mercurial.el
70 %{_datadir}/emacs/site-lisp/mercurial.el
@@ -71,8 +74,13 b' rm -rf $RPM_BUILD_ROOT'
71 %{_bindir}/hg-viz
74 %{_bindir}/hg-viz
72 %{_bindir}/git-rev-tree
75 %{_bindir}/git-rev-tree
73 %{_bindir}/mercurial-convert-repo
76 %{_bindir}/mercurial-convert-repo
77 %dir %{_sysconfdir}/bash_completion.d/
78 %dir %{_datadir}/zsh/site-functions/
79 %dir %{_sysconfdir}/mercurial
80 %dir %{_sysconfdir}/mercurial/hgrc.d
81 %config(noreplace) %{_sysconfdir}/mercurial/hgrc.d/mergetools.rc
74 %if "%{?pythonver}" != "2.4"
82 %if "%{?pythonver}" != "2.4"
75 %{_libdir}/python%{pythonver}/site-packages/%{name}-*-py%{pythonver}.egg-info
83 %{_libdir}/python%{pythonver}/site-packages/%{name}-*-py%{pythonver}.egg-info
76 %endif
84 %endif
77 %{pythonlib}
85 %{_libdir}/python%{pythonver}/site-packages/%{name}
78 %{hgext}
86 %{_libdir}/python%{pythonver}/site-packages/hgext
General Comments 0
You need to be logged in to leave comments. Login now