www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - State of D on iOS/Android?

reply "Nick Sabalausky" <a a.a> writes:
What's the current state of D on iOS and Android? I know someone has been 
working on connecting D up to Objective-C somehow, and either GDC or LDC has 
at least partial support for Arm (but with some caveats, right?).

Has anyone actually made anything in D on iOS and/or Android? It is feasable 
yet? (On just one, or on both?) If not, what's needed?
Jan 28 2012
next sibling parent Paulo Pinto <pjmlp progtools.org> writes:
Am 28.01.2012 11:08, schrieb Nick Sabalausky:
 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is feasable
 yet? (On just one, or on both?) If not, what's needed?
Be able to generate ARM code? I remeber seeing some post about hacking the NDK toolchain to support GDC, but not sure how good it is.
Jan 28 2012
prev sibling next sibling parent reply Chad J <chadjoan __spam.is.bad__gmail.com> writes:
On 01/28/2012 05:08 AM, Nick Sabalausky wrote:
 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is feasable
 yet? (On just one, or on both?) If not, what's needed?
The state of D on Android ... http://interaxiom.blogspot.com/2011/08/android-d-stuff.html ... seems to be unmaintained? I want this. And if there's any way D android apps could run without rooting the phone, then I /really/ want this.
Jan 28 2012
next sibling parent reply Manu <turkeyman gmail.com> writes:
On 28 January 2012 14:58, Chad J <chadjoan __spam.is.bad__gmail.com> wrote:

 On 01/28/2012 05:08 AM, Nick Sabalausky wrote:

 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC
 has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is
 feasable
 yet? (On just one, or on both?) If not, what's needed?
The state of D on Android ... http://interaxiom.blogspot.**com/2011/08/android-d-stuff.**html<http://interaxiom.blogspot.com/2011/08/android-d-stuff.html> ... seems to be unmaintained? I want this. And if there's any way D android apps could run without rooting the phone, then I /really/ want this.
I've been thinking there really should be a nice central repository for information relating to D cross compilers, associated patches and build process/scripts... Perhaps an official section on d-p-l? I'd *really* love to see simple buildscripts for linux users, and pre-built mingw toolchains for Windows. This would really stimulate cross platform usage of D I think; relaxing the requirement that an interested user understands, and is capable of building the toolchain themselves. Particularly Android; I think D could make a strong and immediate splash for Android devs looking to avoid the Java front end/UI system.
Jan 28 2012
next sibling parent "Nick Sabalausky" <a a.a> writes:
"Manu" <turkeyman gmail.com> wrote in message 
news:mailman.100.1327756764.25230.digitalmars-d puremagic.com...
 I've been thinking there really should be a nice central repository for
 information relating to D cross compilers, associated patches and build
 process/scripts...
 Perhaps an official section on d-p-l? I'd *really* love to see simple
 buildscripts for linux users, and pre-built mingw toolchains for Windows.
 This would really stimulate cross platform usage of D I think; relaxing 
 the
 requirement that an interested user understands, and is capable of 
 building
 the toolchain themselves.
That would be nice. Writing non-desktop/web software should be considered extremely important for any systems langauge. (Desktop and web developers already have five billion languages to choose from.)
Jan 28 2012
prev sibling parent "F i L" <witte2008 gmail.com> writes:
Manu wrote:
 I've been thinking there really should be a nice central 
 repository for
 information relating to D cross compilers, associated patches 
 and build
 process/scripts...
 Perhaps an official section on d-p-l? I'd *really* love to see 
 simple
 buildscripts for linux users, and pre-built mingw toolchains 
 for Windows.
 This would really stimulate cross platform usage of D I think; 
 relaxing the
 requirement that an interested user understands, and is capable 
 of building
 the toolchain themselves.
 Particularly Android; I think D could make a strong and 
 immediate splash
 for Android devs looking to avoid the Java front end/UI system.
+1 to this. Can't agree more.
Jan 28 2012
prev sibling next sibling parent reply Manu <turkeyman gmail.com> writes:
On 28 January 2012 14:58, Chad J <chadjoan __spam.is.bad__gmail.com> wrote:

 On 01/28/2012 05:08 AM, Nick Sabalausky wrote:

 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC
 has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is
 feasable
 yet? (On just one, or on both?) If not, what's needed?
