-
Notifications
You must be signed in to change notification settings - Fork 110
Open
Description
Hi there,
I am trying to build combine-schedulers for Android, but cross-compiling from macOS.
By updating dependencies for swift-concurrency-extras to 1.3.2 and xctest-dynamic-overlay to 1.7.0 I can get the package compiling by adding the OpenCombineSchedulers trait.
Unfortunately traits don't appear to work transitively, so when including combine-schedulers as a dependency to swift-dependencies (which is my goal to get building for Android), then I can't pass the trait.
And as I am building on macOS, the following lines in the Package.swift have no effect:
#if !canImport(Darwin)
package.traits.insert(
.default(enabledTraits: ["OpenCombineSchedulers"])
)
#endif
Would it be sufficient to check for the platform when conditionally depending on OpenCombineShim?
So:
.product(
name: "OpenCombineShim",
package: "OpenCombine",
condition: .when(platforms: [.linux, .android])
),
rather than:
.product(
name: "OpenCombineShim",
package: "OpenCombine",
condition: .when(platforms: [.linux, .android], traits: ["OpenCombineSchedulers"])
),
?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels