Hacker News new | ask | show | jobs
by gorbypark 11 days ago
Off topic but I've always wondered why Apple ships XNU/Darwin as open source. As far as I know, there's no real usage of it outside of the "hobby" space and I don't think the license requires it to be open source. Any ideas as to why Apple continues to do it to this day?
2 comments

It's not open source, really. Not anymore. A lot of the newer code added since the first versions of macOS is proprietary. A lot of the code signing and security subsystem is closed source, the APFS file system is too, most of the drivers are etc.

As for why a few parts remain open, it's probably just inertia. When OS X was new the open source/free software movement was at the peak of its hype cycle, many treated it as a locked in future, sort of how people talk about AI today. Kernel engineers in general were always pretty pro-open source, much moreso than GUI layer developers, and Linux was already available and growing fast. People believed that desktop Linux could be a competitive platform back then.

So as XNU was built on open source components like FreeBSD and Mach, I guess there was some internal fights between pro- and anti- open source camps. Jobs or someone else resolved it by saying it was OK to open source the low value / generic parts like the UNIX parts, but not the higher value userspace where macOS historically had competitive advantage. Then as the years passed this became just the way things are done, and nobody revisited it.

It already starts at NeXT, as it was well known fact that they only based it on UNIX because they wanted the university market initially.

Also the Stepstone GCC based implementation of Objective-C frontend and language runtime were only begrudgingly contributed back to the project.

> it was well known fact that they only based it on UNIX because they wanted the university market

I'm a life long Apple/NeXT follower and I've never heard this.

Surely UNIX had its own clear merits as a foundation for a new OS.

So you haven't been following long enough it seems.

"Why We Have to Make UNIX Invisible."

https://www.usenix.org/blog/vault-steve-jobs-keynotes-1987-u...

> They said a Unix weenie was code for software engineers who hated what we were doing to Unix (the operating system we licensed)—putting a graphical user interface on it to dumb it down for grandmothers. They heckled Steve about his efforts to destroy it. His nightmare would be to speak to a crowd of them.

From https://web.archive.org/web/20180628214613/https://www.cake....

"NeXT marketing strategy video (1991)"

https://www.youtube.com/watch?v=KRBIH0CA7ZU

Then you can hop into a book like "Steve Jobs and the Next Big Thing" from Randall Stross.

None of those links or quotes support your claim.

The contrapositive would be that NeXT would have written a separate OS foundation that had nothing to do with UNIX, and your claim is that the only reason they didn't do this was to get universities to buy it. But your links only emphasize how much they wanted to hide the underpinnings (which is a good idea in general, since they were going for, y'know, a GUI.)

A much simpler explanation is that they needed UNIX's design as a well-understood and proven technical foundation, but were determined to hide that fact as much as possible, because they didn't believe in the CLI as the future of the user interface. But for markets where users actually wanted UNIX, they were happy to advertise that it was there.

Missed on the video, or the book, given that you assert none of them.

https://youtu.be/KRBIH0CA7ZU?t=136

"These are not machines for mere mortals!" when referring to traditional UNIX workstations.

Also it's not really a release and they don't really care. It seems more of a "we're legally obligated to dump something at release time". Their source is often missing headers, or parts of code and needs patches to compile. Apple is not building any open-source community here.
> It seems more of a "we're legally obligated to dump something at release time".

That's the thing, as far as I can tell, they are not legally obligated to do it, but continue to do it in such a way it seems like they don't care at all.

Well, it is based on open source work like the Mach microkernel and parts of BSD. Not sure how easy it would be to make it closed-source now.

From what I remember, the original idea was to keep it open source so the community would take part in the review of UNIX-compliance, as an external party to ensure that Apple doesn't accidentally drift away too much.

But yeah, since it barely has any use outside of Apple products, I doubt that there is much power in the community to actually influence it...

It's not GPL licensed. They could just not publish the source code anymore if they don't want to.