diff --git a/bzr-icon-64.png b/bzr-icon-64.png new file mode 100644 index 0000000..9dd8d07 Binary files /dev/null and b/bzr-icon-64.png differ diff --git a/bzr-old-sphinx.patch b/bzr-old-sphinx.patch new file mode 100644 index 0000000..055d87f --- /dev/null +++ b/bzr-old-sphinx.patch @@ -0,0 +1,95 @@ +=== modified file 'doc/en/Makefile' +--- doc/en/Makefile 2009-09-08 12:33:30 +0000 ++++ doc/en/Makefile 2010-03-25 10:09:32 +0000 +@@ -11,6 +11,22 @@ + PAPEROPT_letter = -D latex_paper_size=letter + ALLSPHINXOPTS = -d _build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . + ++# Note that this assumes name of the output dir is same as name of the rule. ++define make_output_dirs ++# Create output directory (only needed for sphinx < 0.5) ++[ -d _build ] || mkdir _build ++[ -d "_build/$@" ] || mkdir "_build/$@" ++# Workaround for a bug in sphinx < 0.5 where it tries to delete ++# nonexistent static dirs and does not catch the exception. This was ++# fixed in svn+ssh://pythondev@svn.python.org/doctools/branches/0.4.x ++# at r65551 and merged as 280b62246342 in hg branch released as 0.5. ++[ -d "_build/$@/_static" ] || mkdir "_build/$@/_static" ++for fn in _static/*; do \ ++ [ ! -d "$$fn" ] && continue; \ ++ [ -d "_build/$@/$$fn" ] || mkdir "_build/$@/$$fn"; \ ++done ++endef ++ + .PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest + + help: +@@ -30,32 +46,38 @@ + -rm -rf _build/* + + html: ++ $(make_output_dirs) + $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) _build/html + @echo + @echo "Build finished. The HTML pages are in _build/html." + + dirhtml: ++ $(make_output_dirs) + $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) _build/dirhtml + @echo + @echo "Build finished. The HTML pages are in _build/dirhtml." + + pickle: ++ $(make_output_dirs) + $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) _build/pickle + @echo + @echo "Build finished; now you can process the pickle files." + + json: ++ $(make_output_dirs) + $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) _build/json + @echo + @echo "Build finished; now you can process the JSON files." + + htmlhelp: ++ $(make_output_dirs) + $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) _build/htmlhelp + @echo + @echo "Build finished; now you can run HTML Help Workshop with the" \ + ".hhp project file in _build/htmlhelp." + + qthelp: ++ $(make_output_dirs) + $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) _build/qthelp + @echo + @echo "Build finished; now you can run "qcollectiongenerator" with the" \ +@@ -65,6 +87,7 @@ + @echo "# assistant -collectionFile _build/qthelp/Bazaar.qhc" + + latex: ++ $(make_output_dirs) + $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) _build/latex + @echo + @echo "Build finished; the LaTeX files are in _build/latex." +@@ -72,17 +95,20 @@ + "run these through (pdf)latex." + + changes: ++ $(make_output_dirs) + $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) _build/changes + @echo + @echo "The overview file is in _build/changes." + + linkcheck: ++ $(make_output_dirs) + $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) _build/linkcheck + @echo + @echo "Link check complete; look for any errors in the above output " \ + "or in _build/linkcheck/output.txt." + + doctest: ++ $(make_output_dirs) + $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) _build/doctest + @echo "Testing of doctests in the sources finished, look at the " \ + "results in _build/doctest/output.txt." + diff --git a/bzr.spec b/bzr.spec index 54e66c8..21ebc81 100644 --- a/bzr.spec +++ b/bzr.spec @@ -1,4 +1,8 @@ -%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} +# It's not strictly necessary to conditionalize this but it's a reminder of +# when it can go away +%if 0%{?fedora} < 13 && 0%{?rhel} < 6 +%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} +%endif # All package versioning is found here: # the actual version is composed from these below, including leading 0 for release candidates @@ -9,10 +13,10 @@ %define bzrmajor 2.1 %define bzrminor .1 #define bzrrc rc2 -%define release 1 +%define release 2 # Magics to get the dots in Release string correct per the above -%define subrelease %{?bzrrc:.}%{?bzrrc} +%global subrelease %{?bzrrc:.}%{?bzrrc} Name: bzr Version: %{bzrmajor}%{?bzrminor} @@ -24,6 +28,8 @@ License: GPLv2+ URL: http://www.bazaar-vcs.org/ Source0: https://launchpad.net/%{name}/%{bzrmajor}/%{version}%{?bzrrc}/+download/%{name}-%{version}%{?bzrrc}.tar.gz Source1: https://launchpad.net/%{name}/%{bzrmajor}/%{version}%{?bzrrc}/+download/%{name}-%{version}%{?bzrrc}.tar.gz.sig +Source2: bzr-icon-64.png +Patch0: bzr-old-sphinx.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel zlib-devel @@ -35,6 +41,11 @@ BuildRequires: python-sphinx Requires: python-paramiko # Workaround Bug #230223 otherwise this would be a soft dependency Requires: python-pycurl +# ElementTree is part of python2.5 so only needed for EL-5 +%if 0%{?rhel} && 0%{?rhel} <= 5 +BuildRequires: python-elementtree +Requires: python-elementtree +%endif %description Bazaar is a distributed revision control system that is powerful, friendly, @@ -54,6 +65,8 @@ This package contains the documentation for the Bazaar version control system. %prep %setup -q -n %{name}-%{version}%{?bzrrc} +%patch0 -p0 -b .oldsphinx + sed -i '1{/#![[:space:]]*\/usr\/bin\/\(python\|env\)/d}' bzrlib/_patiencediff_py.py sed -i '1{/#![[:space:]]*\/usr\/bin\/\(python\|env\)/d}' bzrlib/weave.py @@ -69,8 +82,10 @@ make docs-sphinx %install rm -rf $RPM_BUILD_ROOT %{__python} setup.py install --skip-build --install-data %{_datadir} --root $RPM_BUILD_ROOT -chmod 0644 contrib/bzr_access +chmod -R a+rX contrib +chmod 0644 contrib/debian/init.d chmod 0644 contrib/bzr_ssh_path_limiter +chmod 0644 contrib/bzr_access chmod 0755 $RPM_BUILD_ROOT%{python_sitearch}/bzrlib/*.so install -d $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d/ @@ -99,6 +114,9 @@ for dir in *; do done cd .. +install -d $RPM_BUILD_ROOT%{_datadir}/pixmaps +install -m 0644 %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/pixmaps/bzr.png + %clean rm -rf $RPM_BUILD_ROOT @@ -110,13 +128,24 @@ rm -rf $RPM_BUILD_ROOT %{_mandir}/man1/* %{python_sitearch}/bzrlib/ %{_sysconfdir}/bash_completion.d/ +%{_datadir}/pixmaps/bzr.png +%if 0%{?fedora} || 0%{?rhel} > 5 %{python_sitearch}/*.egg-info +%endif %files doc %defattr(-,root,root,-) %doc %{_defaultdocdir}/%{name}-doc-%{version}/* %changelog +* Mon May 31 2010 Toshio Kuratomi - 2.1.1-2 +- Add an icon for bzr. This lets the gtk and qbzr plugins share the same icon + for things like associating an image with a file type. +- Clean up rhel/fedora conditionals bz#537254 +- Clean up some rpmlint warnings +- Fixes so this spec file will also build on EL-5 +- define => global + * Tue Mar 30 2010 Henrik Nordstrom - 2.1.1-1 - Upstream 2.1.1 bugfix release