summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Suster <carl@contraflo.ws>2017-01-11 22:26:29 +1100
committerCarl Suster <carl@contraflo.ws>2017-01-11 22:26:29 +1100
commitc1eca6d92492993689ac37384dc796f04e68a341 (patch)
treec67ebb104b592fda6d0cded669542971ee5e3068
parentf534872dc46f65357e970e2c328cdce1b24f4dc8 (diff)
Call 2to3 within setup.py instead of the hackier d/rules
-rw-r--r--debian/changelog2
-rwxr-xr-xdebian/rules2
2 files changed, 2 insertions, 2 deletions
diff --git a/debian/changelog b/debian/changelog
index b54d9a2..57a8d8c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -15,9 +15,9 @@ python-pynzb (0.1.0-3) unstable; urgency=medium
* Run the test suite with pytest:
- cleanup the produced .cache/ in d/clean,
- add B-D on python3-pytest.
- * Call 2to3-3.Y during auto build for Python 3.X.
* 0001-set-message_id-properly-in-expat-parser.patch: fix an upstream code
typo. This change allows the tests to pass for Python 2.
+ * 0002-enable-use_2to3-in-setup.py.patch: enable 2to3 invocation in setup.py.
* Move lxml to Suggests rather than Depends since there are fallbacks using
standard library XML parsers.
* Build-Depend on lxml in order to run the test for the implementation of the
diff --git a/debian/rules b/debian/rules
index 1300e4a..68142db 100755
--- a/debian/rules
+++ b/debian/rules
@@ -8,7 +8,7 @@ export PYBUILD_TEST_ARGS=pynzb/tests.py
# utf-8 for the Python 3 build. If this turns out to be problematic, we can
# instead disable lxml support for the Python 3 build in pynzb/__init__.py and
# rely on the standard library fallbacks for XML parsing.
-export PYBUILD_AFTER_BUILD_python3=2to3-{version} -n -w {build_dir}/pynzb/; sed -i -e 's/StringIO/BytesIO/g' -e 's/BytesIO(xml)/BytesIO(bytes(xml,"utf-8"))/' {build_dir}/pynzb/lxml_nzb.py
+export PYBUILD_AFTER_BUILD_python3=sed -i -e 's/StringIO/BytesIO/g' -e 's/BytesIO(xml)/BytesIO(bytes(xml,"utf-8"))/' {build_dir}/pynzb/lxml_nzb.py
%: