Skip to content

Conversation

scottrhoyt
Copy link
Collaborator

@scottrhoyt scottrhoyt commented Oct 2, 2025

Issue/Motivation

This allows MapLibreSwiftUI to build against swift-syntax 602.0.0. Since the release of swift 6.2, the experimental prebuilts functionality was removed for 6.1. This restores the ability to use swift-syntax prebuilts to dramatically speed up build times.

@hactar
Copy link
Collaborator

hactar commented Oct 2, 2025

Changes look sane, but the tests are failing?

@scottrhoyt scottrhoyt force-pushed the update-swift-syntax branch from fd86479 to 3951fff Compare October 2, 2025 22:26
@scottrhoyt
Copy link
Collaborator Author

I updated to swift-syntax 602.0.0 explicitly in the Package.resolved let's see if that's it. It's the same issue that @ianthetechie was mentioning on the Discord.

@scottrhoyt
Copy link
Collaborator Author

Still failing, do you happen to know what version of Xcode and swift the test runner is using?

@ianthetechie
Copy link
Collaborator

It was Slack but same difference ;)

The Xcode version is 26.0.0. You can find this buried in the build logs.

@scottrhoyt
Copy link
Collaborator Author

I was building the MapLibreSwiftUI library and not the MapLibreSwiftUI-Package scheme synthesized by SPM. Once I switched, I reproed the build error.

The package scheme builds the test targets as well which reveals the error. The tests depend on https://github.com/pointfreeco/swift-macro-testing which in turn extends swift-syntax. This sort of mixing of build environments is Xcode is a known issue currently.

The immediate solution is to disable prebuilts for the GitHub build using...

defaults write com.apple.dt.Xcode IDEPackageEnablePrebuilts NO

...which I verified to work locally in building the *-Package scheme. Downstream deps can still use the prebuilts as they aren't building the test code.

Note: If you are testing this locally, you will need to reset your package cache and clean your project to fully flush the pre-built and build swift-syntax from source.

So this change should be fine in that it doesn't introduce any problems that don't already exist. A separate change to disable prebuilts for the GH actions is recommended.

@scottrhoyt
Copy link
Collaborator Author

Rebased on the CI changes, so this should be good to go now.

@ianthetechie ianthetechie merged commit 210b632 into maplibre:main Oct 11, 2025
2 checks passed
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.

4 participants