Psellos
Contemporary Development With Functional Programming

iOS Development

To make OCaml work on iOS devices I’ve had to learn about a few out-of-the-way parts of iOS. The pages listed here describe some of what I’ve discovered about iOS and iOS development, in the hope it may be useful to others who are using iOS in unusual ways.

Run iOS Simulator from the Command Line

I often want to run an app in the iOS Simulator for a quick test or demonstration, without the overhead of starting up Xcode. For times like this, I’ve written a shell script named runsim that installs an app and runs it in the iOS Simulator directly from the command line. For the latest version, I added the ability to launch the app in the simulator from the command line. It’s a little tricky, but it works well. You can read the details in Run iOS Simulator from the Command Line.

Convert Linux ARM Assembly Code for iOS

While getting OCaml 4.00.0 working on iOS, I learned quite a bit about the differences between the Linux ARM assembler and the iOS ARM assembler. This information was difficult to come by—I spent many hours reading the assembler source code at Apple’s open source site. To show what I found out, I’ve written a Python script named arm-as-to-ios that translates Linux ARM assembly code into iOS ARM assembly code. You can read about it in Convert Linux ARM Assembly Code for iOS.