aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog7
-rw-r--r--debian/control6
-rw-r--r--debian/patches/02_do-not-use-embedded-python-six.patch40
-rw-r--r--debian/patches/series1
-rwxr-xr-xdebian/rules3
5 files changed, 54 insertions, 3 deletions
diff --git a/debian/changelog b/debian/changelog
index 2840434..ab26168 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -5,6 +5,11 @@ requests (0.10.8-1) UNRELEASED; urgency=low
[ Daniele Tricoli ]
* New upstream release (Closes: #663561)
+ * Removed embedded copy of python-six
+ - Added debian/patches/02_do-not-use-embedded-python-six.patch
+ - Added override_dh_auto_configure to debian/rules to remove
+ the embedded copy
+ - Added python(3)-six to Depends
* debian/control
- Bumped Standards-Version to 3.9.3 (no changes needed)
* debian/patches/01_do-not-use-python-certifi.patch
@@ -12,7 +17,7 @@ requests (0.10.8-1) UNRELEASED; urgency=low
* debian/patches/02_fix-python3-except-sintax-error.patch
- Removed as it is applied upstream
- -- Daniele Tricoli <eriol@mornie.org> Fri, 16 Mar 2012 19:37:44 +0100
+ -- Daniele Tricoli <eriol@mornie.org> Mon, 19 Mar 2012 00:35:09 +0100
requests (0.10.1-1) unstable; urgency=low
diff --git a/debian/control b/debian/control
index d688cc7..11513f2 100644
--- a/debian/control
+++ b/debian/control
@@ -19,7 +19,8 @@ Architecture: all
Depends:
${misc:Depends},
${python:Depends},
- ca-certificates
+ ca-certificates,
+ python-six
Recommends:
python-chardet,
python-gevent
@@ -49,7 +50,8 @@ Architecture: all
Depends:
${misc:Depends},
${python3:Depends},
- ca-certificates
+ ca-certificates,
+ python3-six
Description: elegant and simple HTTP library for Python3, built for human beings
Requests allow you to send GET, HEAD, PUT, POST, and DELETE
HTTP requests. You can add headers, form data, multipart files, and
diff --git a/debian/patches/02_do-not-use-embedded-python-six.patch b/debian/patches/02_do-not-use-embedded-python-six.patch
new file mode 100644
index 0000000..2cd415b
--- /dev/null
+++ b/debian/patches/02_do-not-use-embedded-python-six.patch
@@ -0,0 +1,40 @@
+Description: Do not use embedded copy of python-six.
+Author: Daniele Tricoli <eriol@mornie.org>
+Forwarded: not-needed
+Last-Update: 2012-03-19
+
+--- a/requests/packages/urllib3/connectionpool.py
++++ b/requests/packages/urllib3/connectionpool.py
+@@ -59,7 +59,7 @@
+ )
+
+ from .packages.ssl_match_hostname import match_hostname, CertificateError
+-from .packages import six
++import six
+
+ xrange = six.moves.xrange
+
+--- a/requests/packages/urllib3/filepost.py
++++ b/requests/packages/urllib3/filepost.py
+@@ -14,8 +14,8 @@
+
+ from io import BytesIO
+
+-from .packages import six
+-from .packages.six import b
++import six
++from six import b
+
+ writer = codecs.lookup('utf-8')[3]
+
+--- a/requests/packages/urllib3/response.py
++++ b/requests/packages/urllib3/response.py
+@@ -11,7 +11,7 @@
+ from io import BytesIO
+
+ from .exceptions import HTTPError
+-from .packages.six import string_types as basestring
++from six import string_types as basestring
+
+
+ log = logging.getLogger(__name__)
diff --git a/debian/patches/series b/debian/patches/series
index 94aff1f..45a01fe 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
01_do-not-use-python-certifi.patch
+02_do-not-use-embedded-python-six.patch
diff --git a/debian/rules b/debian/rules
index af9831c..b3b2304 100755
--- a/debian/rules
+++ b/debian/rules
@@ -16,6 +16,9 @@ override_dh_auto_clean:
rm -rf build
dh_auto_clean
+override_dh_auto_configure:
+ rm requests/packages/urllib3/packages/six.py
+
override_dh_auto_install:
set -ex; \
for python in $(PYVERS); do \