News

Open Source Compiler for Java to iOS Released

The first stable release (1.0) of the RoboVM ahead-of-time (AOT) compiler and runtime library for Java is now available.

Developed by Swedish company Trillain Mobile, the open-source tool is designed to bring Java and other JVM languages to iOS.

The company says its goal is to "turn the world's 10 million Java developers into cross-platform mobile developers by making Java 8 work on both iOS and Android devices."

Based on Android's runtime, RoboVM translates Java bytecode to ARM or x86 machine code without being interpreted. The result is code that runs directly on the target CPU.

Although the primary target of this release is Java on iOS, RoboVM can produce Linux and Mac OS X x86 executables, the company says. Currently, a Mac and XCode are required to use RoboVM.

Along with Java, the list of JVM languages supported by RoboVM includes Scala, Kotlin, Groovy and Clojure.

This release comes with a Java-to-Objective-C bridge (called "Bro," which is Swedish for "bridge") that supports calls into native iOS CocoaTouch APIs. Objective-C objects can be used as though they are Java objects. The company claims Bro is simpler and easier to use than JNI (Java Native Interface) when it comes to interfacing with iPhone and iPad hardware, and for such iOS services as in-app purchasing and notifications.

According to the company, this release also includes an improved debugger with complete JDWP (Java Debug Wire Protocol) functionality (as part of a commercial license), which allows devs to debug a Java process from inside an IDE. It supports HFS+ file compression, includes a new Eclipse project wizard, and provides Maven archetype support.

The open-source RoboVM project tools are GPLv2 licensed. The runtime component is licensed primarily under the Apache License v2.0. Trillain Mobile maintains the open-source RoboVM technology, and sells commercial licenses and additional support packages.

A RoboVM for Eclipse plugin, which integrates the AOT compiler with the Eclipse Java IDE, is available from the Eclipse Marketplace. Eclipse is the product's default development environment. "Using the plug-in, launching apps on the simulator or on an iOS device is as easy as launching ordinary Java applications," the company says.

Also, the company has just released an alpha build of a RoboVM plugin for the Intellij IDEA Java IDE. RoboVM is also supported in Android Studio.

The company said it plans to include integration with the Xcode Interface Builder in the next release, due in Q2. It will be offered as a commercial feature, the company says.

About the Author

John K. Waters is a freelance author and journalist based in Silicon Valley. His latest book is The Everything Guide to Social Media. Follow John on Twitter, read his blog on ADTmag.com, check out his author page on Amazon, or e-mail him at john@watersworks.com.


Featured

Upcoming Events

AppTrends

Sign up for our newsletter.

I agree to this site's Privacy Policy.