Skip to content

Commit

Permalink
refactor(build)!: Remove the preparation step (#601)
Browse files Browse the repository at this point in the history
Reviewed-by: Cezar Craciunoiu <[email protected]>
Approved-by: Cezar Craciunoiu <[email protected]>
  • Loading branch information
craciunoiuc committed Jul 5, 2023
2 parents 8f29c19 + cc76f4d commit 0d19d35
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions cmd/kraft/build/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ type Build struct {
NoConfigure bool `long:"no-configure" usage:"Do not run Unikraft's configure step before building"`
NoFast bool `long:"no-fast" usage:"Use maximum parallelization when performing the build"`
NoFetch bool `long:"no-fetch" usage:"Do not run Unikraft's fetch step before building"`
NoPrepare bool `long:"no-prepare" usage:"Do not run Unikraft's prepare step before building"`
NoPull bool `long:"no-pull" usage:"Do not pull packages before invoking Unikraft's build system"`
NoUpdate bool `long:"no-update" usage:"Do not update package index before running the build"`
Platform string `long:"plat" short:"p" usage:"Filter the creation of the build by platform of known targets"`
Expand Down Expand Up @@ -461,26 +460,6 @@ func (opts *Build) Run(cmd *cobra.Command, args []string) error {
))
}

if !opts.NoPrepare {
processes = append(processes, paraprogress.NewProcess(
fmt.Sprintf("preparing %s (%s)", targ.Name(), target.TargetPlatArchName(targ)),
func(ctx context.Context, w func(progress float64)) error {
return opts.project.Prepare(
ctx,
targ, // Target-specific options
append(
mopts,
make.WithProgressFunc(w),
make.WithExecOptions(
exec.WithStdout(log.G(ctx).Writer()),
exec.WithStderr(log.G(ctx).WriterLevel(logrus.ErrorLevel)),
),
)...,
)
},
))
}

processes = append(processes, paraprogress.NewProcess(
fmt.Sprintf("building %s (%s)", targ.Name(), target.TargetPlatArchName(targ)),
func(ctx context.Context, w func(progress float64)) error {
Expand Down

0 comments on commit 0d19d35

Please sign in to comment.