Skip to content

New native Xcode project generator. #6411

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

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from

Conversation

JX-Master
Copy link

This pull request implements a native Xcode project generator for macOS development. The new project generator is temporary named as Xcode2 to distinguish with the old generator, and has the following features:

  1. Generate Xcode projects from xmake.lua directly, without the need to install and use CMake.
  2. Map files, builds rules and targets to corresponding Xcode concepts (files, groups, configurations, targets, etc).
  3. Triggering build in Xcode invokes xmake to build targets by using custom building phases of Xcode. xmake callbacks like before_build, after_build, before_install, after_install, etc will be called as expected.
  4. Redirect xmake build directory to Xcode BUILD_DIR, so that invoking Clean build folder in Xcode will remove all xmake intermediate and output files as expected.
  5. Running & debugging in Xcode is supported, with additional graphics debugging support if the application uses Metal.
  6. Application bundle (.app) is supported if xcode.application rule is specified (currently only works for macOS applications. iOS applications will be supported later).

Note that this is still a very early version and needs further improvements and bug-fixes. I tested this generator on my own project and it worked fine, but more projects should be used to test this generator before it can be released.

@JX-Master
Copy link
Author

This fixes #4810

@waruqi
Copy link
Member

waruqi commented May 9, 2025

Thanks, but I need a few days to review it. Because I don't have much free time recently.

@waruqi waruqi added this to the v3.0.0 milestone May 9, 2025
@waruqi
Copy link
Member

waruqi commented May 9, 2025

I tried to run and debug program, it cannot be loaded.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants