diff options
Diffstat (limited to 'meta/classes/icecc.bbclass')
-rw-r--r-- | meta/classes/icecc.bbclass | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/meta/classes/icecc.bbclass b/meta/classes/icecc.bbclass index 529b097aac..61b8bb1a11 100644 --- a/meta/classes/icecc.bbclass +++ b/meta/classes/icecc.bbclass | |||
@@ -36,14 +36,14 @@ def icecc_dep_prepend(d): | |||
36 | # INHIBIT_DEFAULT_DEPS doesn't apply to the patch command. Whether or not | 36 | # INHIBIT_DEFAULT_DEPS doesn't apply to the patch command. Whether or not |
37 | # we need that built is the responsibility of the patch function / class, not | 37 | # we need that built is the responsibility of the patch function / class, not |
38 | # the application. | 38 | # the application. |
39 | if not d.getVar('INHIBIT_DEFAULT_DEPS'): | 39 | if not d.getVar('INHIBIT_DEFAULT_DEPS', False): |
40 | return "icecc-create-env-native" | 40 | return "icecc-create-env-native" |
41 | return "" | 41 | return "" |
42 | 42 | ||
43 | DEPENDS_prepend += "${@icecc_dep_prepend(d)} " | 43 | DEPENDS_prepend += "${@icecc_dep_prepend(d)} " |
44 | 44 | ||
45 | def get_cross_kernel_cc(bb,d): | 45 | def get_cross_kernel_cc(bb,d): |
46 | kernel_cc = d.getVar('KERNEL_CC') | 46 | kernel_cc = d.getVar('KERNEL_CC', False) |
47 | 47 | ||
48 | # evaluate the expression by the shell if necessary | 48 | # evaluate the expression by the shell if necessary |
49 | if '`' in kernel_cc or '$(' in kernel_cc: | 49 | if '`' in kernel_cc or '$(' in kernel_cc: |
@@ -56,7 +56,7 @@ def get_cross_kernel_cc(bb,d): | |||
56 | return kernel_cc | 56 | return kernel_cc |
57 | 57 | ||
58 | def get_icecc(d): | 58 | def get_icecc(d): |
59 | return d.getVar('ICECC_PATH') or bb.utils.which(os.getenv("PATH"), "icecc") | 59 | return d.getVar('ICECC_PATH', False) or bb.utils.which(os.getenv("PATH"), "icecc") |
60 | 60 | ||
61 | def create_path(compilers, bb, d): | 61 | def create_path(compilers, bb, d): |
62 | """ | 62 | """ |
@@ -91,7 +91,7 @@ def create_path(compilers, bb, d): | |||
91 | return staging | 91 | return staging |
92 | 92 | ||
93 | def use_icc(bb,d): | 93 | def use_icc(bb,d): |
94 | if d.getVar('ICECC_DISABLED') == "1": | 94 | if d.getVar('ICECC_DISABLED', False) == "1": |
95 | # don't even try it, when explicitly disabled | 95 | # don't even try it, when explicitly disabled |
96 | return "no" | 96 | return "no" |
97 | 97 | ||
@@ -102,7 +102,7 @@ def use_icc(bb,d): | |||
102 | pn = d.getVar('PN', True) | 102 | pn = d.getVar('PN', True) |
103 | 103 | ||
104 | system_class_blacklist = [] | 104 | system_class_blacklist = [] |
105 | user_class_blacklist = (d.getVar('ICECC_USER_CLASS_BL') or "none").split() | 105 | user_class_blacklist = (d.getVar('ICECC_USER_CLASS_BL', False) or "none").split() |
106 | package_class_blacklist = system_class_blacklist + user_class_blacklist | 106 | package_class_blacklist = system_class_blacklist + user_class_blacklist |
107 | 107 | ||
108 | for black in package_class_blacklist: | 108 | for black in package_class_blacklist: |
@@ -119,8 +119,8 @@ def use_icc(bb,d): | |||
119 | # e.g. when there is new version | 119 | # e.g. when there is new version |
120 | # building libgcc-initial with icecc fails with CPP sanity check error if host sysroot contains cross gcc built for another target tune/variant | 120 | # building libgcc-initial with icecc fails with CPP sanity check error if host sysroot contains cross gcc built for another target tune/variant |
121 | system_package_blacklist = ["libgcc-initial"] | 121 | system_package_blacklist = ["libgcc-initial"] |
122 | user_package_blacklist = (d.getVar('ICECC_USER_PACKAGE_BL') or "").split() | 122 | user_package_blacklist = (d.getVar('ICECC_USER_PACKAGE_BL', False) or "").split() |
123 | user_package_whitelist = (d.getVar('ICECC_USER_PACKAGE_WL') or "").split() | 123 | user_package_whitelist = (d.getVar('ICECC_USER_PACKAGE_WL', False) or "").split() |
124 | package_blacklist = system_package_blacklist + user_package_blacklist | 124 | package_blacklist = system_package_blacklist + user_package_blacklist |
125 | 125 | ||
126 | if pn in package_blacklist: | 126 | if pn in package_blacklist: |
@@ -131,14 +131,14 @@ def use_icc(bb,d): | |||
131 | bb.debug(1, "%s: found in whitelist, enable icecc" % pn) | 131 | bb.debug(1, "%s: found in whitelist, enable icecc" % pn) |
132 | return "yes" | 132 | return "yes" |
133 | 133 | ||
134 | if d.getVar('PARALLEL_MAKE') == "": | 134 | if d.getVar('PARALLEL_MAKE', False) == "": |
135 | bb.debug(1, "%s: has empty PARALLEL_MAKE, disable icecc" % pn) | 135 | bb.debug(1, "%s: has empty PARALLEL_MAKE, disable icecc" % pn) |
136 | return "no" | 136 | return "no" |
137 | 137 | ||
138 | return "yes" | 138 | return "yes" |
139 | 139 | ||
140 | def icc_is_allarch(bb, d): | 140 | def icc_is_allarch(bb, d): |
141 | return d.getVar("PACKAGE_ARCH") == "all" | 141 | return d.getVar("PACKAGE_ARCH", False) == "all" |
142 | 142 | ||
143 | def icc_is_kernel(bb, d): | 143 | def icc_is_kernel(bb, d): |
144 | return \ | 144 | return \ |
@@ -155,8 +155,8 @@ def icc_version(bb, d): | |||
155 | if use_icc(bb, d) == "no": | 155 | if use_icc(bb, d) == "no": |
156 | return "" | 156 | return "" |
157 | 157 | ||
158 | parallel = d.getVar('ICECC_PARALLEL_MAKE') or "" | 158 | parallel = d.getVar('ICECC_PARALLEL_MAKE', False) or "" |
159 | if not d.getVar('PARALLEL_MAKE') == "" and parallel: | 159 | if not d.getVar('PARALLEL_MAKE', False) == "" and parallel: |
160 | d.setVar("PARALLEL_MAKE", parallel) | 160 | d.setVar("PARALLEL_MAKE", parallel) |
161 | 161 | ||
162 | if icc_is_native(bb, d): | 162 | if icc_is_native(bb, d): |
@@ -167,7 +167,7 @@ def icc_version(bb, d): | |||
167 | prefix = d.expand('${HOST_PREFIX}' ) | 167 | prefix = d.expand('${HOST_PREFIX}' ) |
168 | distro = d.expand('${DISTRO}') | 168 | distro = d.expand('${DISTRO}') |
169 | target_sys = d.expand('${TARGET_SYS}') | 169 | target_sys = d.expand('${TARGET_SYS}') |
170 | float = d.getVar('TARGET_FPU') or "hard" | 170 | float = d.getVar('TARGET_FPU', False) or "hard" |
171 | archive_name = prefix + distro + "-" + target_sys + "-" + float | 171 | archive_name = prefix + distro + "-" + target_sys + "-" + float |
172 | if icc_is_kernel(bb, d): | 172 | if icc_is_kernel(bb, d): |
173 | archive_name += "-kernel" | 173 | archive_name += "-kernel" |