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

Rosetta label for simulators #16

Open
jfd02 opened this issue Jun 7, 2024 · 4 comments
Open

Rosetta label for simulators #16

jfd02 opened this issue Jun 7, 2024 · 4 comments

Comments

@jfd02
Copy link

jfd02 commented Jun 7, 2024

Our project requires compilation using rosetta simulators, right now I don't believe this label is being displayed in the simulator list

@hyzyla
Copy link
Collaborator

hyzyla commented Jun 7, 2024

Hello! I've never worked with Rosetta simulators. Could you tell me how I can create a project like that in Xcode?

@jfd02
Copy link
Author

jfd02 commented Jun 9, 2024

In Xcode you can go to Product > Destination > Destination Architectures > Show both

@hyzyla
Copy link
Collaborator

hyzyla commented Jun 9, 2024

Thank you so much! I'll check later after vacation

@hyzyla
Copy link
Collaborator

hyzyla commented Jun 16, 2024

Hello! As I understand how simulators work, we don't need to run the simulator in Rosetta mode. We just need to build the application for the x86_64 architecture, and then, when you run the application on the simulator, macOS can automatically determine that the application should be run in Rosetta mode. I've found that to build the application for the x86_64 architecture, you can set ARCHS=x86_64 VALID_ARCHS=x86_64 ONLY_ACTIVE_ARCH=NO in your xcodebuild command (or in Xcode configurations). Here is the PR [1] that adds support for the "sweetpad.build.arch": "x86_64" configuration for building application for x86_64 architecture.

Let me know if this is the right direction to resolve your issue.

  1. https://github.com/sweetpad-dev/sweetpad/pull/18/files#diff-7d7056ba834da895f939e1ed1aa66cb323d19207384c944d47cf2d73d7a4772cR131

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

No branches or pull requests

2 participants