The state of D on Android ... http://interaxiom.blogspot.**com/2011/08/android-d-stuff.**html<http://interaxiom.blogspot.com/2011/08/android-d-stuff.html> ... seems to be unmaintained? I want this. And if there's any way D android apps could run without rooting the phone, then I /really/ want this.
Since Android 2.3 it has been possible to run fully native apps, and a GDC for android will work just as well as any C compiler, although some work will have to be done to produce bindings for the NDK libraries. What I'm most excited about is being able to use D to wrap the NDK libraries to create an android experience that's very similar to the Android Java API's, but with native code throughout.
Jan 28 2012
parent reply Jacob Carlborg <doob me.com> writes:
On 2012-01-28 14:34, Manu wrote:
 On 28 January 2012 14:58, Chad J <chadjoan __spam.is.bad__gmail.com
 <http://spam.is.bad__gmail.com>> wrote:

     On 01/28/2012 05:08 AM, Nick Sabalausky wrote:

         What's the current state of D on iOS and Android? I know someone
         has been
         working on connecting D up to Objective-C somehow, and either
         GDC or LDC has
         at least partial support for Arm (but with some caveats, right?).

         Has anyone actually made anything in D on iOS and/or Android? It
         is feasable
         yet? (On just one, or on both?) If not, what's needed?



     The state of D on Android ...
     http://interaxiom.blogspot.__com/2011/08/android-d-stuff.__html
     <http://interaxiom.blogspot.com/2011/08/android-d-stuff.html>
     ... seems to be unmaintained?

     I want this.  And if there's any way D android apps could run
     without rooting the phone, then I /really/ want this.


 Since Android 2.3 it has been possible to run fully native apps, and a
 GDC for android will work just as well as any C compiler, although some
 work will have to be done to produce bindings for the NDK libraries.
 What I'm most excited about is being able to use D to wrap the NDK
 libraries to create an android experience that's very similar to the
 Android Java API's, but with native code throughout.
The ARM support needs to be added to the runtime. -- /Jacob Carlborg
Jan 28 2012
next sibling parent Manu <turkeyman gmail.com> writes:
On 28 January 2012 17:15, Jacob Carlborg <doob me.com> wrote:

 On 2012-01-28 14:34, Manu wrote:

 On 28 January 2012 14:58, Chad J
<chadjoan __spam.is.bad__**gmail.com<http://spam.is.bad__gmail.com>
 <http://spam.is.bad__gmail.com**>> wrote:

    On 01/28/2012 05:08 AM, Nick Sabalausky wrote:

        What's the current state of D on iOS and Android? I know someone
        has been
        working on connecting D up to Objective-C somehow, and either
        GDC or LDC has
        at least partial support for Arm (but with some caveats, right?).

        Has anyone actually made anything in D on iOS and/or Android? It
        is feasable
        yet? (On just one, or on both?) If not, what's needed?



    The state of D on Android ...
    http://interaxiom.blogspot.__**com/2011/08/android-d-stuff.__**html

    <http://interaxiom.blogspot.**com/2011/08/android-d-stuff.**html<http://interaxiom.blogspot.com/2011/08/android-d-stuff.html>

    ... seems to be unmaintained?

    I want this.  And if there's any way D android apps could run
    without rooting the phone, then I /really/ want this.


 Since Android 2.3 it has been possible to run fully native apps, and a
 GDC for android will work just as well as any C compiler, although some
 work will have to be done to produce bindings for the NDK libraries.
 What I'm most excited about is being able to use D to wrap the NDK
 libraries to create an android experience that's very similar to the
 Android Java API's, but with native code throughout.
The ARM support needs to be added to the runtime.
Sure. I'd gladly do that myself the instant I had a toolchain.
Jan 28 2012
prev sibling parent =?UTF-8?B?QWxleCBSw7hubmUgUGV0ZXJzZW4=?= <xtzgzorex gmail.com> writes:
On 28-01-2012 16:15, Jacob Carlborg wrote:
 On 2012-01-28 14:34, Manu wrote:
 On 28 January 2012 14:58, Chad J <chadjoan __spam.is.bad__gmail.com
 <http://spam.is.bad__gmail.com>> wrote:

 On 01/28/2012 05:08 AM, Nick Sabalausky wrote:

 What's the current state of D on iOS and Android? I know someone
 has been
 working on connecting D up to Objective-C somehow, and either
 GDC or LDC has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It
 is feasable
 yet? (On just one, or on both?) If not, what's needed?



 The state of D on Android ...
 http://interaxiom.blogspot.__com/2011/08/android-d-stuff.__html
 <http://interaxiom.blogspot.com/2011/08/android-d-stuff.html>
 ... seems to be unmaintained?

 I want this. And if there's any way D android apps could run
 without rooting the phone, then I /really/ want this.


 Since Android 2.3 it has been possible to run fully native apps, and a
 GDC for android will work just as well as any C compiler, although some
 work will have to be done to produce bindings for the NDK libraries.
 What I'm most excited about is being able to use D to wrap the NDK
 libraries to create an android experience that's very similar to the
 Android Java API's, but with native code throughout.
