summaryrefslogtreecommitdiffstats
path: root/lib/bb/ui/hob.py
diff options
context:
space:
mode:
authorJoshua Lock <josh@linux.intel.com>2012-04-05 10:56:43 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-04-11 00:02:20 +0100
commit5ccbcdf8c47f2f20655a3ea0f60e5870cdba6f83 (patch)
treebd116e990ca839b9996d982823a520ce4040b2d1 /lib/bb/ui/hob.py
parent82ea0619e9ecf9107b75692385bcf1434ea8a307 (diff)
downloadbitbake-5ccbcdf8c47f2f20655a3ea0f60e5870cdba6f83.tar.gz
hob: update required versions of (py)gtk et al
With the previous two changes we now work on Gtk+ 2.18 and PyGtk 2.16 Signed-off-by: Joshua Lock <josh@linux.intel.com>
Diffstat (limited to 'lib/bb/ui/hob.py')
-rwxr-xr-xlib/bb/ui/hob.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/bb/ui/hob.py b/lib/bb/ui/hob.py
index 1321ebbac..6cd957963 100755
--- a/lib/bb/ui/hob.py
+++ b/lib/bb/ui/hob.py
@@ -22,15 +22,18 @@
import sys
import os
-requirements = "FATAL: pygtk (version 2.22.0 or later) and pygobject are required to use Hob"
+requirements = "FATAL: Gtk+, PyGtk and PyGobject are required to use Hob"
try:
import gobject
import gtk
import pygtk
pygtk.require('2.0') # to be certain we don't have gtk+ 1.x !?!
- ver = gtk.pygtk_version
- if ver < (2, 22, 0):
- sys.exit("%s (you have pygtk %s.%s.%s)." % (requirements, ver[0], ver[1], ver[2]))
+ gtkver = gtk.gtk_version
+ pygtkver = gtk.pygtk_version
+ if gtkver < (2, 18, 0) or pygtkver < (2, 16, 0):
+ sys.exit("%s,\nYou have Gtk+ %s and PyGtk %s." % (requirements,
+ ".".join(map(str, gtkver)),
+ ".".join(map(str, pygtkver))))
except ImportError as exc:
sys.exit("%s (%s)." % (requirements, str(exc)))
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.dirname(__file__))))