summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormattsb42-aws <bullocm@amazon.com>2018-02-09 11:18:01 -0800
committermattsb42-aws <bullocm@amazon.com>2018-02-09 11:18:01 -0800
commitb0b141cf75a39613ebc58e0c6c018fc01287fb08 (patch)
tree9596192170c6171b44e31d0d02e6061df4a4c7d7
parentf31ff816e74f9ab1b9d518215b2a77ab6ed64141 (diff)
downloadpysnmp-git-b0b141cf75a39613ebc58e0c6c018fc01287fb08.tar.gz
fixing Python 2.6 dependency issue
-rw-r--r--requirements.txt1
-rw-r--r--setup.py9
-rw-r--r--tox.ini2
3 files changed, 9 insertions, 3 deletions
diff --git a/requirements.txt b/requirements.txt
index dfbec048..76ab7775 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -5,3 +5,4 @@ pycryptodomex; python_version == '3.2'
pycryptodomex; python_version == '3.3'
cryptography; python_version >= '3.4'
pyasn1>=0.2.3
+ordereddict; python_version < '2.7'
diff --git a/setup.py b/setup.py
index c9981b85..f5a81a78 100644
--- a/setup.py
+++ b/setup.py
@@ -60,11 +60,16 @@ if py_version < (2, 7) or (py_version >= (3, 0) and py_version < (3, 4)):
else:
crypto_lib = 'cryptography'
+requires = ['pyasn1>=0.2.3', 'pysmi', crypto_lib]
+
+if py_version < (2, 7):
+ requires.append('ordereddict')
+
try:
from setuptools import setup
params = {
- 'install_requires': ['pyasn1>=0.2.3', 'pysmi', crypto_lib],
+ 'install_requires': requires,
'zip_safe': True
}
@@ -78,7 +83,7 @@ except ImportError:
params = {}
if py_version > (2, 4):
- params['requires'] = ['pyasn1(>=0.2.3)', 'pysmi', crypto_lib]
+ params['requires'] = requires
doclines = [x.strip() for x in (__doc__ or '').split('\n') if x]
diff --git a/tox.ini b/tox.ini
index 5aa494dd..728030cc 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,5 +1,5 @@
[envlist]
-envlist = py{27,34,35,36}
+envlist = py{26,27,34,35,36}
[testenv]
commands = {toxinidir}/runtests.sh