Re: How to use D for cross platform development?

2012-03-30 Thread Jacob Carlborg
On 2012-03-29 21:03, Bennie Copeland wrote: Thanks for your help. My primary use case is to provide a native look and feel GUI on the Mac. So, to the extent of creating the interface using Cocoa and tying it back to the core code written in D. In that case you would, hopefully, only need a

Re: How to use D for cross platform development?

2012-03-30 Thread Jacob Carlborg
On 2012-03-29 21:45, Gour wrote: On Thu, 29 Mar 2012 21:03:05 +0200 Bennie Copelandmugen.kano...@gmail.com wrote: Thanks for your help. My primary use case is to provide a native look and feel GUI on the Mac. So, to the extent of creating the interface using Cocoa and tying it back to the

Re: How to use D for cross platform development?

2012-03-30 Thread Chris W.
That's all great stuff. Thanks guys. I think in this respect D could really take off, i.e. as the natively compiled, portable core language that can easily interface to platform specific frameworks through C and C++. This, among other things, got me interested in D in the first place. I think

Re: How to use D for cross platform development?

2012-03-30 Thread Michel Fortin
On 2012-03-29 16:36:55 +, Jacob Carlborg d...@me.com said: Both I and Michel have created an Objective-C/D bridge that uses this approach. It lets you call Objective-C methods, create instances of Objective-C classes, create subclasses in D that inherit from Objective-C classes and so on.

Re: How to use D for cross platform development?

2012-03-30 Thread Jacob Carlborg
On 2012-03-30 13:09, Michel Fortin wrote: Indeed. And the approach makes much more sense. Only I don't really have time for compiler hacking these days. I still hope I'll be able to continue it later this year. I don't know if you have seen this, but I took the liberty to add your project as

Re: How to use D for cross platform development?

2012-03-30 Thread Michel Fortin
On 2012-03-30 12:34:50 +, Jacob Carlborg d...@me.com said: On 2012-03-30 13:09, Michel Fortin wrote: Indeed. And the approach makes much more sense. Only I don't really have time for compiler hacking these days. I still hope I'll be able to continue it later this year. I don't know if

Re: How to use D for cross platform development?

2012-03-29 Thread Chris W.
On Wednesday, 28 March 2012 at 15:31:26 UTC, Bennie Copeland wrote: Great to hear someone with experience with it. Was there any issues with the code that had to be tweaked depending on the OS? When I was looking at C++, there was implementation defined data type sizes, endieness,

Re: How to use D for cross platform development?

2012-03-29 Thread Jacob Carlborg
On 2012-03-29 11:12, Chris W. wrote: I cannot give you any advice as regards C++, because I have never really used it - avoiding it like the plague. My strategy is to keep things as simple as possible and use C only as the glue. It's a bit like the Lua approach which only uses ANSI C to ensure

Re: How to use D for cross platform development?

2012-03-29 Thread Chris W.
On Thursday, 29 March 2012 at 12:10:17 UTC, Jacob Carlborg wrote: I have some with using Objective-C together with D. It's a lot more verbose and quite more complicated than using a C library with D. How complicated it is depends on what one want to do with the Objective-C library. Obviously

Re: How to use D for cross platform development?

