Skip to content

Commit

Permalink
waf: Fail if custom hwdef file doesn't exist
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Friedman <[email protected]>
  • Loading branch information
Ryanf55 authored and peterbarker committed Oct 27, 2024
1 parent b4df082 commit 0725109
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions wscript
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,9 @@ def configure(cfg):
cfg.env.ENABLE_STATS = cfg.options.enable_stats
cfg.env.SAVE_TEMPS = cfg.options.save_temps

extra_hwdef = cfg.options.extra_hwdef
if extra_hwdef is not None and not os.path.exists(extra_hwdef):
raise FileNotFoundError(f"extra-hwdef file NOT found: '{cfg.options.extra_hwdef}'")
cfg.env.HWDEF_EXTRA = cfg.options.extra_hwdef
if cfg.env.HWDEF_EXTRA:
cfg.env.HWDEF_EXTRA = os.path.abspath(cfg.env.HWDEF_EXTRA)
Expand Down

0 comments on commit 0725109

Please sign in to comment.