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

Dependencies.swift not generating xcframework with catalyst #4900

Closed
unxavi opened this issue Nov 30, 2022 · 5 comments · Fixed by #5108
Closed

Dependencies.swift not generating xcframework with catalyst #4900

unxavi opened this issue Nov 30, 2022 · 5 comments · Fixed by #5108
Labels
type:bug Something isn't working

Comments

@unxavi
Copy link
Contributor

unxavi commented Nov 30, 2022

What happened?

When using Dependencies.swift to generate the xcframeworks, are not generated with the framework for mac catalyst

How do we reproduce it?

  1. set deploymentTarget: .iOS(targetVersion: "14.0", devices: [.mac, .ipad, .iphone])
  2. run tuist fetch
  3. run tuist cache warm --xcframeworks
  4. run tuist generate --xcframeworks

When the project open, it's configured for ios, ipad and catalyst, but the generated xcframeworks doesn't contain catalyst.

Example project:
app_with_spm_dependencies.zip

Error log

/.tuist/Cache/BuildCache/261dde80769c1e179810d4ebd83fb1ee/abseil.xcframework:1:1 While building for Mac Catalyst, no library for this platform was found in '/.tuist/Cache/BuildCache/261dde80769c1e179810d4ebd83fb1ee/abseil.xcframework'.

image

macOS version

13.0.1

Tuist version

3.14.0

Xcode version

14.1

@unxavi unxavi added the type:bug Something isn't working label Nov 30, 2022
@danieleformichelli
Copy link
Collaborator

Not super familiar with Catalyst, would you have expected another architecture inside the xcframework? Do you have an example of such xcframework?

@unxavi
Copy link
Contributor Author

unxavi commented Dec 20, 2022

@danyf90 thanks for your reply. Yes, there should be a catalyst architecture generated for catalyst.

An example of a xcframework compatible with catalyst can be seen for example on the releases of firebase, stripe, revenuecat, etc. To list some examples:

Stripe for example https://github.com/stripe/stripe-ios/releases/

When you open the xcframework:

image

You can see that there is a Catalyst architecture there for the Stripe xcframework. What happens with Dependencies.swift is that is not generating the catalyst architecture only the ones for iOS, therefore the project is not compatible with Catalyst and a project can not enjoy the benefits of the Dependencies.swift and has to rely on the old SPM integration.

@danieleformichelli
Copy link
Collaborator

Thanks, then I think we should enhance or xcframework builder to take that into account if the target supports catalyst 🤔

If you would like to have a look at this we can provide pointer of what should be changed 💪

@unxavi
Copy link
Contributor Author

unxavi commented Dec 20, 2022

@danyf90 thanks, Tuist is a complex project, not sure if I could be able to help, but we can try.

@danieleformichelli
Copy link
Collaborator

danieleformichelli commented Jan 23, 2023

Maybe related to #4610?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
2 participants