BuildOperation
BuildOperation.swift:38final class BuildOperation
Citizens in Build
Conformances
protocol BuildErrorAdviceProvider
A provider of advice about build errors.
protocol BuildSystem
A protocol that represents a build system used by SwiftPM for all build operations. This allows factoring out the implementation details between SwiftPM’s
BuildOperation
and the XCBuild backedXCBuildSystem
.protocol Cancellable
protocol PackageStructureDelegate
Types
Type members
init(productsBuildParameters: BuildParameters, toolsBuildParameters: BuildParameters, cacheBuildManifest: Bool, packageGraphLoader: @escaping () throws -> ModulesGraph, pluginConfiguration: PluginConfiguration?, scratchDirectory: AbsolutePath, additionalFileRules: [FileRuleDescription], pkgConfigDirectories: [AbsolutePath], outputStream: OutputByteStream, logLevel: Basics.Diagnostic.Severity, fileSystem: Basics.FileSystem, observabilityScope: ObservabilityScope
)
Instance members
var buildPlan: SPMBuildCore.BuildPlan
var builtTestProducts: [BuiltTestProduct]
let cacheBuildManifest: Bool
If build manifest caching should be enabled.
var delegate: SPMBuildCore.BuildSystemDelegate?
func build(subset: BuildSubset
) throws Perform a build using the given build description and subset.
func cancel(deadline: DispatchTime
) throws Cancel the active build operation.
func getBuildDescription(subset: BuildSubset?
) throws -> BuildDescription Compute and return the latest build description.
func getBuildManifest(
) throws -> LLBuildManifest func getPackageGraph(
) throws -> ModulesGraph func packageStructureChanged(
) -> Bool func provideBuildErrorAdvice(for: String, command: String, message: String
) -> String?
Show implementation details (1)
Hide implementation details
var _buildPlan: BuildPlan?
The build plan that was computed, if any.
Instance features
func build(
) throws Builds the default subset: all targets excluding tests.