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

Add support for XCFrameworks with .dylib libraries #6133

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

eddieh
Copy link

@eddieh eddieh commented Mar 29, 2024

Tuist should not error when an XCFramework contains .dylib libraries

Short description πŸ“

According to the XCFramework documentation "an XCFramework can include dynamic library files" for macOS. This indeed works without fail and should be allowed. However, the documentation is wrong or outdated for iOS and iOS Simulator. These platforms also allow .dylib libs in an XCFramework.

Tuist does not allow dynamic library files even for macOS. Using an XCFramework containing .dylib files, regardless of platform, throws a "XCFrameworkMetadataProviderError.supportedArchitectureReferencesNotFound" error and prints "couldn't find any supported architecture [...]" which, at the very least, is misleading.

How to test the changes locally 🧐

Include a set of steps for the reviewer to test the changes locally (see the documentation for reference).

Contributor checklist βœ…

  • The code has been linted using run mise run lint:fix
  • The change is tested via unit testing or acceptance testing, or both
  • The title of the PR is formulated in a way that is usable as a changelog entry
  • In case the PR introduces changes that affect users, the documentation has been updated

Reviewer checklist βœ…

  • The code architecture and patterns are consistent with the rest of the codebase
  • Reviewer has checked that, if needed, the PR includes the label changelog:added, changelog:fixed, or changelog:changed, and the title is usable as a changelog entry

Tuist should not error when an XCFramework contains .dylib libraries
@pepicrft
Copy link
Contributor

Thanks a lot, for creating a PR for this one @eddieh. I noticed you marked it as "draft". Is there anything else that that should be added?

@pepicrft pepicrft added the changelog:added PR will be listed in the Added section of CHANGELOG label Mar 29, 2024
@pepicrft pepicrft changed the title An XCFrameworks may use .dylib libraries Add support for XCFrameworks with .dylib libraries Mar 29, 2024
@eddieh
Copy link
Author

eddieh commented Mar 29, 2024

I intended to add a little more to the description, but I now think it is sufficient. I'm using this change in several projects and it works great. This is ready for review.

@eddieh eddieh marked this pull request as ready for review March 29, 2024 22:01
Copy link
Member

@fortmarek fortmarek left a comment

Choose a reason for hiding this comment

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

Looks good! Would you mind also adding an acceptance or a unit test? Afterwards, I think we can merge πŸ™

@apps4everyone
Copy link
Sponsor Contributor

I think this is also missing
#6153

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog:added PR will be listed in the Added section of CHANGELOG
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants