Skip to content

Support String Catalog symbol generation by adding String Catalogs as both Sources and Resources #8815

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: release/6.2
Choose a base branch
from

Conversation

matthewseaman
Copy link
Contributor

@matthewseaman matthewseaman commented Jun 12, 2025

This change adds support for String Catalog symbol generation by ensuring that String Catalogs get added to the Sources build phase in the same way that Asset Catalogs do.

Depends on: swiftlang/swift-build#582

@plemarquand
Copy link
Contributor

@swift-ci please test

@matthewseaman
Copy link
Contributor Author

Will fail in CI until SwiftBuild portion lands via swiftlang/swift-build#582

@bkhouri
Copy link
Contributor

bkhouri commented Jun 16, 2025

Thanks for this change, but would it be possible to add, or enabled, one or more automated tests that would validate the SwiftPM behaviour?

@matthewseaman
Copy link
Contributor Author

Thanks for this change, but would it be possible to add, or enabled, one or more automated tests that would validate the SwiftPM behaviour?

It would be the same as the Asset Catalog logic on the lines above. Are there existing tests for these code paths somewhere that it would make sense to add to?

@matthewseaman matthewseaman changed the title Support String Catalog symbol generation by always treating String Catalogs as Sources Support String Catalog symbol generation by adding String Catalogs as both Sources and Resources Jun 21, 2025
@matthewseaman
Copy link
Contributor Author

@swift-ci please test

@matthewseaman
Copy link
Contributor Author

@swift-ci test

@matthewseaman
Copy link
Contributor Author

matthewseaman commented Jun 21, 2025

Added tests in XCBuildSupportTests module.
Interestingly, I don't see a SwiftBuildSupportTests module.

@@ -2216,15 +2222,15 @@ final class PIFBuilderTests: XCTestCase {
Manifest.createRootManifest(
displayName: "Foo",
path: "/Foo",
toolsVersion: .v5_3,
toolsVersion: .v5_9,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bumped to the first tools version that supports xcstrings at all.

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