diff options
author | Chris Larson <chris_larson@mentor.com> | 2010-04-15 08:45:15 -0700 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-07-02 15:41:34 +0100 |
commit | 214d1f7433fd8571c3e0920624ce07f31c7f08c9 (patch) | |
tree | 60bcbf02751331e45b6d8782a4318a184262f70e /bitbake/lib/bb | |
parent | 231d3a534cdf75b3db588329fbd5d2a0fbbfba5e (diff) | |
download | poky-214d1f7433fd8571c3e0920624ce07f31c7f08c9.tar.gz |
Move the python version check into the python package
This ensures the check is run for anyone using the package, including
setup.py, though it's sad that it's necessary, since all it really wants is
__version__.
Ideally, we'd avoid the version check entirely in favor of checking for
functionality, but that's rather difficult with language constructs like
context managers, so this'll do for now.
(Bitbake rev: f936f1c0edf70860ea0f39ec1a500ba43b56f289)
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/__init__.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bitbake/lib/bb/__init__.py b/bitbake/lib/bb/__init__.py index bf2f35a730..e4a970c640 100644 --- a/bitbake/lib/bb/__init__.py +++ b/bitbake/lib/bb/__init__.py | |||
@@ -23,6 +23,10 @@ | |||
23 | 23 | ||
24 | __version__ = "1.11.0" | 24 | __version__ = "1.11.0" |
25 | 25 | ||
26 | import sys | ||
27 | if sys.version_info < (2, 6, 0): | ||
28 | raise RuntimeError("Sorry, python 2.6.0 or later is required for this version of bitbake") | ||
29 | |||
26 | import os | 30 | import os |
27 | import bb.msg | 31 | import bb.msg |
28 | 32 | ||