-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Labels
Description
Is it reproducible with SwiftPM command-line tools: swift build, swift test, swift package etc?
- Confirmed reproduction steps with SwiftPM CLI. The description text must include reproduction steps with either of command-line SwiftPM commands,
swift build,swift test,swift packageetc.
Description
Triple specified with the "triple" argument is not picked up by build:
swift build --triple arm64-apple-macosx15.0
Target: arm64-apple-macosx10.13
and specify target triple for swiftc is picked up by build
swift build -Xswiftc -target -Xswiftc arm64-apple-macosx15.0
Target: arm64-apple-macosx15.0
Expected behavior
swift build --triple triple-value override/set Package manifest platform target triple
Actual behavior
--triple value is ignored
Steps to reproduce
on macOS, build simple package with minimum manifest
// swift-tools-version:5.9
import PackageDescription
let package = Package(
name: "Foo",
products: [
.executable(
name: "Foo",
targets: ["Foo"]),
],
dependencies: [],
targets: [
.executableTarget(
name: "Foo",
dependencies: []),
]
)
swift build --triple arm64-apple-macosx15.0 -v
Target: arm64-apple-macosx10.13
Swift Package Manager version/commit hash
Swift Package Manager - Swift 6.1.0
Swift & OS version (output of swift --version ; uname -a)
swift-driver version: 1.120.5 Apple Swift version 6.1.2 (swiftlang-6.1.2.1.2 clang-1700.0.13.5)
Target: arm64-apple-macosx15.0
Darwin MarcinK-MacBook.local 24.5.0 Darwin Kernel Version 24.5.0: Tue Apr 22 19:54:33 PDT 2025; root:xnu-11417.121.6~2/RELEASE_ARM64_T8122 arm64