The ARM support needs to be added to the runtime.
It's more or less done in GDC. - Alex
Jan 28 2012
prev sibling next sibling parent "H. S. Teoh" <hsteoh quickfur.ath.cx> writes:
On Sat, Jan 28, 2012 at 03:34:22PM +0200, Manu wrote:
[...]
 Since Android 2.3 it has been possible to run fully native apps, and a
 GDC for android will work just as well as any C compiler, although
 some work will have to be done to produce bindings for the NDK
 libraries.  What I'm most excited about is being able to use D to wrap
 the NDK libraries to create an android experience that's very similar
 to the Android Java API's, but with native code throughout.
+1 to this. I've been looking forward to getting an Android (either phone or tablet) and writing apps for it. If I can write apps in D, that would simply be awesome. (And you never know, maybe it will be an Android killer app that will make D really take off... ;-)) As far as I know, gdc can already produce ARM code since it uses the gcc backend. All we need now is a nice native D interface to the Android libraries, and I'll be a very very happy man. T -- The early bird gets the worm. Moral: ewww...
Jan 28 2012
prev sibling next sibling parent Manu <turkeyman gmail.com> writes:
On 28 January 2012 18:19, H. S. Teoh <hsteoh quickfur.ath.cx> wrote:

 On Sat, Jan 28, 2012 at 03:34:22PM +0200, Manu wrote:
 [...]
 Since Android 2.3 it has been possible to run fully native apps, and a
 GDC for android will work just as well as any C compiler, although
 some work will have to be done to produce bindings for the NDK
 libraries.  What I'm most excited about is being able to use D to wrap
 the NDK libraries to create an android experience that's very similar
 to the Android Java API's, but with native code throughout.
+1 to this. I've been looking forward to getting an Android (either phone or tablet) and writing apps for it. If I can write apps in D, that would simply be awesome. (And you never know, maybe it will be an Android killer app that will make D really take off... ;-)) As far as I know, gdc can already produce ARM code since it uses the gcc backend. All we need now is a nice native D interface to the Android libraries, and I'll be a very very happy man.
Libraries are the easy part. If you can make a build-script that 'just works' for the average man, and perhaps also mingw binaries for the Win users, I think progress in this area will explode almost instantly.
Jan 28 2012
prev sibling next sibling parent "H. S. Teoh" <hsteoh quickfur.ath.cx> writes:
On Sat, Jan 28, 2012 at 06:42:14PM +0200, Manu wrote:
 On 28 January 2012 18:19, H. S. Teoh <hsteoh quickfur.ath.cx> wrote:
[...]
 As far as I know, gdc can already produce ARM code since it uses the
 gcc backend. All we need now is a nice native D interface to the
 Android libraries, and I'll be a very very happy man.
Libraries are the easy part. If you can make a build-script that 'just works' for the average man, and perhaps also mingw binaries for the Win users, I think progress in this area will explode almost instantly.
OK, what do you mean by "just works"? What is needed to in the script? I'll admit I haven't really looked too closely at the Android docs yet, but shouldn't it just be a matter of compiling your D sources with gdc as usual, and then link it with a particular set of libraries? Well, OK, so you do need to setup an ARM cross-compiler, so you'll need either to build gdc/gcc yourself (ugh) or have someone provide the binaries. What else? T -- Тише едешь, дальше будешь.
Jan 28 2012
prev sibling parent Manu <turkeyman gmail.com> writes:
On 28 January 2012 19:03, H. S. Teoh <hsteoh quickfur.ath.cx> wrote:

 On Sat, Jan 28, 2012 at 06:42:14PM +0200, Manu wrote:
 On 28 January 2012 18:19, H. S. Teoh <hsteoh quickfur.ath.cx> wrote:
[...]
 As far as I know, gdc can already produce ARM code since it uses the
 gcc backend. All we need now is a nice native D interface to the
 Android libraries, and I'll be a very very happy man.
