[OE-core] [PATCH 2/2] classes/sanity: import regular expression module in SuSE distro check
Paul Eggleton
paul.eggleton at linux.intel.com
Wed Apr 18 09:56:10 UTC 2012
We call re.sub here, so we need to "import re" or an error occurs
(tested on OpenSuSE 12.1).
Signed-off-by: Paul Eggleton <paul.eggleton at linux.intel.com>
---
meta/classes/sanity.bbclass | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 3ec449c..9cd04c4 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -124,6 +124,7 @@ def check_supported_distro(e):
finally:
f.close()
elif os.path.exists("/etc/SuSE-release"):
+ import re
f = open("/etc/SuSE-release", "r")
try:
distro = f.readline()
--
1.7.5.4
More information about the Openembedded-core
mailing list