Upgrade to 0.8 final.
Remove the two remaining Apache licensed files until their license is fixed. Patch regressions that we had already submitted upstream -- resubmit
This commit is contained in:
parent
985c740cb3
commit
5d8b05315f
12
docutils-encoding.patch
Normal file
12
docutils-encoding.patch
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
Index: docutils-0.8/test/test_functional.py
|
||||||
|
===================================================================
|
||||||
|
--- docutils-0.8.orig/test/test_functional.py
|
||||||
|
+++ docutils-0.8/test/test_functional.py
|
||||||
|
@@ -175,7 +175,6 @@ expected output and check it in:
|
||||||
|
f = open(expected_path, 'r')
|
||||||
|
else: # samples are UTF8 encoded. 'rb' leads to errors with Python 3!
|
||||||
|
f = open(expected_path, 'r', encoding='utf-8')
|
||||||
|
- f = open(expected_path, 'r')
|
||||||
|
# Normalize line endings:
|
||||||
|
expected = '\n'.join(f.read().splitlines())
|
||||||
|
f.close()
|
22
docutils-test-exceptions.patch
Normal file
22
docutils-test-exceptions.patch
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
Index: docutils-0.8/test/test_error_reporting.py
|
||||||
|
===================================================================
|
||||||
|
--- docutils-0.8.orig/test/test_error_reporting.py
|
||||||
|
+++ docutils-0.8/test/test_error_reporting.py
|
||||||
|
@@ -236,7 +236,7 @@ class SafeStringTests_locale(unittest.Te
|
||||||
|
except UnicodeEncodeError:
|
||||||
|
try:
|
||||||
|
open(u'\xfc'.encode(sys.getfilesystemencoding(), 'replace'))
|
||||||
|
- except IOError:
|
||||||
|
+ except IOError, e:
|
||||||
|
uioe = e
|
||||||
|
try:
|
||||||
|
os.chdir(b('\xfc'))
|
||||||
|
@@ -249,7 +249,7 @@ class SafeStringTests_locale(unittest.Te
|
||||||
|
except UnicodeEncodeError:
|
||||||
|
try:
|
||||||
|
os.chdir(u'\xfc'.encode(sys.getfilesystemencoding(), 'replace'))
|
||||||
|
- except OSError:
|
||||||
|
+ except OSError, e:
|
||||||
|
uose = e
|
||||||
|
# wrapped test data:
|
||||||
|
wbioe = SafeString(bioe)
|
@ -1,29 +0,0 @@
|
|||||||
Index: docutils/test/test_functional.py
|
|
||||||
===================================================================
|
|
||||||
--- docutils/test/test_functional.py (revision 7036)
|
|
||||||
+++ docutils/test/test_functional.py (working copy)
|
|
||||||
@@ -171,7 +171,10 @@
|
|
||||||
no_expected = self.no_expected_template % {
|
|
||||||
'exp': expected_path, 'out': params['destination_path']}
|
|
||||||
self.assert_(os.access(expected_path, os.R_OK), no_expected)
|
|
||||||
- f = open(expected_path, 'r') # ! 'rb' leads to errors with Python 3!
|
|
||||||
+ if sys.version_info < (3,0):
|
|
||||||
+ f = open(expected_path, 'r')
|
|
||||||
+ else:
|
|
||||||
+ f = open(expected_path, 'r', encoding='utf-8') # ! 'rb' leads to errors with Python 3!
|
|
||||||
# Normalize line endings:
|
|
||||||
expected = '\n'.join(f.read().splitlines())
|
|
||||||
f.close()
|
|
||||||
Index: docutils/test/test_io.py
|
|
||||||
===================================================================
|
|
||||||
--- docutils/test/test_io.py (revision 7036)
|
|
||||||
+++ docutils/test/test_io.py (working copy)
|
|
||||||
@@ -99,7 +99,7 @@
|
|
||||||
except UnicodeEncodeError:
|
|
||||||
try:
|
|
||||||
open(u'\xfc'.encode(sys.getfilesystemencoding(), 'replace'))
|
|
||||||
- except IOError:
|
|
||||||
+ except IOError, e:
|
|
||||||
uioe = e
|
|
||||||
if locale:
|
|
||||||
locale.setlocale(locale.LC_ALL, 'C') # reset
|
|
@ -11,21 +11,24 @@
|
|||||||
|
|
||||||
Name: python-%{srcname}
|
Name: python-%{srcname}
|
||||||
Version: 0.8
|
Version: 0.8
|
||||||
Release: 0.1.20110517svn7036%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: System for processing plaintext documentation
|
Summary: System for processing plaintext documentation
|
||||||
|
|
||||||
Group: Development/Languages
|
Group: Development/Languages
|
||||||
# See COPYING.txt for information
|
# See COPYING.txt for information
|
||||||
License: Public Domain and MIT and Python and GPLv2
|
License: Public Domain and BSD and Python and GPLv3+
|
||||||
URL: http://docutils.sourceforge.net
|
URL: http://docutils.sourceforge.net
|
||||||
#Source0: http://downloads.sourceforge.net/docutils/%{srcname}-%{version}.tar.gz
|
Source0: http://downloads.sourceforge.net/docutils/%{srcname}-%{version}.tar.gz
|
||||||
# Build a snapshot
|
# Sometimes we need snapshots. Instructions below:
|
||||||
# svn co svn://svn.berlios.de/docutils/trunk/docutils
|
# svn co -r $REV svn://svn.berlios.de/docutils/trunk/docutils
|
||||||
# cd docutils
|
# cd docutils
|
||||||
# python setup.py sdist
|
# python setup.py sdist
|
||||||
# The tarball is in dist/docutils-VERSION.tar.gz
|
# The tarball is in dist/docutils-VERSION.tar.gz
|
||||||
Source0: %{srcname}-%{version}.tar.gz
|
#Source0: %{srcname}-%{version}.tar.gz
|
||||||
Patch0: docutils-test-io-exception.patch
|
# Patches submitted upstream here:
|
||||||
|
# https://sourceforge.net/tracker/index.php?func=detail&aid=3365041&group_id=38414&atid=422032
|
||||||
|
Patch0: docutils-test-exceptions.patch
|
||||||
|
Patch1: docutils-encoding.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
@ -74,23 +77,21 @@ This package contains the module, ported to run under python3.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{srcname}-%{version}
|
%setup -q -n %{srcname}-%{version}
|
||||||
%patch0 -p1 -b .testio
|
%patch0 -p1 -b .testexc
|
||||||
|
%patch1 -p1 -b .testencoding
|
||||||
|
|
||||||
# We want to check if this is necessary every time we rebuild
|
# Remove Apache licensed files for now. Can stop doing this when this bug is resolved
|
||||||
# since it is icky, nasty, and gross.
|
# https://sourceforge.net/tracker/?func=detail&aid=3364658&group_id=38414&atid=422030
|
||||||
# The python3 bug that needs to be solved for this to work is:
|
rm -f docs/user/docutils-05-compat.sty.txt docutils/writers/latex2e/docutils-05-compat.sty
|
||||||
# https://bugzilla.redhat.com/show_bug.cgi?id=705436
|
|
||||||
%if 0%{?with_python3}
|
|
||||||
if test x"%{release}" = x"0.1.20110517svn7036%{?dist}" ; then
|
|
||||||
sed -i 's/Günter/Gunter/' tools/rst2xetex.py
|
|
||||||
fi
|
|
||||||
%endif
|
|
||||||
|
|
||||||
# Remove shebang from library files
|
# Remove shebang from library files
|
||||||
for file in docutils/_string_template_compat.py ; do
|
for file in docutils/_string_template_compat.py docutils/math/{__init__.py,latex2mathml.py}; do
|
||||||
sed -i -e '/#! *\/usr\/bin\/.*/{1D}' $file
|
sed -i -e '/#! *\/usr\/bin\/.*/{1D}' $file
|
||||||
done
|
done
|
||||||
|
|
||||||
|
iconv -f ISO88592 -t UTF8 tools/editors/emacs/IDEAS.rst > tmp
|
||||||
|
mv tmp tools/editors/emacs/IDEAS.rst
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
rm -rf %{py3dir}
|
rm -rf %{py3dir}
|
||||||
cp -a . %{py3dir}
|
cp -a . %{py3dir}
|
||||||
@ -183,10 +184,16 @@ rm -rf %{buildroot}
|
|||||||
%{python3_sitelib}/*
|
%{python3_sitelib}/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jul 12 2011 Toshio Kuratomi <toshio@fedoraproject.org> - 0.8-1
|
||||||
|
- Upgrade to 0.8 final.
|
||||||
|
- Remove the two remaining Apache licensed files until their license is fixed.
|
||||||
|
- Patch regressions that we had already submitted upstream -- resubmit
|
||||||
|
|
||||||
* Tue May 17 2011 Toshio Kuratomi <toshio@fedoraproject.org> - 0.8-0.1.20110517svn7036
|
* Tue May 17 2011 Toshio Kuratomi <toshio@fedoraproject.org> - 0.8-0.1.20110517svn7036
|
||||||
- Ship a snapshot of 0.8 so that we can build on python-3.2.1
|
- Ship a snapshot of 0.8 so that we can build on python-3.2.1
|
||||||
- Unfortunately, 3.2.1 isn't out yet either. So also apply a fix for building
|
- Unfortunately, 3.2.1 isn't out yet either. So also apply a fix for building
|
||||||
with 3.2.0 that we'll need to remove later.
|
with 3.2.0 that we'll need to remove later.
|
||||||
|
- The new docutils.math module is licensed Apache. Update the license to reflect this
|
||||||
|
|
||||||
* Wed Mar 16 2011 Toshio Kuratomi <toshio@fedoraproject.org> - 0.7-5
|
* Wed Mar 16 2011 Toshio Kuratomi <toshio@fedoraproject.org> - 0.7-5
|
||||||
- Fix building with python-3.2 via a workaround. Sent upstream awaiting
|
- Fix building with python-3.2 via a workaround. Sent upstream awaiting
|
||||||
|
Loading…
Reference in New Issue
Block a user