build

package
v8.1.0+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 26, 2017 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

The build package houses the core functionality for actually building targets.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(tid int, state *core.BuildState, label core.BuildLabel)

func OutputHash

func OutputHash(target *core.BuildTarget) ([]byte, error)

OutputHash calculates the hash of a target's outputs.

func PrintHashes

func PrintHashes(state *core.BuildState, target *core.BuildTarget)

PrintHashes prints the various hashes for a target to stdout. It's used by plz hash --detailed to show a breakdown of the input hashes of a target.

func RemoveOutputs

func RemoveOutputs(target *core.BuildTarget) error

RemoveOutputs removes all generated outputs for a rule.

func ReplaceSequences

func ReplaceSequences(target *core.BuildTarget, command string) string

Replace escape sequences in the given string.

func ReplaceTestSequences

func ReplaceTestSequences(target *core.BuildTarget, command string) string

Replace escape sequences in the given string when running a test.

func RuleHash

func RuleHash(target *core.BuildTarget, runtime, postBuild bool) []byte

RuleHash calculates a hash for the relevant bits of this rule that affect its output. Optionally it can include parts of the rule that affect runtime (most obviously test-time). Note that we have to hash on the declared fields, we obviously can't hash pointers etc. incrementality_test will warn if new fields are added to the struct but not here.

func RuntimeHash

func RuntimeHash(state *core.BuildState, target *core.BuildTarget) ([]byte, error)

RuntimeHash returns the target hash, source hash, config hash & runtime file hash, all rolled into one. Essentially this is one hash needed to determine if the runtime state is consistent.

func StopWorkers

func StopWorkers()

StopWorkers does nothing, because in the stub we don't have any workers.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL