[projects/template-specs] python: use pypi_name macro in files as well

glen glen at pld-linux.org
Sun Jun 25 11:18:15 CEST 2017


commit b785d0c94b9d46115122cd314806c45b3b82b4b4
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Sun Jun 25 12:18:00 2017 +0300

    python: use pypi_name macro in files as well

 python.spec | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/python.spec b/python.spec
index e9beeae..b88a95a 100644
--- a/python.spec
+++ b/python.spec
@@ -48,15 +48,15 @@ BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description -l pl.UTF-8
 
-%package -n python3-%{module}
+%package -n python3-%{pypi_name}
 Summary:	-
 Summary(pl.UTF-8):	-
 Group:		Libraries/Python
 Requires:	python3-modules
 
-%description -n python3-%{module}
+%description -n python3-%{pypi_name}
 
-%description -n python3-%{module} -l pl.UTF-8
+%description -n python3-%{pypi_name} -l pl.UTF-8
 
 %package apidocs
 Summary:	API documentation for Python %{module} module
@@ -117,9 +117,9 @@ find $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version} -name '*.py' \
 	| xargs sed -i '1s|^#!.*python\b|#!%{__python}|'
 %endif
 %if %{with python3}
-install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
-cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
-find $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version} -name '*.py' \
+install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{pypi_name}-%{version}
+cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/python3-%{pypi_name}-%{version}
+find $RPM_BUILD_ROOT%{_examplesdir}/python3-%{pypi_name}-%{version} -name '*.py' \
 	| xargs sed -i '1s|^#!.*python\b|#!%{__python3}|'
 %endif
 
@@ -136,12 +136,12 @@ rm -rf $RPM_BUILD_ROOT
 %endif
 
 %if %{with python3}
-%files -n python3-%{module}
+%files -n python3-%{pypi_name}
 %defattr(644,root,root,755)
 %doc AUTHORS CHANGES LICENSE
 %{py3_sitescriptdir}/%{module}
 %{py3_sitescriptdir}/%{egg_name}-%{version}-py*.egg-info
-%{_examplesdir}/python3-%{module}-%{version}
+%{_examplesdir}/python3-%{pypi_name}-%{version}
 %endif
 
 %if %{with doc}
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/template-specs.git/commitdiff/b785d0c94b9d46115122cd314806c45b3b82b4b4



More information about the pld-cvs-commit mailing list