[packages/python-django] remove custom compilation

glen glen at pld-linux.org
Mon Jun 27 23:22:36 CEST 2016


commit 755530bfa1fb2cb69e07c3ca2f710b8545e1fa15
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Tue Jun 28 00:06:34 2016 +0300

    remove custom compilation
    
    install already compiles, and no idea what the "fix" was in 3ef44b33
    currently there are no files matching rpm build root
    
    doc cleanup

 python-django.spec | 27 ++++++++-------------------
 1 file changed, 8 insertions(+), 19 deletions(-)
---
diff --git a/python-django.spec b/python-django.spec
index ffa40b2..dea9257 100644
--- a/python-django.spec
+++ b/python-django.spec
@@ -75,17 +75,21 @@ Dokumentacja do Django.
 %if %{with python2}
 %py_build
 %endif
+
 %{__make} -C docs html
+rm -r docs/_build/html/_sources
+
 %if %{with python3}
 %py3_build
 %endif
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_docdir}
-
 %if %{with python2}
 %py_install
+%py_postclean
+find $RPM_BUILD_ROOT%{py_sitescriptdir} -type f -path '*_template*' -a -name '*.py[oc]' | xargs rm
+
 mv $RPM_BUILD_ROOT%{_bindir}/{django-admin.py,py2-django-admin}
 # default to python2 if built
 ln -sf py2-django-admin $RPM_BUILD_ROOT%{_bindir}/django-admin
@@ -100,23 +104,8 @@ ln -sf py3-django-admin $RPM_BUILD_ROOT%{_bindir}/django-admin
 %endif
 %endif
 
-find $RPM_BUILD_ROOT -type f -name '*.py[co]' | xargs rm
-find $RPM_BUILD_ROOT -type f -exec sed -i -e "s#$RPM_BUILD_ROOT##g" "{}" ";"
-
-%if %{with python2}
-%py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
-%py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
-
-find $RPM_BUILD_ROOT%{py_sitescriptdir} -type f -path '*_template*' -a -name '*.py[oc]' | xargs rm
-%endif
-
-%if %{with python3}
-%py3_ocomp $RPM_BUILD_ROOT%{py3_sitescriptdir}
-%py3_comp $RPM_BUILD_ROOT%{py3_sitescriptdir}
-%endif
-
+install -d $RPM_BUILD_ROOT%{_docdir}
 ln -sf python-django-doc-%{version} $RPM_BUILD_ROOT%{_docdir}/python-django-doc
-rm -rf docs/_build/html/_sources
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -145,5 +134,5 @@ rm -rf $RPM_BUILD_ROOT
 
 %files doc
 %defattr(644,root,root,755)
-%doc docs/_build/html
+%doc docs/_build/html/*
 %{_docdir}/python-django-doc
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-django.git/commitdiff/76025b570a6517a60ce40795901d68458ac94ea6



More information about the pld-cvs-commit mailing list