Kickstarter - Headless JVM for iOS

The minute you write a JVM that runs actual Java classes on iOS, Apple will block it at the AppStore level - they killed Adobe and they’d kill Java. Put as much money as you want into building a VM - wasted time. Better bet would be improve the automated conversion approaches.

Kev

Apple is a horrible company, I agree, but I don’t see a big difference between a real JVM and the automated approaches. Both get your Java apps on iOS. Both could be blocked.

Did you see the links pitbuller and I posted? Avian is a JVM that runs on iOS. It does JIT so only runs on jailbroken iShit, but AOT compilation can be done.

You’re missing the point. The automated conversions are not Java programs, they are native iOS programs. Adobe Flash got killed because Apple does not want a platform-in-the-middle, which is a category JVM also falls under.

In fact Adobe themselves are adding iOS as a compile target for applications built with their upcoming Flash development suites.

Maybe with Steve Jobs out of the picture, new guy might be more open to a few changes.

Also sometime in 08 and 09, google did build an entire VM to run java on iOS and it worked really great, but apple changed mind about approving it. However I think it still stayed a VM and JIT compiling and not AOT. I ¿thought¿ it was the JIT compiling that apple didnt like. Though I know very little about it and my information is old/fragmented

edit:
though there always could be some hidden converter apps out there that might actually work good. you never know

?anyone heard of: http://www.in-the-box.org/

Pahahaha good luck with that…

No, you are missing the point. Avian compiles Java to native code that runs on iOS.

It’s not a JVM then, it’s a Java native compiler?

All the examples I can see on the Avian website are about using it as a JVM, i.e. embedding it in your application and packaging your JARs along with it. If thats the case, Apple will reject it based on it being a “scripting” language (their words).

As to whether it’s a native application or not (and from what I can see, it’s not), on every submission Apple scan the symbols in the object files. There are particular names they’re looking for. I doubt Avian is on their scope yet but if once it is, it’s blocked for everyone - and anyone using it already will get pulled. I’ve tried a few different routes so far and they get hit in similar ways.

Trying to trick Apple into letting your application onto the AppStore isn’t a way to run a business. XMLVM have had the thumbs up from Apple so far (not that they couldn’t change their mind in a second).

With respect to GCJ, I tried for a few days on the Mac and couldn’t get anything to actually target ARM correctly. I’m sure it’s possible I just haven’t see it yet.

Kev

I was under the impression that Apple had relaxed this restriction? Certainly I hear of several games using Lua as a scripting language that aren’t having any trouble.

Edit:

[quote]“In particular, we are relaxing all restrictions on the development tools used to create iOS apps, as long as the resulting apps do not download any code,” Apple said in a statement released to the press. “This should give developers the flexibility they want, while preserving the security we need.”
[/quote]

Thats entirely selective - Adobe products still being prevented under this “clause”. Last I checked, Apple were not fans of Java.

Kev

Look for “bootimage” here:
http://oss.readytalk.com/avian/building.html

From here:

[quote]Bootimage (i.e.
ahead-of-time-compiled) builds are not yet supported because Avian can’t
currently build a bootimage targeting a different architecture than the
build system, and I haven’t tried installing GCC on the iPhone to do
native builds. The lack of cross-architecture build support for
bootimages is something I’ve wanted to address for a while, and this may
be a good time to finally do it.
[/quote]

[quote]Trying to trick Apple into letting your application onto the AppStore isn’t a way to run a business.
[/quote]
Being at the complete mercy of such a nasty company isn’t a way to run a business.

Apple are entirely fine with Java on iOS - so long as it doesn’t have the ability to JIT code. This is the root of their objection. Excelsior JET is an AOT compiler that just so happens to be every bit as good (well ok let’s be honest, it’s a bit better) than the Sun JRE.

The XMLVM solution has the problem that it is shit. I can qualify “shit” with the following: it is a nightmare to figure out; it is virtually unsupported; as it is not a certified JVM it is full of little idiosyncrasies in the way that it works that are likely to catch you out; it most likely doesn’t have particularly great garbage collection (though I couldn’t say for sure); and the code it generates is little faster than interpreted, which is no good for anything vaguely heavyweight.

Cas :slight_smile:

Reference or at least source? And I said Apple won’t accept a JVM on iPhone - AOT is a different story.

That comes from your masses of experience with it does it? I don’t think the version I use is good for anything heavyweight, however the C/register based backend shows impressive performance. Everything you’ve put above just smacks as I took a 5 minute look at it and I couldn’t get it working.

I think you’d agree you’re lazy in this department, you just want it to work with no changes to your java or process at all, which is of course entirely understandable from a business point of view. However, there are two choices here:

a) Invest a cubic-shit-tonne of cash to someone else doing this.

b) Help do the work yourself (and of course potentially waste effort better spent on producing games)

