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

Use clang modules in cinterop instead of headers #32

Merged

Conversation

IlyaGulya
Copy link
Collaborator

@IlyaGulya IlyaGulya commented Jun 28, 2024

This PR is based on #31 and should be reviewed and merged after #31.

This change makes cinterop support usage of clang modules in Objective-C headers.
This is required to be able to use any modern apple framework (including UIKit, AVFoundation, etc).

Basically, any Objective-C header containing @import directive requires modules to be enabled.

This change seems to be backwards compatible since we are generating cinterops for our own builds which are guaranteed to be clang modules.

Also, I've added iosX64 and iosSimulatorArm64 to list of targets which are required sdk path to be provided to swift build.

Finally, I've fixed all configuration cache issues.

Also, this fixes issue #25

@markst
Copy link

markst commented Jul 7, 2024

@IlyaGulya awesome! does this fix #25?

@IlyaGulya
Copy link
Collaborator Author

@IlyaGulya awesome! does this fix #25?

Yes, it should be fixed. 🙂
Noted this in the description of PR, thanks!

@IlyaGulya IlyaGulya force-pushed the feature/cinterop-modules-instead-of-headers branch from 058a392 to e58f2be Compare July 13, 2024 08:38
@IlyaGulya IlyaGulya force-pushed the feature/cinterop-modules-instead-of-headers branch from e58f2be to dad59aa Compare July 13, 2024 08:48
markst added a commit to markst/radioplayer-kt that referenced this pull request Jul 17, 2024
@IlyaGulya IlyaGulya merged commit 46dd1cf into ttypic:main Jul 18, 2024
@IlyaGulya IlyaGulya deleted the feature/cinterop-modules-instead-of-headers branch July 18, 2024 07:34
@markst
Copy link

markst commented Jul 20, 2024

@IlyaGulya are we able to tag this release?

@IlyaGulya
Copy link
Collaborator Author

@IlyaGulya are we able to tag this release?

@IlyaGulya are we able to tag this release?

Sure, I'll try to do it later this week.

@IlyaGulya
Copy link
Collaborator Author

@markst this is available in latest release: https://github.com/ttypic/swift-klib-plugin/releases/tag/v0.6.2

@markst
Copy link

markst commented Jul 22, 2024

Thanks @IlyaGulya !

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.

2 participants