summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Kletzander <mkletzan@redhat.com>2014-10-07 10:35:10 +0200
committerMartin Kletzander <mkletzan@redhat.com>2014-10-07 10:35:10 +0200
commit5346d9d9a30b8ce53a0dccfa40492cb03ed53119 (patch)
tree20f4611296d794c93813fdb7db1ba1d765ac720f
parentc58c7f362aab37e4961407c2efc8a74925ed9c37 (diff)
downloadlibvirt-python-5346d9d9a30b8ce53a0dccfa40492cb03ed53119.tar.gz
sanitytest: define long for python version >= 3
Commit c58c7f362aab37e4961407c2efc8a74925ed9c37 fixed 32-bit python build but broke build with python3 due to the lack of 'long' in the newer version of python. This patch aims to fix it with a simple string comparison of sys.version and '3'. Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
-rw-r--r--sanitytest.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/sanitytest.py b/sanitytest.py
index 5bd85a5..b161696 100644
--- a/sanitytest.py
+++ b/sanitytest.py
@@ -9,6 +9,9 @@ import string
sys.path.insert(0, sys.argv[1])
import libvirt
+if sys.version > '3':
+ long = int
+
# Path to the libvirt API XML file
xml = sys.argv[2]