Files
punktfunk/clients/apple/Package.swift
T
enricobuehler 92933ef46b
ci / rust (push) Has been cancelled
fix(apple/tvOS): system-style slide for in-stack pushes (swiftui-navigation-transitions)
SwiftUI's NavigationStack on tvOS animates pushes as a bare crossfade with no public
customization — the system Settings app slides. The home stack now applies
.customNavigationTransition(.slide) on tvOS via davdroman/swiftui-navigation-transitions
(MIT, tvOS 13+), covering the top-level routes AND the settings pickers' drill-ins.

The dependency is referenced by the Xcode PROJECT only and linked solely by the
Punktfunk-tvOS target: its manifest (no macOS platform declared vs 10.15 deps) breaks
SwiftPM whole-graph validation for plain `swift build`, and the #if os(tvOS) import
never compiles in the macOS-only SwiftPM dev shell anyway. Headless builds need
xcodebuild -skipMacroValidation (the lib pulls Swift macro packages; in the Xcode UI
it's a one-time Trust & Enable prompt).

iOS/macOS keep their untouched system navigation animations.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-06-11 14:12:04 +02:00

34 lines
1.5 KiB
Swift

// swift-tools-version: 5.9
// PunktfunkKit Swift wrapper around the punktfunk-core C ABI (punktfunk/1 client connector) plus the
// SwiftUI/VideoToolbox presentation layer. Build PunktfunkCore.xcframework first:
// bash ../../scripts/build-xcframework.sh (on a Mac; see README.md)
import PackageDescription
let package = Package(
name: "PunktfunkKit",
platforms: [.macOS(.v14), .iOS(.v17), .tvOS(.v17)],
products: [
.library(name: "PunktfunkKit", targets: ["PunktfunkKit"]),
.executable(name: "PunktfunkClient", targets: ["PunktfunkClient"]),
],
targets: [
.binaryTarget(name: "PunktfunkCore", path: "PunktfunkCore.xcframework"),
.target(
name: "PunktfunkKit",
dependencies: ["PunktfunkCore"],
linkerSettings: [
// Rust staticlib system deps.
.linkedFramework("Security"),
.linkedFramework("SystemConfiguration"),
.linkedLibrary("resolv"),
]
),
// Development app shell (swift run PunktfunkClient): connect form stream + input.
// (The tvOS slide-transition package is referenced by the Xcode PROJECT only
// its manifest breaks SwiftPM whole-graph validation on macOS, and only the
// Punktfunk-tvOS target links it; the #if os(tvOS) import never compiles here.)
.executableTarget(name: "PunktfunkClient", dependencies: ["PunktfunkKit"]),
.testTarget(name: "PunktfunkKitTests", dependencies: ["PunktfunkKit"]),
]
)