This document contains information on how to develop llbuild2.
swift build # Debug build
swift build -c release # Release build
swift test # Run all tests
swift test --filter llbuild2fxTests # Run specific test target
swift test --filter "EngineTests" # Run a specific test class
swift test --filter "EngineTests/testBasicKey" # Run a single test methodGenerated protobuf sources are checked in. Regenerate only when proto definitions change:
make generate # Regenerate all protobuf sources
make proto-toolchain # Build protoc toolchain first if needed
make update # Clone/update external proto reposFollow Swift project guidelines for contributing code. All public
types use the FX prefix.
New files use // Copyright (c) <current_year> Apple Inc. and the Swift project authors. When modifying an existing
file, update its copyright to a year range ending at the current year.
Prefer throw over fatalError wherever possible. If a function can throw, use a thrown error (e.g. an FXError
case) instead of crashing the process. Reserve fatalError / preconditionFailure only for true programming errors
that indicate a logic bug (e.g. unreachable code paths).