Predefined Versions for Apple Operating Systems

Jonathan M Davis newsgroup.d at jmdavisprog.com
Sun Jun 22 04:16:37 UTC 2025


On Saturday, June 21, 2025 9:40:44 PM Mountain Daylight Time Walter Bright via Digitalmars-d wrote:
> Lots of good points, Jonathan.
>
> The current situation for C #defines for operating systems is an utter disaster.
> I can find zero official guidance from Apple on what to use.
>
> People have remarked that I was denigrating Linux by using lowercase "linux" as
> the version, but nothing of the sort was my intention. It was simply that
> "linux" was the most commonly used predefine in the Linux world.
>
> Maybe we should simply go with "Apple" as the umbrella for the various Apple
> operating systems, and be done with it. Maybe we can set a positive trend there!
> Wouldn't that be nice!

It would be nice.

And now that I think of it, much as having multiple names for the same thing
is usually a bad idea, maybe we should consider adding the Linux version
identifier as an alternate spelling for linux? That would increase
confusion, because folks would wonder about the difference (which is a big
part of why having duplicate names is usually a bad idea), but it seems like
folks screw that one up a lot. I don't know. It's just a thought.

In any case, I was aware of your reasoning for why you made it linux and not
Linux, which is why I commented that I thought that following C# defines in
the past has been problematic - and thus why I think that we should just
pick a reasonable name for this new one based on our naming conventions
(especially when the C ones are all over the place).

LOL. Either way, as a non-Mac person, it would be nice if what needed to be
done with version identifiers were clear. There are a ton of them, and I'd
thought that Darwin was supposed to be the one to combine them all where
possible, but then folks were talking like it wasn't a thing anymore, and
it's all quite confusing. I guess that it's yet one more thing that I should
arguably pay more attention to...

- Jonathan M Davis






More information about the Digitalmars-d mailing list