summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorelie <elie>2009-08-28 19:37:36 +0000
committerelie <elie>2009-08-28 19:37:36 +0000
commitbdde3e6d70557ebd55b30e5d0071092b9b2a1d3f (patch)
tree4ae1e3a0c68a2887c3201fadb80dc7104c061fec /setup.py
parentb863b55c3dcb482e252add1821256366fb7e6da6 (diff)
downloadpysnmp-bdde3e6d70557ebd55b30e5d0071092b9b2a1d3f.tar.gz
attempt to load setuptools
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py19
1 files changed, 18 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index 3a1cc3f..7c9fd40 100644
--- a/setup.py
+++ b/setup.py
@@ -1,5 +1,22 @@
#!/usr/bin/env python
-from distutils.core import setup
+import sys
+
+def howto_install_setuptools():
+ print """Error: You need setuptools Python package!
+
+It's very easy to install it, just type (as root on Linux):
+ wget http://peak.telecommunity.com/dist/ez_setup.py
+ python ez_setup.py
+"""
+
+try:
+ from setuptools import setup
+except ImportError:
+ for arg in sys.argv:
+ if "egg" in arg:
+ howto_install_setuptools()
+ sys.exit(1)
+ from distutils.core import setup
setup(name="pysnmp",
version="4.1.12a",