JTransc + Android/iOS status support
soywiz via Digitalmars-d
digitalmars-d at puremagic.com
Mon Nov 28 17:09:19 PST 2016
On Monday, 28 November 2016 at 17:53:30 UTC, Joakim wrote:
> On Monday, 28 November 2016 at 14:28:54 UTC, soywiz wrote:
>> I am working on a software that allows to transform JVM
>> bytecode into something else. In last version I have done a D
>> target: https://github.com/jtransc/jtransc
>> D target already passes my test suite and works just fine
>> (next version will come with some optimizations regarding to
>> code generation that will improve generation).
>> At this point I'm successfully generating windows/linux and
>> mac native executables from Java/Kotlin code.
>
> Interesting, might provide a better bridge for Java
> compatibility on Android.
>
>> It would be awesome to be able to support Android and iOS. I
>> have seen that there was Android/iOS alpha support in the
>> past. What is the current status of this?
>
> Android support is in beta, latest cross-compiler and native
> builds here:
>
> https://github.com/joakim-noah/android/releases
>
> I've been seeing random crashes for apk builds recently, trying
> to track down why. I've ported the Teapot OpenGL ES 2.0/C++
> sample app from the NDK, but it's got some bugs, debugging that
> next. Once both issues are fixed, I'll announce the beta in a
> new thread.
>
> As for iOS, Dan has been busy with other stuff, may get back to
> it sometime this winter. All mobile builds are linked from the
> main download page, under ldc:
>
> http://dlang.org/download
Thanks you both for the info!
I have seen those links already. I was a bit concerned about the
support, since it is outside the main development. It is planned
to be merged in the main projects? Or those were just
experiments? It would be great to have full support from the
community that seems to be pretty active lately at github so it
doesn't end being outdated.
When considering a new target for jtransc i was searching for a
language like c++ that allowed to generate native executables,
with gc already included, with safety in mind, and full oop
included while allowing to go low level when required. And that
was exactly D. So I can mix both of the two worlds and mix code
as required (performant parts in D, and higher level/productivity
in kotlin).
In the case D targets every major popular platforms (including
mobile) it would be great, since i can generate javascript for
the web already and d for desktop+mobile covering all my current
needs. Instead of having to implement a gc for c++. Also D has
faster compilation times than it which is great.
I will try both projects asap. If it works I will try to port
libgdx to jtransc+d+android/ios.
Even when in Android I can run Java directly. I think there is
still a point for it. Android doesn't support java8 directly and
it can be running either dalvik or art. Also it is easily
decompilable. So a native with unknown optimizations depending on
the versio AOT could make performance much more predictable
among versions, obfuscate it, allow to use stuff like simd, or
support higher java versions.
And for iOS it just supports an AOT approach except for
javascript. So it is great too.
Thank you for the great work on those forks!
More information about the Digitalmars-d
mailing list