[packages/python-breathe] - updated to 4.2.0 - enabled (nose) tests

qboosh qboosh at pld-linux.org
Sat May 14 20:30:59 CEST 2016


commit c6364fe133c14629cc6e9d24ab3245047c541b53
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sat May 14 20:31:07 2016 +0200

    - updated to 4.2.0
    - enabled (nose) tests

 python-breathe.spec | 61 ++++++++++++++++++++++++++++++++++++++++-------------
 1 file changed, 46 insertions(+), 15 deletions(-)
---
diff --git a/python-breathe.spec b/python-breathe.spec
index 3593999..3fb4911 100644
--- a/python-breathe.spec
+++ b/python-breathe.spec
@@ -1,30 +1,41 @@
 #
 # Conditional build:
-%bcond_with	tests	# do not perform "make test"
+%bcond_without	tests	# nose tests
 %bcond_without	python2 # CPython 2.x module
 %bcond_without	python3 # CPython 3.x module
 
 Summary:	Sphinx Doxygen renderer
 Summary(pl.UTF-8):	Renderer Doxygena dla systemu dokumentacji Sphinx
 Name:		python-breathe
-Version:	1.0.0
-Release:	3
+Version:	4.2.0
+Release:	1
 License:	BSD
 Group:		Development/Languages/Python
+#Source0Download: https://github.com/michaeljones/breathe/releases
 Source0:	https://github.com/michaeljones/breathe/archive/v%{version}/%{name}-%{version}.tar.gz
-# Source0-md5:	a1617f9cb555bbd618257d70e577909f
+# Source0-md5:	790672f9f192ac43ac183eb1a741a0b7
 URL:		https://github.com/michaeljones/breathe
-BuildRequires:	python >= 1:2.5
 %if %{with python2}
-BuildRequires:	python-modules
+BuildRequires:	python-modules >= 1:2.5
+%if %{with tests}
+BuildRequires:	python-Sphinx >= 1.0.7
+BuildRequires:	python-docutils >= 0.5
+BuildRequires:	python-nose
+BuildRequires:	python-six >= 1.4
+%endif
 %endif
 %if %{with python3}
-BuildRequires:	python3-modules
+BuildRequires:	python3-2to3 >= 1:3.2
+BuildRequires:	python3-modules >= 1:3.2
+%if %{with tests}
+BuildRequires:	python3-Sphinx >= 1.0.7
+BuildRequires:	python3-docutils >= 0.5
+BuildRequires:	python3-nose
+BuildRequires:	python3-six >= 1.4
+%endif
 %endif
 BuildRequires:	rpm-pythonprov
 BuildRequires:	rpmbuild(macros) >= 1.710
-Requires:	python-Sphinx >= 1.0.7
-Requires:	python-docutils >= 0.5
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -41,8 +52,6 @@ Summary:	Sphinx Doxygen renderer
 Summary(pl.UTF-8):	Renderer Doxygena dla systemu dokumentacji Sphinx
 Group:		Libraries/Python
 Requires:	python3-modules
-Requires:	python3-Sphinx >= 1.0.7
-Requires:	python3-docutils >= 0.5
 
 %description -n python3-breathe
 Breathe is an extension to reStructuredText and Sphinx to be able to
@@ -57,11 +66,25 @@ Sphinx, pozwalające na odczyt i renderowanie wyjścia XML z Doxygena.
 
 %build
 %if %{with python2}
-%py_build %{?with_tests:test}
+%py_build
+
+%if %{with tests}
+cd tests
+PYTHONPATH=.. \
+nosetests-%{py_ver}
+cd ..
+%endif
 %endif
 
 %if %{with python3}
-%py3_build %{?with_tests:test}
+%py3_build
+
+%if %{with tests}
+cd tests
+PYTHONPATH=.. \
+nosetests-%{py3_ver}
+cd ..
+%endif
 %endif
 
 %install
@@ -71,10 +94,15 @@ rm -rf $RPM_BUILD_ROOT
 %py_install
 
 %py_postclean
+
+%{__mv} $RPM_BUILD_ROOT%{_bindir}/breathe-apidoc{,-2}
 %endif
 
 %if %{with python3}
 %py3_install
+
+%{__mv} $RPM_BUILD_ROOT%{_bindir}/breathe-apidoc{,-3}
+ln -sf breathe-apidoc-3 $RPM_BUILD_ROOT%{_bindir}/breathe-apidoc
 %endif
 
 %clean
@@ -82,12 +110,15 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc LICENCE README.rst
+%doc LICENSE README.rst
+%attr(755,root,root) %{_bindir}/breathe-apidoc-2
 %{py_sitescriptdir}/breathe
 %{py_sitescriptdir}/breathe-%{version}-py*.egg-info
 
 %files -n python3-breathe
 %defattr(644,root,root,755)
-%doc LICENCE README.rst
+%doc LICENSE README.rst
+%attr(755,root,root) %{_bindir}/breathe-apidoc
+%attr(755,root,root) %{_bindir}/breathe-apidoc-3
 %{py3_sitescriptdir}/breathe
 %{py3_sitescriptdir}/breathe-%{version}-py*.egg-info
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-breathe.git/commitdiff/c6364fe133c14629cc6e9d24ab3245047c541b53



More information about the pld-cvs-commit mailing list