Preface
I am partially sighted and find IDEs incredibly hard to use. If you wanted to hire me for a job that required using one, I'd be looking for at least ten times as much money, and warning you that my productivity would be utterly pathetic. Imagine using an IDE whose menus are in a language you can't read, where the screen flashes to a painful intensity at random intervals of thirty seconds or so. That's how about hard I find them.
Situation
I work on libraries, not applications. The main product I work on is a mathematical modelling library, which is quite large (about 25 million LoC) and built for many platforms, including iOS/iPadOS. The conventional way to do this would be to run the modelling on a cloud service, but there are customers who are willing to pay large amounts to run it on devices.
We have to create an app to run testing on iPads, but we do not distribute that app, not even to other parts of the same company. The app is just a wrapper round a command-line test harness, which redirects input and output to files. It has no GUI at all, and there is no value in providing one.
We understand the various processor architectures that Apple uses. We provide dylibs for Apple Silicon macOS and Intel macOS. We provide static libraries for ARM iOS/iPadOS and for the iOS Simulator on Intel.
Problem
On macOS we build dylibs with no difficulty and use them in the command-line test harness. I want to do the same for iOS/iPadOS, but Apple's documentation is all about using the IDE, and defeats me. We ship the libraries in static (aka archive) form, and customers use those successfully.
Can one build a dylib for iOS/iPadOS from the command line in a similar way to doing it for macOS?
If that is possible, how does one link it into a (very) basic iOS/iPadOS app? We have to do the linking and test-running via the xcodebuild
tool, but we change that project as little as possible.