`error: [xrsimulator] Component Compatibility: EnvironmentLightingConfiguration not available for 'xros 1.0', please update 'platforms' array in Package.swift error: [xrsimulator] Exception thrown during compile: compileFailedBecause(reason: "compatibility faults") error: Tool exited with code 1
Build Vision Pro failed
Hi @SteveAcc ,
It's not clear what's really happening here without more context. However, I think if you update the platforms block in your reality kit content's Package.swift
file to look something like this:
let package = Package(
name: "RealityKitContent",
platforms: [
.visionOS(.v2),
.macOS(.v15),
.iOS(.v18)
],
it might clear up this issue.
Hi, thanks for your answer. However, it's still not working. To provide more context: I'm running an experiment on Vision Pro, and when I add the "EnvironmentLightingConfiguration" component in Reality Composer, my build fails (no issues before adding the "EnvironmentLightingConfiguration" component).
I'm using VisionOS 2.0, and I believe I don't need macOS or iOS for this project. When I open the Package.swift file, there's no platform block, and when I add the block you mentioned, I get an error: "v2 is unavailable."
Hey @SteveAcc,
Could you try upgrading to your PackageDescription to 6.0, this is when the .v2
version was made first available. I think this may fix this issue.
// swift-tools-version:6.0
Let me know if this works,
Michael