diff --git a/builder/build.go b/builder/build.go index 85114d9d72..dc360b92ea 100644 --- a/builder/build.go +++ b/builder/build.go @@ -344,6 +344,10 @@ func Build(pkgName, outpath, tmpdir string, config *compileopts.Config) (BuildRe } packageActionIDJobs[pkg.ImportPath] = packageActionIDJob + // Build the SSA for the given package. + ssaPkg := program.Package(pkg.Pkg) + ssaPkg.Build() + // Now create the job to actually build the package. It will exit early // if the package is already compiled. job := &compileJob{