go/src/cmd/go/internal/work/build.go

var CmdBuild

const concurrentGCBackendCompilationEnabledByDefault

func init() {}

var forcedAsmflags

var forcedGcflags

var forcedLdflags

var forcedGccgoflags

var BuildToolchain

var ldBuildmode

type buildCompiler

func (c buildCompiler) Set(value string) error {}

func (c buildCompiler) String() string {}

func init() {}

type BuildFlagMask

const DefaultBuildFlags

const OmitModFlag

const OmitModCommonFlags

const OmitVFlag

// AddBuildFlags adds the flags common to the build, clean, get,
// install, list, run, and test commands.
func AddBuildFlags(cmd *base.Command, mask BuildFlagMask) {}

// AddCoverFlags adds coverage-related flags to "cmd". If the
// CoverageRedesign experiment is enabled, we add -cover{mode,pkg} to
// the build command and only -coverprofile to the test command. If
// the CoverageRedesign experiment is disabled, -cover* flags are
// added only to the test command.
func AddCoverFlags(cmd *base.Command, coverProfileFlag *string) {}

type tagsFlag

func (v *tagsFlag) Set(s string) error {}

func (v *tagsFlag) String() string {}

type buildvcsFlag

func (f *buildvcsFlag) IsBoolFlag() bool {}

func (f *buildvcsFlag) Set(s string) error {}

func (f *buildvcsFlag) String() string {}

// fileExtSplit expects a filename and returns the name
// and ext (without the dot). If the file has no
// extension, ext will be empty.
func fileExtSplit(file string) (name, ext string) {}

func pkgsMain(pkgs []*load.Package) (res []*load.Package) {}

func pkgsNotMain(pkgs []*load.Package) (res []*load.Package) {}

func oneMainPkg(pkgs []*load.Package) []*load.Package {}

var pkgsFilter

func runBuild(ctx context.Context, cmd *base.Command, args []string) {}

var CmdInstall

// libname returns the filename to use for the shared library when using
// -buildmode=shared. The rules we use are:
// Use arguments for special 'meta' packages:
//
//	std --> libstd.so
//	std cmd --> libstd,cmd.so
//
// A single non-meta argument with trailing "/..." is special cased:
//
//	foo/... --> libfoo.so
//	(A relative path like "./..."  expands the "." first)
//
// Use import paths for other cases, changing '/' to '-':
//
//	somelib --> libsubdir-somelib.so
//	./ or ../ --> libsubdir-somelib.so
//	gopkg.in/tomb.v2 -> libgopkg.in-tomb.v2.so
//	a/... b/... ---> liba/c,b/d.so - all matching import paths
//
// Name parts are joined with ','.
func libname(args []string, pkgs []*load.Package) (string, error) {}

func runInstall(ctx context.Context, cmd *base.Command, args []string) {}

// omitTestOnly returns pkgs with test-only packages removed.
func omitTestOnly(pkgs []*load.Package) []*load.Package {}

func InstallPackages(ctx context.Context, patterns []string, pkgs []*load.Package) {}

// installOutsideModule implements 'go install pkg@version'. It builds and
// installs one or more main packages in module mode while ignoring any go.mod
// in the current directory or parent directories.
//
// See golang.org/issue/40276 for details and rationale.
func installOutsideModule(ctx context.Context, args []string) {}

var ExecCmd

// FindExecCmd derives the value of ExecCmd to use.
// It returns that value and leaves ExecCmd set for direct use.
func FindExecCmd() []string {}

type coverFlag

func (f coverFlag) String() string {}

func (f coverFlag) Set(value string) error {}

type coverModeFlag

func (f *coverModeFlag) String() string {}

func (f *coverModeFlag) Set(value string) error {}

type commaListFlag

func (f commaListFlag) String() string {}

func (f commaListFlag) Set(value string) error {}

type stringFlag

func (f stringFlag) String() string {}

func (f stringFlag) Set(value string) error {}