Blame allow-older-setuptools.patch

12fd205
Upstream uses environment markers to conditionally apply some dependencies.
12fd205
Environment markers were first added in setuptools 20.6.8.
12fd205
3f50907
diff -Nurp docker-compose-1.18.0.orig/setup.py docker-compose-1.18.0/setup.py
3f50907
--- docker-compose-1.18.0.orig/setup.py	2017-12-06 19:34:46.000000000 -0600
3f50907
+++ docker-compose-1.18.0/setup.py	2017-12-26 18:09:04.896020834 -0600
12fd205
@@ -42,6 +42,17 @@ install_requires = [
3f50907
     'jsonschema >= 2.5.1, < 3',
12fd205
 ]
12fd205
 
12fd205
+if sys.version_info[:2] < (3, 4):
12fd205
+    install_requires.append('enum34 >= 1.0.4')
12fd205
+
12fd205
+if sys.version_info[:2] < (3, 5):
12fd205
+    install_requires.append('backports.ssl_match_hostname >= 3.5')
12fd205
+
12fd205
+if sys.version_info[:2] < (3, 3):
12fd205
+    install_requires.append('ipaddress >= 1.0.16')
12fd205
+
12fd205
+if sys.platform == 'win32':
3f50907
+    install_requires.append('colorama >= 0.3.9')
12fd205
 
12fd205
 tests_require = [
12fd205
     'pytest',
12fd205
@@ -52,27 +63,10 @@ if sys.version_info[:2] < (3, 4):
12fd205
     tests_require.append('mock >= 1.0.1')
12fd205
 
12fd205
 extras_require = {
12fd205
-    ':python_version < "3.4"': ['enum34 >= 1.0.4, < 2'],
12fd205
-    ':python_version < "3.5"': ['backports.ssl_match_hostname >= 3.5'],
12fd205
-    ':python_version < "3.3"': ['ipaddress >= 1.0.16'],
3f50907
-    ':sys_platform == "win32"': ['colorama >= 0.3.9, < 0.4'],
12fd205
     'socks': ['PySocks >= 1.5.6, != 1.5.7, < 2'],
12fd205
 }
12fd205
 
12fd205
 
12fd205
-try:
12fd205
-    if 'bdist_wheel' not in sys.argv:
12fd205
-        for key, value in extras_require.items():
12fd205
-            if key.startswith(':') and pkg_resources.evaluate_marker(key[1:]):
12fd205
-                install_requires.extend(value)
12fd205
-except Exception as e:
12fd205
-    print("Failed to compute platform dependencies: {}. ".format(e) +
12fd205
-          "All dependencies will be installed as a result.", file=sys.stderr)
12fd205
-    for key, value in extras_require.items():
12fd205
-        if key.startswith(':'):
12fd205
-            install_requires.extend(value)
12fd205
-
12fd205
-
12fd205
 setup(
12fd205
     name='docker-compose',
12fd205
     version=find_version("compose", "__init__.py"),