2012-03-29 Thread Jacob Carlborg
On 2012-03-29 14:44, Chris W. wrote: Thanks for the link. Objective-C is basically C and can be implemented in C style as far as I know. Is it worth going down to the C level like so: Yes that would be possible. struct NSObject { struct objc_class* isa; } struct objc_class { Class isa;

Re: How to use D for cross platform development?

2012-03-29 Thread Bennie Copeland
On Thursday, 29 March 2012 at 16:36:57 UTC, Jacob Carlborg wrote: On 2012-03-29 14:44, Chris W. wrote: Thanks for the link. Objective-C is basically C and can be implemented in C style as far as I know. Is it worth going down to the C level like so: Yes that would be possible. struct

Re: How to use D for cross platform development?

2012-03-29 Thread Gour
On Thu, 29 Mar 2012 21:03:05 +0200 Bennie Copeland mugen.kano...@gmail.com wrote: Thanks for your help. My primary use case is to provide a native look and feel GUI on the Mac. So, to the extent of creating the interface using Cocoa and tying it back to the core code written in D. Have

Re: How to use D for cross platform development?

2012-03-28 Thread Bennie Copeland
On Sunday, 25 March 2012 at 16:20:51 UTC, Alex Rønne Petersen wrote: About ARM support: That's not strictly true. D on ARM should work fine at this point in time if you build druntime/phobos in GDC with -fno-section-anchors (there is even some experimental Android support). But indeed, no

Re: How to use D for cross platform development?

2012-03-28 Thread Bennie Copeland
On Monday, 26 March 2012 at 10:46:39 UTC, Chris W. wrote: I am using D for cross platform development. I recently implemented C wrappers for D. It works fine (Mac OS X). I could also create a Python module that consists of both D and C code (the C code is really just the wrapper for the

Re: How to use D for cross platform development?

2012-03-28 Thread Iain Buclaw
On 28 March 2012 16:31, Bennie Copeland mugen.kano...@gmail.com wrote: On Monday, 26 March 2012 at 10:46:39 UTC, Chris W. wrote: I am using D for cross platform development. I recently implemented C wrappers for D. It works fine (Mac OS X). I could also create a Python module that consists of

Re: How to use D for cross platform development?

2012-03-28 Thread Jacob Carlborg
On 2012-03-28 17:23, Bennie Copeland wrote: I'm still new at low level programming topics like ABI's etc, so I'll betray my ignorance. Is the druntime only required for providing an interface between the executable and OS resources like IO, or is it inseparable from the language? For example,

Re: How to use D for cross platform development?

2012-03-28 Thread Nick Sabalausky
Bennie Copeland mugen.kano...@gmail.com wrote in message news:mizfgcnxjpbfbclcs...@forum.dlang.org... On Sunday, 25 March 2012 at 16:20:51 UTC, Alex Rønne Petersen wrote: About ARM support: That's not strictly true. D on ARM should work fine at this point in time if you build druntime/phobos

Re: How to use D for cross platform development?

2012-03-28 Thread Nick Sabalausky
Iain Buclaw ibuc...@ubuntu.com wrote in message news:mailman.1198.1332955673.4860.digitalmar...@puremagic.com... On 28 March 2012 16:31, Bennie Copeland mugen.kano...@gmail.com wrote: On Monday, 26 March 2012 at 10:46:39 UTC, Chris W. wrote: I am using D for cross platform development. I

Re: How to use D for cross platform development?

2012-03-28 Thread H. S. Teoh
On Wed, Mar 28, 2012 at 03:13:01PM -0400, Nick Sabalausky wrote: [...] Some basic things are tied into druntme/phobos. The GC is definitely one of them. AIUI, Arrays and AAs have been moving to a druntime-based implementation, and the Object class is implemented there. Technically, you can

Re: How to use D for cross platform development?

2012-03-28 Thread Nick Sabalausky
H. S. Teoh hst...@quickfur.ath.cx wrote in message news:mailman.1199.1332962802.4860.digitalmar...@puremagic.com... ( [...] ( [...] ( [...] (Gah, I'm starting to Lisp, better stop now! lol :)

Re: How to use D for cross platform development?

2012-03-26 Thread Chris W.
I am using D for cross platform development. I recently implemented C wrappers for D. It works fine (Mac OS X). I could also create a Python module that consists of both D and C code (the C code is really just the wrapper for the module's functionality that is completely in D). It also works

How to use D for cross platform development?

2012-03-25 Thread Bennie Copeland
Hello all. I'm sorry if this has been addressed before. For a little background. I've been studying C++ with the intention of doing cross platform work on Windows, OSX, and eventually iOS and some other mobile OSes. My plan was to write cross platform shared libraries for the core

Re: How to use D for cross platform development?

2012-03-25 Thread maarten van damme
Op 25 maart 2012 13:12 schreef Bennie Copeland mugen.kano...@gmail.comhet volgende: For linking against C, I can create a DLL in windows, but I can't create an .so in linux, and no information at all about OSX. From what I've heard this was a certain bug (

Re: How to use D for cross platform development?

2012-03-25 Thread Iain Buclaw
On 25 March 2012 13:22, maarten van damme maartenvd1...@gmail.com wrote: Op 25 maart 2012 13:12 schreef Bennie Copeland mugen.kano...@gmail.com het volgende: For linking against C, I can create a DLL in windows, but I can't create an .so in linux, and no information at all about OSX. From

Re: How to use D for cross platform development?

2012-03-25 Thread Jacob Carlborg
On 2012-03-25 13:12, Bennie Copeland wrote: Hello all. I'm sorry if this has been addressed before. For a little background. I've been studying C++ with the intention of doing cross platform work on Windows, OSX, and eventually iOS and some other mobile OSes. My plan was to write cross platform

Re: How to use D for cross platform development?

2012-03-25 Thread Alex Rønne Petersen
On 25-03-2012 17:04, Jacob Carlborg wrote: On 2012-03-25 13:12, Bennie Copeland wrote: Hello all. I'm sorry if this has been addressed before. For a little background. I've been studying C++ with the intention of doing cross platform work on Windows, OSX, and eventually iOS and some other

Re: How to use D for cross platform development?

2012-03-25 Thread Jacob Carlborg
On 2012-03-25 18:20, Alex Rønne Petersen wrote: About ARM support: That's not strictly true. D on ARM should work fine at this point in time if you build druntime/phobos in GDC with -fno-section-anchors (there is even some experimental Android support). But indeed, no iOS support. Ok, I

Re: How to use D for cross platform development?

2012-03-25 Thread Iain Buclaw
On 25 March 2012 21:31, Jacob Carlborg d...@me.com wrote: On 2012-03-25 18:20, Alex Rønne Petersen wrote: About ARM support: That's not strictly true. D on ARM should work fine at this point in time if you build druntime/phobos in GDC with -fno-section-anchors (there is even some experimental

Re: How to use D for cross platform development?

2012-03-25 Thread James Miller
On 26 March 2012 09:44, Iain Buclaw ibuc...@ubuntu.com wrote: A spork of druntime, yes. A spork? I've never heard that before... -- James Miller

Re: How to use D for cross platform development?

2012-03-25 Thread Iain Buclaw
On 25 March 2012 21:55, James Miller ja...@aatch.net wrote: On 26 March 2012 09:44, Iain Buclaw ibuc...@ubuntu.com wrote: A spork of druntime, yes. A spork? I've never heard that before... It's constantly merged from upstream, however we keep any GDC-specific differences in-house. -- Iain

Re: How to use D for cross platform development?

2012-03-25 Thread Jonathan M Davis
On Monday, March 26, 2012 09:55:00 James Miller wrote: On 26 March 2012 09:44, Iain Buclaw ibuc...@ubuntu.com wrote: A spork of druntime, yes. A spork? I've never heard that before... http://en.wikipedia.org/wiki/Spork Not that it has anything to do with software... - Jonathan M Davis

Re: How to use D for cross platform development?

2012-03-25 Thread Kevin Cox
On Mar 25, 2012 7:34 PM, Jonathan M Davis jmdavisp...@gmx.com wrote: On Monday, March 26, 2012 09:55:00 James Miller wrote: On 26 March 2012 09:44, Iain Buclaw ibuc...@ubuntu.com wrote: A spork of druntime, yes. A spork? I've never heard that before...

Re: How to use D for cross platform development?

2012-03-25 Thread Michel Fortin
On 2012-03-25 15:04:34 +, Jacob Carlborg d...@me.com said: A third option for Objective-C would be to use a fork of DMD that makes it possible to directly interface with Objective-C, just as it's possible with C. I'm not sure of the status of this project but an alpha has been released.