Hacker News new | ask | show | jobs
by on_and_off 3796 days ago
The NDK is not part of their priorities indeed (although to be fair it seems that things are slowly getting better with a team dedicated to integrating Clion).

They are smart engineers though and I have no doubt that if C++ had been the best choice for the platform, we would not be writing apps in java ...

tbh, I am really tired of the simplistic 'because java' argument with nothing to back it up ...

I have no love for the language (although I think it gets more flak than it deserves) but I have spent a lot of time working on the performances of Android apps and none of the issues I have fixed would have been any different in another language.

1 comments

I would also used Java if Oracle hadn't dropped the ball in mobile support, as if they couldn't provide JIT and AOT compilers.

So given that I enjoy C++, when conding on my own, that is what I end up using for hobby coding between mobile platforms. But the NDK and JNI wrapping take the fun out of it.

I am curious : on what kind of mobile apps are you working on your free time ?

By design, the NDK can only access a very small part of the platform APIs.

It is not an issue if you are making something where you are supposed to use the NDK (like a drawing app or a game), but for a 'traditional' app, that's another matter.

Very basic games or for the business logic with the UI done in Java and XAML - C++/CX.

But if Clojure did support properly Android and CoreCLR, I would probably use it instead.

As things are, I might go Xamarin in the future.

if you want multiplatform support (or just really like c#/VS), xamarin can be a good choice for an hobby app.

Otherwise, Kotlin borrows many niceties with c# and allows you to directly use the platform APIs.