Skip to content
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

[WIP] Add minimal CMake support #82

Merged
merged 1 commit into from
Apr 22, 2024

Conversation

kabiroberai
Copy link
Contributor

Adds enough CMake support to get WasmKitWASI importing in the Swift compiler's build system. Marking as a draft until I can fully test this.

@kateinoigakukun kateinoigakukun linked an issue Apr 22, 2024 that may be closed by this pull request
@kabiroberai kabiroberai marked this pull request as ready for review April 22, 2024 04:26
@kabiroberai
Copy link
Contributor Author

Was able to confirm that this gets things building correctly. I based the Swift CMake utils off of the ones in swift-syntax; I don't have too much experience with CMake though so let me know if there's any glaring issues or just things I may not have considered in general cc @kateinoigakukun

Copy link
Member

@kateinoigakukun kateinoigakukun left a comment

Choose a reason for hiding this comment

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

LGTM! I'll add CI checks

@kateinoigakukun
Copy link
Member

We might be able to use CMake's native Swift support, but let's go ahead for now.

@kateinoigakukun kateinoigakukun merged commit c3a08eb into swiftwasm:main Apr 22, 2024
6 checks passed
@kabiroberai
Copy link
Contributor Author

We might be able to use CMake's native Swift support

This is indeed what this PR uses fyi — the AddSwiftHostLibrary utils layer on top of CMake's built-in Swift support. I'm not sure why there's explicit handling for swiftmodules though, so maybe it's worth looking into whether that's redundant but it gets the job done right now so I don't want to cause any regressions by removing it.

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.

CMake build
2 participants