mirror of https://github.com/ARMmbed/mbed-os.git
Improve error messages for bootloader build errors
parent
7675901b7b
commit
ee5006f672
|
@ -497,7 +497,15 @@ class Config(object):
|
||||||
"""Generate a list of regions from the config"""
|
"""Generate a list of regions from the config"""
|
||||||
if not self.target.bootloader_supported:
|
if not self.target.bootloader_supported:
|
||||||
raise ConfigException("Bootloader not supported on this target.")
|
raise ConfigException("Bootloader not supported on this target.")
|
||||||
cmsis_part = Cache(False, False).index[self.target.device_name]
|
if not hasattr(self.target, "device_name"):
|
||||||
|
raise ConfigException("Bootloader not supported on this target: "
|
||||||
|
"targets.json `device_name` not specified.")
|
||||||
|
cache = Cache(False, False)
|
||||||
|
if self.target.device_name not in cache.index:
|
||||||
|
raise ConfigException("Bootloader not supported on this target: "
|
||||||
|
"targets.json `device_name` not found in "
|
||||||
|
"arm_pack_manager index.")
|
||||||
|
cmsis_part = cache.index[self.target.device_name]
|
||||||
target_overrides = self.app_config_data['target_overrides'].get(
|
target_overrides = self.app_config_data['target_overrides'].get(
|
||||||
self.target.name, {})
|
self.target.name, {})
|
||||||
if (('target.bootloader_img' in target_overrides or
|
if (('target.bootloader_img' in target_overrides or
|
||||||
|
|
Loading…
Reference in New Issue