Why version() ?

Anders F Björklund afb at algonet.se
Thu Feb 12 04:21:25 PST 2009


Walter Bright wrote:

> version(OSX)
>
> I just don't think darwin is a good idea, as Apple doesn't even use it. 
> See http://developer.apple.com/unix/index.html, where "darwin" is 
> clearly second string. It looks like Apple is pushing aside "darwin" in 
> favor of "OSX".

Once upon a time, there was a difference between Darwin and Mac OS X.

Where Darwin was the underlying (open source) operating system, but
excluding the (proprietary) frameworks such as Carbon and Cocoa...
So you had two: Darwin OS and Mac OS X. And both of them were "Darwin",
so the term "puredarwin" was being used to refer to the open source OS.

If you only target the vendor product, and not the open source one,
then it doesn't really matter whether "Darwin" or "MacOSX" is used.
(or "OSX", which includes both iPhone OS and Mac OS X in one term)
Like you mentioned, GCC only predefines __APPLE__ and __MACH__...

Now, I still hate the term "OSX" but that's without technical reasons.

--anders


PS. See also http://en.wikipedia.org/wiki/Darwin_(operating_system)



More information about the Digitalmars-d mailing list