diff options
Diffstat (limited to 'meta/lib/oe/package_manager.py')
-rw-r--r-- | meta/lib/oe/package_manager.py | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py index 5ac729455e..20a41d53f8 100644 --- a/meta/lib/oe/package_manager.py +++ b/meta/lib/oe/package_manager.py | |||
@@ -370,7 +370,7 @@ class PackageManager(object, metaclass=ABCMeta): | |||
370 | self._handle_intercept_failure(registered_pkgs) | 370 | self._handle_intercept_failure(registered_pkgs) |
371 | 371 | ||
372 | 372 | ||
373 | def run_intercepts(self): | 373 | def run_intercepts(self, populate_sdk=None): |
374 | intercepts_dir = self.intercepts_dir | 374 | intercepts_dir = self.intercepts_dir |
375 | 375 | ||
376 | bb.note("Running intercept scripts:") | 376 | bb.note("Running intercept scripts:") |
@@ -392,9 +392,22 @@ class PackageManager(object, metaclass=ABCMeta): | |||
392 | output = subprocess.check_output(script_full, stderr=subprocess.STDOUT) | 392 | output = subprocess.check_output(script_full, stderr=subprocess.STDOUT) |
393 | if output: bb.note(output.decode("utf-8")) | 393 | if output: bb.note(output.decode("utf-8")) |
394 | except subprocess.CalledProcessError as e: | 394 | except subprocess.CalledProcessError as e: |
395 | bb.warn("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
396 | bb.note("Exit code %d. Output:\n%s" % (e.returncode, e.output.decode("utf-8"))) | 395 | bb.note("Exit code %d. Output:\n%s" % (e.returncode, e.output.decode("utf-8"))) |
397 | self._postpone_to_first_boot(script_full) | 396 | if populate_sdk == 'host': |
397 | bb.warn("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
398 | elif populate_sdk == 'target': | ||
399 | if "qemuwrapper: qemu usermode is not supported" in e.output.decode("utf-8"): | ||
400 | bb.warn("The postinstall intercept hook '%s' could not be executed due to missing qemu usermode support, details in %s/log.do_%s" | ||
401 | % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
402 | else: | ||
403 | bb.fatal("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
404 | else: | ||
405 | if "qemuwrapper: qemu usermode is not supported" in e.output.decode("utf-8"): | ||
406 | bb.note("The postinstall intercept hook '%s' could not be executed due to missing qemu usermode support, details in %s/log.do_%s" | ||
407 | % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
408 | self._postpone_to_first_boot(script_full) | ||
409 | else: | ||
410 | bb.fatal("The postinstall intercept hook '%s' failed, details in %s/log.do_%s" % (script, self.d.getVar('T'), self.d.getVar('BB_CURRENTTASK'))) | ||
398 | 411 | ||
399 | @abstractmethod | 412 | @abstractmethod |
400 | def update(self): | 413 | def update(self): |