Question

Is it possible to write in Go for iPhone? I think following steps are required

  1. Compile Go as ARM Mach-O binary (I expect GCCGO be able to do that)

  2. Compile iPhone app as static library (I think it possible to rename main() -> main2(), etc)

  3. Compile Go as Mach-O binary linked with iPhone static library. Go will have to call main2.

  4. make some plist files, zip, sign

Was it helpful?

Solution

Minux maintains the Go iOS port here: https://bitbucket.org/minux/goios/wiki/Home

OTHER TIPS

Being able to compile and a go program is only part of writing go for the iPhone. You will still need bindings to the iOS API's in order to do anything interesting with it. Others have already given pointers to ports of the language to iOS but you'll still have a long way go after that.

Since this question is 4 years old now and a lot has happened since then I thought I'd add to the already existing answers:

This github project supports writing native applications entirely written in Go for Android and iOS (with a limited subset of APIs available, however) and SDK applications where the Android or iOS native code communicates with the Go code via bindings.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top