[packages/python-repoguard] cleanups, py3 files

glen glen at pld-linux.org
Tue Feb 18 21:17:19 CET 2014


commit e3f18b9d1a957be4f0aab4e36bd4994ac9e68ca7
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Tue Feb 18 22:17:16 2014 +0200

    cleanups, py3 files

 python-repoguard.spec | 39 +++++++++++++++++++++++----------------
 1 file changed, 23 insertions(+), 16 deletions(-)
---
diff --git a/python-repoguard.spec b/python-repoguard.spec
index e83c156..59a6c6d 100644
--- a/python-repoguard.spec
+++ b/python-repoguard.spec
@@ -1,12 +1,17 @@
-#
+# TODO
+# - configure proper prefix and package:
+#        /usr/cfg/templates/default.tpl.conf
+#        /usr/cfg/templates/python.tpl.conf
+#        /usr/local/share/repoguard/logger.conf
+#        /usr/local/share/repoguard/repoguard.conf
+
 # Conditional build:
 %bcond_without	python2		# Python 2.x module
 %bcond_with	python3		# Python 3.x module
-#
+
 %define	module	repoguard
-#
 Summary:	A framework for Subversion commit hooks
-Name:		python-repoguard
+Name:		python-%{module}
 Version:	0.2.0
 Release:	0.1
 License:	APL
@@ -14,18 +19,17 @@ Group:		Development/Version Control
 Source0:	http://repoguard.tigris.org/files/documents/6497/48735/repoguard-%{version}.tar
 # Source0-md5:	b7036d436e819576917daa3bca0f2482
 URL:		http://repoguard.tigris.org/
+BuildRequires:	rpm-pythonprov
 %if %{with python2}
 BuildRequires:	python-devel
 BuildRequires:	python-modules
-Requires:	python
-Requires:	python-configobj
 %endif
 %if %{with python3}
 BuildRequires:	python3-2to3
 BuildRequires:	python3-devel
 BuildRequires:	python3-modules
 %endif
-BuildRequires:	rpm-pythonprov
+Requires:	python-configobj
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -34,10 +38,9 @@ RepoGuard is an advanced validation framework with built-in
 integrations for several common version control systems. It is the
 successor of the SVNChecker framework.
 
-%package -n	python3-%{module}
+%package -n python3-%{module}
 Summary:	A framework for Subversion commit hooks
 Group:		Libraries/Python
-Requires:	python3
 Requires:	python3-configobj
 
 %description -n python3-%{module}
@@ -50,17 +53,17 @@ successor of the SVNChecker framework.
 
 %build
 %if %{with python2}
-%{__python} ./setup.py build --build-base py2
+%{__python} setup.py build --build-base py2
 %endif
 %if %{with python3}
-%{__python3} ./setup.py build --build-base py3
+%{__python3} setup.py build --build-base py3
 %endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
 %if %{with python2}
 install -d $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
-%{__python} ./setup.py build \
+%{__python} setup.py build \
 	--build-base py2 \
 	install \
 	--optimize 2 \
@@ -69,7 +72,7 @@ install -d $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
 
 %if %{with python3}
 install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
-%{__python3} ./setup.py build \
+%{__python3} setup.py build \
 	--build-base py3 \
 	install \
 	--optimize 2 \
@@ -83,14 +86,18 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc CHANGES README
-%{_examplesdir}/python-%{module}-%{version}
 %attr(755,root,root) %{_bindir}/repoguard
 %{py_sitescriptdir}/%{module}
-%{py_sitescriptdir}/*egg-info
-%{py_sitescriptdir}/*nspkg.pth
+%{py_sitescriptdir}/%{module}-%{version}-py*-nspkg.pth
+%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%{_examplesdir}/python-%{module}-%{version}
 %endif
 
 %if %{with python3}
 %files -n python3-%{module}
 %defattr(644,root,root,755)
+%{py3_sitescriptdir}/%{module}
+%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%{py3_sitescriptdir}/%{module}-%{version}-py*-nspkg.pth
+%{_examplesdir}/python3-%{module}-%{version}
 %endif
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-repoguard.git/commitdiff/e3f18b9d1a957be4f0aab4e36bd4994ac9e68ca7



More information about the pld-cvs-commit mailing list