Fixup on values interpolation and metadata retrieve

- Fixup search path on metadata spec load. Previously we were reading
  the package being passed, and not the one resolved (it failed against
selectors)
- Do inherit first pushrepositories, so they take precedence over pull
- Add test cases to cover build values interpolation by remote
  repositories
- Enhance test cases to check image cache repository inheritance when
  --from-repositories is passed
- Fix race condition when inheriting buildspec options: Instead of consuming the compiler one, annotate the updates in the
package BuildOption spec which is passed by
- Update vendor
This commit is contained in:
Ettore Di Giacinto
2021-04-21 17:59:56 +02:00
parent 788b889d14
commit c9aed37fa7
9 changed files with 265 additions and 44 deletions

View File

@@ -102,7 +102,7 @@ type LuetCompilationSpec struct {
Includes []string `json:"includes"`
Excludes []string `json:"excludes"`
BuildOptions options.Compiler `json:"build_options"`
BuildOptions *options.Compiler `json:"build_options"`
}
func NewLuetCompilationSpec(b []byte, p pkg.Package) (*LuetCompilationSpec, error) {
@@ -119,7 +119,7 @@ func (cs *LuetCompilationSpec) GetSourceAssertion() solver.PackagesAssertions {
}
func (cs *LuetCompilationSpec) SetBuildOptions(b options.Compiler) {
cs.BuildOptions = b
cs.BuildOptions = &b
}
func (cs *LuetCompilationSpec) SetSourceAssertion(as solver.PackagesAssertions) {