chalet
chalet copied to clipboard
Export - Xcode project format
The wip exploration is in xcode-project.json and the "Build: Release (Xcode)" task, and hook into XcodeGen via Swift.
https://github.com/yonaskolb/XcodeGen
My original thinking:
- Generate an xcode-project.json (into the build folder) from build.json
- Call XcodeGen via Swift and pass it the xcode-project.json path and other options
- Save the xcode project path to the build folder or something
The problem with this is, to go through Swift, part of Chalet would need to be built for Swift and Objective-C++
Objective-C++ support in Chalet works, but interfacing with the Swift compiler is not a thing yet
The alternative is to figure out Xcode project generation from a purely C++ way
2022:
- [x] export route
- [x] "xcodebuild" build strategy
- [x] check for xcodegen & tell the user to install it from brew if they don't have it
- [x] generate the spec file in json
- [ ] generate the spec in yaml - easier to maintain
- [ ] adapter architecture that plays nicely with the existing apple clang generators
- [ ] support all the things
- [ ] Figure out variables needed for each build configure instead of using default debug/release presets
- [x] pass the spec file to xcodegen and generate the project in the export folder
- [x] call xcodebuild at the command line like with msbuild... it should be pretty similar code
https://xcodebuildsettings.com