Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var CargoLock sync.Mutex
CargoLock prevents multiple concurrent cargo executions.
Functions ¶
This section is empty.
Types ¶
type CompileInput ¶
type CompileInput struct {
// Where the source code is located.
PackageRoot FSPath
// The cargo 'target' directory to use for compiled outputs.
CargoTargetDir FSPath
// True if it should be built with `--release`.
ReleaseBuild bool
ArtifactName string
CargoTarget string
UseZig bool
ZigGlibcVersion string
ExtraEnvs []string
}
type CompileOutput ¶
type CompileOutput struct {
// Path to the built artifact.
Artifact FSPath
}
func Compile ¶
func Compile(ctx context.Context, in CompileInput) (*CompileOutput, error)
Compile compiles a rust program.
Click to show internal directories.
Click to hide internal directories.