| |
@@ -6,7 +6,7 @@
|
| |
|
| |
Name: python-%{srcname}
|
| |
Version: 0.14
|
| |
- Release: 4%{?dist}
|
| |
+ Release: 5%{?dist}
|
| |
Summary: System for processing plaintext documentation
|
| |
|
| |
Group: Development/Languages
|
| |
@@ -105,41 +105,37 @@
|
| |
|
| |
|
| |
%install
|
| |
- # Must do the python3 install first because the scripts in /usr/bin are
|
| |
- # overwritten by setup.py install (and we want the python2 version to be the
|
| |
- # default for now).
|
| |
- %if 0%{?with_python3}
|
| |
- pushd %{py3dir}
|
| |
- %py3_install
|
| |
+ %py2_install
|
| |
|
| |
# docutils setup.py runs 2to3 on a copy of the tests and puts it in sitelib.
|
| |
rm -rf %{buildroot}%{python3_sitelib}/test
|
| |
|
| |
- for file in %{buildroot}/%{_bindir}/*.py; do
|
| |
- mv $file `dirname $file`/`basename $file .py`-3
|
| |
- done
|
| |
-
|
| |
# Flash file is used for testing docutils but shouldn't be in the installed package.
|
| |
mv docs/user/rst/images/biohazard.swf ./biohazard.swf
|
| |
- popd
|
| |
|
| |
+ %if 0%{?with_python3}
|
| |
+ rm -f %{buildroot}/%{_bindir}/*
|
| |
%endif # with_python3
|
| |
|
| |
- %py2_install
|
| |
-
|
| |
- for file in %{buildroot}/%{_bindir}/*.py; do
|
| |
- mv $file `dirname $file`/`basename $file .py`
|
| |
- done
|
| |
-
|
| |
+ %if 0%{?with_python3}
|
| |
+ pushd %{py3dir}
|
| |
+ %py3_install
|
| |
# We want the licenses but don't need this build file
|
| |
rm -f licenses/docutils.conf
|
| |
|
| |
# Flash file is used for testing docutils but shouldn't be in the installed package.
|
| |
mv docs/user/rst/images/biohazard.swf ./biohazard.swf
|
| |
+ popd
|
| |
+ %endif # with_python3
|
| |
+
|
| |
+ for file in %{buildroot}/%{_bindir}/*.py; do
|
| |
+ mv $file `dirname $file`/`basename $file .py`
|
| |
+ done
|
| |
+
|
| |
|
| |
%check
|
| |
mv biohazard.swf docs/user/rst/images/biohazard.swf
|
| |
- python test/alltests.py
|
| |
+ python2 test/alltests.py
|
| |
rm docs/user/rst/images/biohazard.swf
|
| |
|
| |
%if 0%{?with_python3}
|
| |
@@ -154,7 +150,6 @@
|
| |
%license COPYING.txt licenses/*
|
| |
%doc BUGS.txt COPYING.txt FAQ.txt HISTORY.txt README.txt RELEASE-NOTES.txt
|
| |
%doc THANKS.txt docs tools/editors
|
| |
- %{_bindir}/*[!'-3']
|
| |
%{python2_sitelib}/*
|
| |
|
| |
%if 0%{?with_python3}
|
| |
@@ -162,11 +157,17 @@
|
| |
%license COPYING.txt licenses/*
|
| |
%doc BUGS.txt FAQ.txt HISTORY.txt README.txt RELEASE-NOTES.txt
|
| |
%doc THANKS.txt docs tools/editors
|
| |
- %{_bindir}/*-3
|
| |
%{python3_sitelib}/*
|
| |
%endif
|
| |
|
| |
+ # Leave this at the end to end up in the proper one
|
| |
+ %{_bindir}/*
|
| |
+
|
| |
%changelog
|
| |
+ * Thu Jul 12 2018 Miro Hrončok <mhroncok@redhat.com> - 0.14-5
|
| |
+ - Only ship one version of the rst2* executables
|
| |
+ - Invoke python2 with python2 in %%check
|
| |
+
|
| |
* Thu Jun 14 2018 Miro Hrončok <mhroncok@redhat.com> - 0.14-4
|
| |
- Rebuilt for Python 3.7
|
| |
|
| |
Also, invoke python2 with python2 in %check