From: duplo Date: Fri, 19 Dec 2008 11:17:10 +0000 (+0000) Subject: Use the constants instead of hardcoded values X-Git-Tag: 2.1.0~580 X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=f7c35b4e4e3535fcfa22c28151cb692d13518fe5;p=bertos.git Use the constants instead of hardcoded values git-svn-id: https://src.develer.com/svnoss/bertos/trunk@2102 38d2e660-2303-0410-9eaa-f027e97ec537 --- diff --git a/wizard/bertos_utils.py b/wizard/bertos_utils.py index 0f0dc709..0a107691 100644 --- a/wizard/bertos_utils.py +++ b/wizard/bertos_utils.py @@ -12,6 +12,8 @@ import os import fnmatch +import const + def isBertosDir(directory): return os.path.exists(directory + "/VERSION") @@ -32,8 +34,9 @@ def findDefinitions(ftype, path): def loadCpuInfos(path): cpuInfos = [] - for definition in findDefinitions("cdef", path): + for definition in findDefinitions(const.CPU_DEFINITION, path): D = {} + D.update(const.CPU_DEF) def include(filename, dict = D, directory=definition[1]): execfile(directory + "/" + filename, {}, D) D["include"] = include