Skip to content

Moving to Swift Cross UI and Swift Bundler#39

Open
philocalyst wants to merge 7 commits intollsc12:mainfrom
philocalyst:scui
Open

Moving to Swift Cross UI and Swift Bundler#39
philocalyst wants to merge 7 commits intollsc12:mainfrom
philocalyst:scui

Conversation

@philocalyst
Copy link
Copy Markdown

Currently included are commits moving to SPM and Swift Bundler, and fixes to the warnings I encountered in the process. What is NOT included is the work needed to run the app ENTIRELY off of Swift Bundler, because the mesh-shaders dep doesn't expose their shaders in a way in which Bundler can compile them. We would need to contribute or fork to handle this. That, and the inclusion of libswiftCompatibilitySpan.dylib throws Bundler for ANOTHER loop, and we'd have to move the project in a direction where it would no longer be needed to avoid that.

Locally, I have a build script that patches over both issues, but it's very messy.

Just wanted to let you know.

@llsc12
Copy link
Copy Markdown
Owner

llsc12 commented Mar 15, 2026

i was hoping you’d make a new project rather than migrate the existing one. the existing app uses a lot of appkit and uikit that won’t work with scui!

@philocalyst
Copy link
Copy Markdown
Author

philocalyst commented Mar 15, 2026 via email

@llsc12
Copy link
Copy Markdown
Owner

llsc12 commented Mar 15, 2026

yeah i think that might have been my bad. my apologies! i don’t think migration of the main swiftui application really requires migration to swift bundler if only the scui application needs it. also im struggling to make an scui app to test out scui, not sure why. fails at package resolution :c

@philocalyst
Copy link
Copy Markdown
Author

philocalyst commented Mar 16, 2026 via email

@llsc12
Copy link
Copy Markdown
Owner

llsc12 commented Mar 16, 2026

i suppose so, though i'm a bit sad you removed the camera dependency since it looked nice lol.

i did use the template without modifying it to no avail, which is odd. i tried using swift 5.10 which didn't help either.

@stackotter
Copy link
Copy Markdown

Would you happen to have a copy of the specific error you're facing?

@llsc12
Copy link
Copy Markdown
Owner

llsc12 commented Mar 17, 2026

🌱 Finding latest version of swift-bundler
🌱 Running swift-bundler v2.0.7...
info: Starting debug build
Fetching https://github.com/stackotter/swift-cross-ui from cache
Fetched https://github.com/stackotter/swift-cross-ui from cache (4.26s)
Fetching https://github.com/stackotter/swift-windowsappsdk from cache
Fetched https://github.com/stackotter/swift-windowsappsdk from cache (0.44s)
Fetching https://github.com/thebrowsercompany/swift-windowsfoundation from cache
Fetched https://github.com/thebrowsercompany/swift-windowsfoundation from cache (0.47s)
error: package 'swift-windowsfoundation' is required using a revision-based requirement and it depends on local package 'swift-cwinrt', which is not supported
error: Failed to build 'paicordscui': Failed to run '/usr/bin/swift build -c debug --product paicordscui --arch x86_64': The process returned a non-zero exit status (1)'

@stackotter
Copy link
Copy Markdown

Ah yeah, that’s an outdated version of Swift Bundler - kind of. It’s a complicated story, but tldr I’m working on a Swift Bundler release (and have been for quite a while), so there are a ton of new things on main that are not in a tagged release. You should run moreSwift/swift-bundler@main instead for now. You may have to run swift bundler templates update after updating to the main branch of Swift Bundler, but ideally not if my v2 to v3 migration code works as advertised.

In your case the immediate issue is that the SwiftCrossUI version used in the old template broke due to an upstream package (which we have since forked) that made a strange broken commit a while ago and never fixed it. If you manually change the scui version in the Package.swift file to 0.2.1, things should work.

@llsc12
Copy link
Copy Markdown
Owner

llsc12 commented Mar 17, 2026

oh ok, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants