3 ms·
I could have worded this better since running xcodebuild is obviously outside of Xcode. But it's not a stretch. Is it possible? Yes, of course. Bazel and Buck
by trevor-e 2y ago
I could have worded this better since running xcodebuild is obviously outside of Xcode. But it's not a stretch.
Is it possible? Yes, of course. Bazel and Buck iOS builds have existed for a long time, and many large teams use them. You can even use Gradle to build an iOS project.
Does Apple officially support any of those? No, you won't find any Apple instructions telling you how to do any of this, Apple expects iOS apps submitted to the store to be built with Xcode. You're on your own with these solutions. And setting up Bazel for an iOS project is not an easy undertaking.
- saurik 2y agoThere might not be end-to-end hand-holding for how to do it, but all of the needed tools are documented, and each one is individually supported. All you are doing is using clang to build a binary -- the same way you would build a binary in any other circumstance -- placing it into a .app container, code-signing it, and zipping the result to get your .ipa file. The codesign tool is documented and clearly supported by Apple, as is the manual provisioning portal, itself a website clearly designed for people to directly futz with. There is copious documentation on how to use clang, as well as on how .app bundles are organized. The only even sort of awkward thing -- like the closest you can get to an argument that any of this "isn't officially supported" -- is some awkward keys you have to place in your Info.plist... but like, that's it (and for all I know it is, too, documented somewhere... I haven't ever looked as it was just a few lines of XML to copy). Even the tool for uploading your build to the App Store without using Xcode--the one step that I'd agree might feel off the beaten path if you have never tried to look into how to do it before--is fully documented by Apple. https://help.apple.com/itc/transporteruserguide/en.lproj/static.html https://help.apple.com/itc/transporteruserguide/en.lproj/sta... Yes: you have to know how to put the steps into order, but it is a stretch to say it isn't officially supported as Apple clearly is not merely not rejecting people who do this... they are going out of their way to support all of this tooling. They could have only provided a way to do this in Xcode, but they didn't. As for "being on your own"... that's software development! We might as well claim there is not only no officially supported way to build a C/C++ command line tool, or even a JavaScript-enabled website, as there is no official upstream. Yet, on the other side, there are numerous supported ways to build such programs in myriad frameworks, some more difficult than or with more build steps than others, each supported by the open source community. If you don't know how to build a binary, how to make a .app folder, how to run codesign, or how to use Transporter, maybe your fancy LLM can do it for you? Isn't that what people are using them for anyway? To quickly generate and manage all of the boilerplate of a project? I bet it can even help you set up Bazel (though I recommend just using GNU Make, as it really isn't difficult to hand-build a binary).