digitalmars.D - What is the current state of D for android development?
- js.mdnq (6/6) Mar 27 2013 I would like to get into writing apps for android and would like
- js.mdnq (2/8) Mar 28 2013 I guess that means none... :/
- BLM768 (8/9) Mar 29 2013 Unfortunately, there hasn't been a lot of focus on ARM platforms;
- deadalnix (3/14) Mar 29 2013 Being able to codegen is easy. But the runtime needs to follow,
- Benjamin Thaut (7/18) Mar 29 2013 Some time ago there was a post on the newsgroup of someone that had a
- =?UTF-8?B?QWxpIMOHZWhyZWxp?= (4/23) Mar 29 2013 I haven't tried it myself but there is this information:
- jerro (4/8) Mar 29 2013 Johannes Pfau has a GDC fork with Android support here:
- Johannes Pfau (4/14) Mar 30 2013 But it's probably horribly outdated now ;-)
- Dicebot (9/15) Mar 29 2013 That is one of dark sides of comunity-driven development.
- Paulo Pinto (8/14) Mar 29 2013 Please note that native development in Android has a second class status...
- Nick Sabalausky (26/46) Mar 29 2013 That's actually something that's been rolling around in my head for
- Paulo Pinto (17/63) Mar 29 2013 Personally my issue is another one.
- Nick Sabalausky (15/94) Mar 30 2013 Exactly. It just makes no sense how they see such little point in
- Jacob Carlborg (6/10) Mar 30 2013 That's one thing Apple is good at, having the different parts of the
- Dicebot (7/7) Mar 30 2013 I hate this decision, too, but in case you wander, initial
- Dicebot (1/1) Mar 30 2013 %s/wander/wonder/g
- Paulo Pinto (12/19) Mar 30 2013 You can achieve this by bytecodes that get compiled on the fly at
- Dicebot (3/3) Mar 30 2013 I have always wondered how it is done by Win 8. It requires
- jerro (6/9) Mar 30 2013 Doesn't it only require knowledge of every architecture? And
- Nick Sabalausky (8/26) Mar 30 2013 Which begs the question, "Why haven't they noticed this and stopped
- Paulo Pinto (13/24) Mar 30 2013 They use a format known as MDIL (Machine Dependent Intermediate Language...
- deadalnix (3/10) Mar 31 2013 At infrastructure level, this is also quite scary that everything
- Paulo Pinto (2/10) Mar 31 2013 It is no different than any other commercial vendor.
I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1
Mar 27 2013
On Thursday, 28 March 2013 at 06:13:17 UTC, js.mdnq wrote:I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1I guess that means none... :/
Mar 28 2013
On Friday, 29 March 2013 at 06:35:10 UTC, js.mdnq wrote:I guess that means none... :/Unfortunately, there hasn't been a lot of focus on ARM platforms; people are too busy improving the language and tools to work on standard PC hardware. The DMD compiler definitely won't work for Android development, but I'm pretty sure that GDC can be compiled for ARM output, and I think LDC has that capability as well. You'd probably need to write your own linkscripts, and the runtime would definitely have to be modified.
Mar 29 2013
On Friday, 29 March 2013 at 07:02:24 UTC, BLM768 wrote:On Friday, 29 March 2013 at 06:35:10 UTC, js.mdnq wrote:Being able to codegen is easy. But the runtime needs to follow, and that another issue altogether.I guess that means none... :/Unfortunately, there hasn't been a lot of focus on ARM platforms; people are too busy improving the language and tools to work on standard PC hardware. The DMD compiler definitely won't work for Android development, but I'm pretty sure that GDC can be compiled for ARM output, and I think LDC has that capability as well. You'd probably need to write your own linkscripts, and the runtime would definitely have to be modified.
Mar 29 2013
Am 29.03.2013 07:35, schrieb js.mdnq:On Thursday, 28 March 2013 at 06:13:17 UTC, js.mdnq wrote:Some time ago there was a post on the newsgroup of someone that had a working GDC which would output ARM binaries and he even converted the most important parts of druntime to work for android to. But unfortunately I can't remember where that was. Kind Regards Bejamin ThautI would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1I guess that means none... :/
Mar 29 2013
On 03/29/2013 02:32 AM, Benjamin Thaut wrote:Am 29.03.2013 07:35, schrieb js.mdnq:I haven't tried it myself but there is this information: http://gdcproject.org/wiki/Cross%20Compiler/crosstool-NG AliOn Thursday, 28 March 2013 at 06:13:17 UTC, js.mdnq wrote:Some time ago there was a post on the newsgroup of someone that had a working GDC which would output ARM binaries and he even converted the most important parts of druntime to work for android to. But unfortunately I can't remember where that was. Kind Regards Bejamin ThautI would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1I guess that means none... :/
Mar 29 2013
Some time ago there was a post on the newsgroup of someone that had a working GDC which would output ARM binaries and he even converted the most important parts of druntime to work for android to. But unfortunately I can't remember where that was.Johannes Pfau has a GDC fork with Android support here: https://github.com/jpf91/GDC/tree/android and build scripts that build NDK with D support here: https://github.com/jpf91/gdc-android-scripts
Mar 29 2013
Am Fri, 29 Mar 2013 22:39:52 +0100 schrieb "jerro" <a a.com>:But it's probably horribly outdated now ;-) I'll have to revisit this when shared library support is stable.Some time ago there was a post on the newsgroup of someone that had a working GDC which would output ARM binaries and he even converted the most important parts of druntime to work for android to. But unfortunately I can't remember where that was.Johannes Pfau has a GDC fork with Android support here: https://github.com/jpf91/GDC/tree/android and build scripts that build NDK with D support here: https://github.com/jpf91/gdc-android-scripts
Mar 30 2013
On Thursday, 28 March 2013 at 06:13:17 UTC, js.mdnq wrote:I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1That is one of dark sides of comunity-driven development. Techincally, it is possible: at least GDC can do ARM code gen, there is nothing inherently blocking the port in language design. What is required is that someone will actually take his time to port druntime and test everything. And that supposes some substantial time investments from someone both familiar with druntime and interested in Android dev. Looks like no such person exist so far.
Mar 29 2013
On 28.03.2013 07:13, js.mdnq wrote:I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1Please note that native development in Android has a second class status. Support is only available as a means to bring "legacy" C and C++ code to the platform. The few Android APIs available to languages outside the Dalvik world are actually wrappers around JNI calls. -- Paulo
Mar 29 2013
On Fri, 29 Mar 2013 18:45:33 +0100 Paulo Pinto <pjmlp progtools.org> wrote:On 28.03.2013 07:13, js.mdnq wrote:That's actually something that's been rolling around in my head for months, and now that it's brought up again, I have to just go ahead and say it: What...the *FUCK* is Google thinking??? How is it *possible* that the one company in the word that's been known, more than any other, for recruiting as many of the supposedly best and brightest developers in the world as they possibly can, portrayed by approximately...everyone in the world...as being practically a developer's utopia, with nary a pointy-hair in sight, and the streets paved with latte, can be so incredibly dumb as to decide "Hey, let's make our system API be *JVM-only* (ok, "JVM-knockoff", whatever, like it even matters) and marginalize native in general, and shit all over the idea of being anything more than halfway Posix"?? Even *Apple* isn't that goddamn stupid, for crap's sakes, and *Apple* was never a developer's company, it was run by a dicatoring *salesman*! A drugged-out fucking *salesman* for fuck's sakes, and even *they* didn't botch things up *that* badly! Not only that, but this is the same - apparently schizophrenic - company that's been trying to push the *Google* **NATIVE** **CLIENT**, ie NaCl!! [Just insert a mental image right here of Lewis Black's trademark freak-out saying "What...the...FUUUCK?!?'] Sheesh. Sorry, had to get it outta my system...I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1Please note that native development in Android has a second class status. Support is only available as a means to bring "legacy" C and C++ code to the platform. The few Android APIs available to languages outside the Dalvik world are actually wrappers around JNI calls.
Mar 29 2013
On 30.03.2013 05:58, Nick Sabalausky wrote:On Fri, 29 Mar 2013 18:45:33 +0100 Paulo Pinto <pjmlp progtools.org> wrote:Personally my issue is another one. I don't mind that they use Java (the language), but I think that instead of having the effort of implementing Dalvik, they could have implemented a native code compiler instead. This way the platform would be fully native. This is Microsoft current approach, regardless of C++ or .NET, since Windows Phone 8, everything is compiled to native code. As for POSIX compatibility, it is oversold. You only have APIs for command line applications and daemons, and like any standard, it has undefined behaviors, with each vendor having a different idea what POSIX means. Nowadays they could even support Go in the platform, but the Android group does not seem to care that much (issue was created by me). http://code.google.com/p/android/issues/detail?id=39482 -- PauloOn 28.03.2013 07:13, js.mdnq wrote:That's actually something that's been rolling around in my head for months, and now that it's brought up again, I have to just go ahead and say it: What...the *FUCK* is Google thinking??? How is it *possible* that the one company in the word that's been known, more than any other, for recruiting as many of the supposedly best and brightest developers in the world as they possibly can, portrayed by approximately...everyone in the world...as being practically a developer's utopia, with nary a pointy-hair in sight, and the streets paved with latte, can be so incredibly dumb as to decide "Hey, let's make our system API be *JVM-only* (ok, "JVM-knockoff", whatever, like it even matters) and marginalize native in general, and shit all over the idea of being anything more than halfway Posix"?? Even *Apple* isn't that goddamn stupid, for crap's sakes, and *Apple* was never a developer's company, it was run by a dicatoring *salesman*! A drugged-out fucking *salesman* for fuck's sakes, and even *they* didn't botch things up *that* badly! Not only that, but this is the same - apparently schizophrenic - company that's been trying to push the *Google* **NATIVE** **CLIENT**, ie NaCl!! [Just insert a mental image right here of Lewis Black's trademark freak-out saying "What...the...FUUUCK?!?'] Sheesh. Sorry, had to get it outta my system...I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1Please note that native development in Android has a second class status. Support is only available as a means to bring "legacy" C and C++ code to the platform. The few Android APIs available to languages outside the Dalvik world are actually wrappers around JNI calls.
Mar 29 2013
On Sat, 30 Mar 2013 07:47:56 +0100 Paulo Pinto <pjmlp progtools.org> wrote:On 30.03.2013 05:58, Nick Sabalausky wrote:Exactly. It just makes no sense how they see such little point in native. They've created a *real* machine that exists almost entirely to run a *virtual* machine. WTF is the point of that, if not to deliberately waste both hardware and developer resources? And on a portable, too - one of the top places where efficiency is particularly important.On Fri, 29 Mar 2013 18:45:33 +0100 Paulo Pinto <pjmlp progtools.org> wrote:Personally my issue is another one. I don't mind that they use Java (the language), but I think that instead of having the effort of implementing Dalvik, they could have implemented a native code compiler instead. This way the platform would be fully native. This is Microsoft current approach, regardless of C++ or .NET, since Windows Phone 8, everything is compiled to native code.On 28.03.2013 07:13, js.mdnq wrote:That's actually something that's been rolling around in my head for months, and now that it's brought up again, I have to just go ahead and say it: What...the *FUCK* is Google thinking??? How is it *possible* that the one company in the word that's been known, more than any other, for recruiting as many of the supposedly best and brightest developers in the world as they possibly can, portrayed by approximately...everyone in the world...as being practically a developer's utopia, with nary a pointy-hair in sight, and the streets paved with latte, can be so incredibly dumb as to decide "Hey, let's make our system API be *JVM-only* (ok, "JVM-knockoff", whatever, like it even matters) and marginalize native in general, and shit all over the idea of being anything more than halfway Posix"?? Even *Apple* isn't that goddamn stupid, for crap's sakes, and *Apple* was never a developer's company, it was run by a dicatoring *salesman*! A drugged-out fucking *salesman* for fuck's sakes, and even *they* didn't botch things up *that* badly! Not only that, but this is the same - apparently schizophrenic - company that's been trying to push the *Google* **NATIVE** **CLIENT**, ie NaCl!! [Just insert a mental image right here of Lewis Black's trademark freak-out saying "What...the...FUUUCK?!?'] Sheesh. Sorry, had to get it outta my system...I would like to get into writing apps for android and would like to choose D for this if it is mature enough. What is the D progress on the android? I see that at least others are interested but not finding a ton of information: http://forum.dlang.org/thread/20120204203109.26c9a80b jpf-laptop?page=1Please note that native development in Android has a second class status. Support is only available as a means to bring "legacy" C and C++ code to the platform. The few Android APIs available to languages outside the Dalvik world are actually wrappers around JNI calls.As for POSIX compatibility, it is oversold. You only have APIs for command line applications and daemons, and like any standard, it has undefined behaviors, with each vendor having a different idea what POSIX means. Nowadays they could even support Go in the platform, but the Android group does not seem to care that much (issue was created by me). http://code.google.com/p/android/issues/detail?id=39482I find this part particularly hilarious: "the Go compilers only generate static executables right now. Which means: ... - These programs *cannot* run in a Dalvik VM." You've got the Go team which has historically been staunchly opposed to dynamic linking, and the Android team ten miles in the opposite direction. Classic corporate "left-hand vs right-hand" discrepancy. Makes them sound like Sony or MS.
Mar 30 2013
On 2013-03-30 08:26, Nick Sabalausky wrote:You've got the Go team which has historically been staunchly opposed to dynamic linking, and the Android team ten miles in the opposite direction. Classic corporate "left-hand vs right-hand" discrepancy. Makes them sound like Sony or MS.That's one thing Apple is good at, having the different parts of the company work together. They don't care if a particular device sells less because of another device, as long as they sell more combined. -- /Jacob Carlborg
Mar 30 2013
I hate this decision, too, but in case you wander, initial rationale for restricting everything to VM was an attempt to fight device h/w fragmentization and avoid necessity to build different application versions for different devices. Failed attempt, obviously. Apple have never needed that though as they 100% control device hardware their OS runs on.
Mar 30 2013
On 30.03.2013 10:43, Dicebot wrote:I hate this decision, too, but in case you wander, initial rationale for restricting everything to VM was an attempt to fight device h/w fragmentization and avoid necessity to build different application versions for different devices. Failed attempt, obviously. Apple have never needed that though as they 100% control device hardware their OS runs on.You can achieve this by bytecodes that get compiled on the fly at installation time. This is how Windows Phone 8 works, by using an offline compiler on Windows Store to compile .NET to native code, thus you only install native code, there is no JIT on the devices. Or how Windows CE used platform neutral binaries, known as Common Executable Format (CEF). Nowadays I think the best way is a mixture of JIT + AOT, similar to what functional programming languages offer. -- Paulo
Mar 30 2013
I have always wondered how it is done by Win 8. It requires knowledge of every single released device from Microsoft side, isn't it? How will it scale?
Mar 30 2013
On Saturday, 30 March 2013 at 09:55:27 UTC, Dicebot wrote:I have always wondered how it is done by Win 8. It requires knowledge of every single released device from Microsoft side, isn't it? How will it scale?Doesn't it only require knowledge of every architecture? And supporting ARM and x86 would cover a great majority of devices. They could improve performance by targeting specific versions of the architecture, such as ARMv7 or x86_64, but even without that, performance would likely be better than that of a JIT.
Mar 30 2013
On Sat, 30 Mar 2013 10:53:31 +0100 Paulo Pinto <pjmlp progtools.org> wrote:On 30.03.2013 10:43, Dicebot wrote:Which begs the question, "Why haven't they noticed this and stopped treating native as second-class?"I hate this decision, too, but in case you wander, initial rationale for restricting everything to VM was an attempt to fight device h/w fragmentization and avoid necessity to build different application versions for different devices. Failed attempt, obviously.Unless the bytecode is both comparable to LLVM and has an escape hatch to include real pre-compiled binary data, then that still bugs me. STill a huge improvement over Android, though. Well, except that the user has to use Win8 ;)Apple have never needed that though as they 100% control device hardware their OS runs on.You can achieve this by bytecodes that get compiled on the fly at installation time. This is how Windows Phone 8 works, by using an offline compiler on Windows Store to compile .NET to native code, thus you only install native code, there is no JIT on the devices.
Mar 30 2013
On 30.03.2013 16:46, Nick Sabalausky wrote:On Sat, 30 Mar 2013 10:53:31 +0100 Paulo Pinto <pjmlp progtools.org> wrote:They use a format known as MDIL (Machine Dependent Intermediate Language). Basically everything is compiled down to machine code, except for memory references and labels. Linking is performed at installation time on the device. This allows the code to be made available in native format, while keeping the flexibility of dynamic libraries to be in sync with operating system updates. More information here, http://channel9.msdn.com/Shows/Going+Deep/Mani-Ramaswamy-and-Peter-Sollich-Inside-Compiler-in-the-Cloud-and-MDIL http://channel9.msdn.com/Events/Build/2012/3-005 -- PauloThis is how Windows Phone 8 works, by using an offline compiler on Windows Store to compile .NET to native code, thus you only install native code, there is no JIT on the devices.Unless the bytecode is both comparable to LLVM and has an escape hatch to include real pre-compiled binary data, then that still bugs me. STill a huge improvement over Android, though. Well, except that the user has to use Win8 ;)
Mar 30 2013
On Saturday, 30 March 2013 at 15:46:58 UTC, Nick Sabalausky wrote:Unless the bytecode is both comparable to LLVM and has an escape hatch to include real pre-compiled binary data, then that still bugs me. STill a huge improvement over Android, though. Well, except that the user has to use Win8 ;)At infrastructure level, this is also quite scary that everything is done in MS server farm.
Mar 31 2013
On 31.03.2013 14:29, deadalnix wrote:On Saturday, 30 March 2013 at 15:46:58 UTC, Nick Sabalausky wrote:It is no different than any other commercial vendor.Unless the bytecode is both comparable to LLVM and has an escape hatch to include real pre-compiled binary data, then that still bugs me. STill a huge improvement over Android, though. Well, except that the user has to use Win8 ;)At infrastructure level, this is also quite scary that everything is done in MS server farm.
Mar 31 2013