Libraries are the easy part. If you can make a build-script that 'just works' for the average man, and perhaps also mingw binaries for the Win users, I think progress in this area will explode almost instantly.
OK, what do you mean by "just works"? What is needed to in the script? I'll admit I haven't really looked too closely at the Android docs yet, but shouldn't it just be a matter of compiling your D sources with gdc as usual, and then link it with a particular set of libraries?
Just build with GDC as usual, and link with the Android NDK libs (we'll obviously need D bindings). They're distributes as binaries with each revision of the Android NDK.
 Well, OK, so you do need to setup an ARM cross-compiler, so you'll need
 either to build gdc/gcc yourself (ugh) or have someone provide the
 binaries. What else?
That's enough. A script to fully automate building the Android toolchain, and ideally, a set of mingw binaries put on the web somewhere. Google have instructions to build the toolchain on the Android developer website, they provide a nice set of scripts to do it on linux... It should just be a matter of patching GDC support into their script and letting it do its thing. The rest can be left to the community, ie. druntime, making bindings for the NDK libraries (binaries are provided in the NDK distro). I'm sure that'll take care of its self within short time.
Jan 28 2012
prev sibling next sibling parent reply Michel Fortin <michel.fortin michelf.com> writes:
On 2012-01-28 10:08:36 +0000, "Nick Sabalausky" <a a.a> said:

 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC has
 at least partial support for Arm (but with some caveats, right?).
 
 Has anyone actually made anything in D on iOS and/or Android? It is feasable
 yet? (On just one, or on both?) If not, what's needed?
You're thinking about D/Objective-C I think. <http://michelf.com/projects/d-objc/> But DMD has no ARM support, and currently my additions only generate binaries working for the legacy Objective-C runtime -- because DMD was 32-bit at the time and 32-bit Mac OS X uses the legacy runtime -- so you have four problems still to solve: - iOS uses the modern Objective-C runtime, which is not supported by my work. - D/Objective-C is starting to get old, and somewhat out of sync from the main DMD tree. - DMD generates only code for x86, you'd need to port my changes to GDC which is not trivial since many things are done in the glue layer. But then perhaps GCC already has all the necessary code to build Objective-C object files. - Bindings, you'll need to generate them somehow. I don't have much time for this right now, but if you want to continue my work I can give you some more directions. -- Michel Fortin michel.fortin michelf.com http://michelf.com/
Jan 28 2012
parent reply Manu <turkeyman gmail.com> writes:
On 28 January 2012 16:35, Michel Fortin <michel.fortin michelf.com> wrote:

 On 2012-01-28 10:08:36 +0000, "Nick Sabalausky" <a a.a> said:

  What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC
 has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is
 feasable
 yet? (On just one, or on both?) If not, what's needed?
You're thinking about D/Objective-C I think. <http://michelf.com/projects/**d-objc/<http://michelf.com/projects/d-objc/>

 But DMD has no ARM support, and currently my additions only generate
 binaries working for the legacy Objective-C runtime -- because DMD was
 32-bit at the time and 32-bit Mac OS X uses the legacy runtime -- so you
 have four problems still to solve:

 - iOS uses the modern Objective-C runtime, which is not supported by my
 work.
 - D/Objective-C is starting to get old, and somewhat out of sync from the
 main DMD tree.
 - DMD generates only code for x86, you'd need to port my changes to GDC
 which is not trivial since many things are done in the glue layer. But then
 perhaps GCC already has all the necessary code to build Objective-C object
 files.
 - Bindings, you'll need to generate them somehow.

 I don't have much time for this right now, but if you want to continue my
 work I can give you some more directions.
There's one problem with using D to write iOS software though, Apple strictly require that any apps submitted MUST use their XCode toolchain. I think D is much more interested for Android at this stage, since it's open, has a good native layer/libs, and is a VERY compelling language to replace the Java layer in most Android apps.
Jan 28 2012
parent Michel Fortin <michel.fortin michelf.com> writes:
On 2012-01-28 14:45:15 +0000, Manu <turkeyman gmail.com> said:

 There's one problem with using D to write iOS software though, Apple
 strictly require that any apps submitted MUST use their XCode toolchain.
They've refrained from that a while ago. <http://www.apple.com/pr/library/2010/09/09Statement-by-Apple-on-App-Store-Review-Guidelines.html> -- Michel Fortin michel.fortin michelf.com http://michelf.com/
Jan 28 2012
prev sibling parent Jacob Carlborg <doob me.com> writes:
On 2012-01-28 11:08, Nick Sabalausky wrote:
 What's the current state of D on iOS and Android? I know someone has been
 working on connecting D up to Objective-C somehow, and either GDC or LDC has
 at least partial support for Arm (but with some caveats, right?).

 Has anyone actually made anything in D on iOS and/or Android? It is feasable
 yet? (On just one, or on both?) If not, what's needed?
This would be one of the projects for connecting D with Objective-C: http://michelf.com/projects/d-objc/ -- /Jacob Carlborg
Jan 28 2012