Skip to content

Commit

Permalink
builder: Add conditional flash map overrides in bsp.yml
Browse files Browse the repository at this point in the history
This allows to conditionally override flash maps in bsp.yml
and target.yml with bsp.flash_map.<CONDITION>
Initial priority of bsp.yml and target.yml is
preserved - if there is any bsp.flash_map definition
in target.yml, all flash maps from bsp.yml are ignored.
Default bsp.flash_map definition (without any condition)
is still needed.
  • Loading branch information
m-gorecki committed Nov 26, 2024
1 parent c6bf556 commit ed7892c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions newt/builder/targetbuild.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,14 @@ func NewTargetTester(target *target.Target,
injectedSettings: cfgv.NewSettings(nil),
}

if err := t.ensureResolved(); err != nil {
return nil, err
}

if err := t.bspPkg.Reload(t.res.Cfg.SettingValues()); err != nil {
return nil, err
}

return t, nil
}

Expand Down

0 comments on commit ed7892c

Please sign in to comment.