I do think it’s a bit off criticizing the hard work of others over many hours, when you haven’t actually tried it in earnest.

Kev

For what it’s worth, I totally agree with you. However, thats life I guess - want the market, play the game. Can’t say I’m sure I’ll bother again, the sales on Android are like x2 what they are on iPhone for my genre. Probably will if it costs me nothing (like currently).

Kev

[quote]I do think it’s a bit off criticizing the hard work of others over many hours, when you haven’t actually tried it in earnest.
[/quote]
Well that concept is all wrong.
If something is somebody’s job and he or she isn’t doing a good enough job, and people notice, they can criticize.
If not you couldn’t even criticize a reckless bus driver, just because you have never driven a bus.

Gaming example: Fallout 3 and vegas had a lot of annoying bugs, even though I may not be able to write code that vast to begin with, it’s their job to do as best as they can; and there are quality expectancies in the industry.
JVM/compiler engineering same story. Whoever writes one should make sure its industry standard quality.

Also

[quote]Excelsior JET is an AOT compiler that just so happens to be every bit as good (well ok let’s be honest, it’s a bit better) than the Sun JRE
[/quote]
Since Java belongs to Sun, was made by Sun, by default, Sun’s JVM and compiler should be the very very best.

bottom line: it’s their job to do this, so you can bitch about it.

[quote]Since XMLVM is currently in an early development phase we do not provide a stable release. All releases currently offered are experimental development releases that are not to be used in a production environment.
[/quote]
To be fair XMLVM is still an early development phase so judging it now before it even has a stable release is a bit premature. That quote is directly from the XMLVM download page, so please correct me if I’m wrong.

Ah, but in this case we’d be criticizing the bus driver having never even seen them drive a bus?

Kev

Agreed, though that comment is possible not quite as true for the last version which built to Objective-C, you know the one I’m using for Legends of Yore.

Kev

Yeah, the arbitrary Apple accept/reject is the main reason I haven’t tried anything serious on iPhone (XMLVM or otherwise). I’ve heard too many horror stories about people’s apps being rejected (or initially accepted, then arbitrarily rejected) with no proper appeals process or even basic feedback. If you’re a popular app you can get enough outrage on your side but as a small startup that’s not really an option.

But hell, what do I know - my only attempt at a commercial app I abandoned because no bugger liked it.

The process can be pretty painful, but if you have the right sort of game I suspect the reward is great. The feedback process on rejections is much better in the last 6 months for me.

Kev

PS. Which game wasn’t liked? I loved the helicopter majig.

Odd timing and slightly off topic but I just got an email from Apple

[quote]Dear namrog84,

We are pleased to announce the availability of the auto-ingest tool, a new tool that lets you automatically retrieve your daily and weekly reports from the Sales and Trends module. The auto-ingest tool is a Java-based script that will run on any operating system that supports Java 1.6 or later. Before you begin using the tool, we strongly urge you to read the App Store Sales and Trends Guide and note the following:

* Use of this tool is monitored.
* If your system will be set up to automatically pull daily or weekly reports, allow 15-minute intervals between pulls.
* For further information about daily and weekly report availability, refer to the App Store Sales and Trends Guide.

If you have any questions, contact us.

Regards,

The App Store team
[/quote]
Apple provides access to a Java based tool to allow you to automate the download of your iTunes Connect
Sales and Trends reports.
” from inside apple pdf that came with email

You must have Java installed on the machine where you are running the Apple auto-ingest tool. The tool will work as
expected with Java version 1.6 or above
.” -from inside apple pdf that came with email

So even though Apple may not like java on the iOS. This in my mind proves they don’t completely despise java. Because they are releasing stuff in Java still.

I find it slightly funny as this relates to sales and trends of the iOS app store sales/downloads… And they are using Java.
Sooo close, yet soo far…

------------------------------------------------------------------------(2nd post)-----------

http://weblogs.java.net/blog/mkarg/archive/2010/09/10/apple-finally-permits-java-iphone-when-will-oracle-deliver
http://www.java.net/external?url=http://www.apple.com/pr/library/2010/09/09statement.html

I thought Flash or something now has or will soon have a “export to iOS” where it packages everything together differently specifically for it.
Do you think Oracle(Sun) are/were working on anything and just haven’t announced it yet?

Where its not a JIT VM but a complete packaged together AOT specifically for the iOS?

------------------------------------------------------------------------(3rd post)-----------

Sun was originally talking with a company called InnaWorks to do what I think we were discussing here
http://www.innaworks.com/alchemo-for-iphone-java-me-j2me-to-iphone-porting/
http://www.innaworks.com/
“Targeting multiple mobile platforms? Had enough of porting?
Convert your Java ME applications to Android, BREW, Brew MP, iPhone, Adobe Flash Player and Windows Mobile with alcheMo”

Has anyone tried innaworks? (if its even released?)