From d33ef936c3c4673112d0fa91a3d9e507b97be663 Mon Sep 17 00:00:00 2001 From: Michael Lauer Date: Sun, 21 May 2006 16:17:03 +0000 Subject: sanity.bbclass: make it work even when distutils is not available --- classes/sanity.bbclass | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'classes/sanity.bbclass') diff --git a/classes/sanity.bbclass b/classes/sanity.bbclass index 8253b27930..a06753b198 100644 --- a/classes/sanity.bbclass +++ b/classes/sanity.bbclass @@ -31,7 +31,10 @@ def check_app_exists(app, d): def check_sanity(e): from bb import note, error, data, __version__ from bb.event import Handled, NotHandled, getName - from distutils.version import LooseVersion + try: + from distutils.version import LooseVersion + except ImportError: + def LooseVersion(v): print "WARNING: sanity.bbclass can't compare versions without python-distutils"; return 1 import os # Check the bitbake version meets minimum requirements -- cgit v1.2.3