43

I learned recently (on Super User) that Mac OS X uses the bash shell. I also know that OS X has a UNIX core.

I was searching for information about OS X and Open Source on google, but what I found was this site which seems to include the source code for OS X.
For instance, one of the links reads: Mac OS X 10.5.7 Source

So, is OS X open source?

There's an Apple Public Source License, but I'm bad at understanding legalese.

Besides the kernel, What about the various other pieces? The X server? Window Manager? File explorer? etc. What's open source and what's not?

4
  • 3
    Technically OSX has a BSD core, not UNIX Aug 7, 2009 at 15:04
  • 7
    @Jeremy French: From Wikipedia: "Historically, BSD has been considered a branch of UNIX". So by syllogism, OS X is UNIX, too. So, another quote: "Mac OS X v10.5 is certified UNIX 03 while running on Intel processors."
    – Nikhil
    Aug 8, 2009 at 12:02
  • 1
    @Jeremy French: Not that it proves you wrong or anything.
    – Nikhil
    Aug 8, 2009 at 12:03
  • 5
    This question is fantastic in so many ways. +1 Mar 7, 2012 at 2:33

8 Answers 8

47

Darwin is open source operation system from Apple and it's core of Mac OS X. But Darwin hasn't Mac OS X GUI.

  • Darwin is like Linux, FreeBSD, etc...
  • Mac OS X GUI is like KDE, GNome, etc...
3
  • 12
    I think a more appropriate analogy would be Darwin is to the Linux kernel as Mac OS X is to Ubuntu. Aug 18, 2009 at 20:31
  • 7
    That's a good concept when describing the GUI, but not so good when talking about open source. Ubuntu is open source (Gnome), while OS X is not (Aqua). Important to understand the difference IMO.
    – churnd
    Aug 19, 2009 at 10:40
  • 2
    XNU is the Mac OS X kernel. See: github.com/opensource-apple/xnu
    – Lourenco
    Jul 29, 2017 at 16:54
23

Others have already explained that Darwin is open source. It's Mac OS X's kernel, similar to how Linux is the kernel of a Linux distro. Mac OS X's windowing system (called Quartz Compositor) is not open source.

You also ask about other open source parts of Mac OS X:

Besides the kernel, What about the various other pieces? The X server? Window Manager? File explorer? etc. What's open source and what's not?

One of the most prominent Apple open source projects is probably WebKit, which was originally a fork of KHTML and KJS. WebKit is used by a huge number of browsers.

Another Apple open source project you may have used even if you don't use Mac OS X is [Bonjour](http://en.wikipedia.org/wiki/Bonjour_(software)), Apple's implementation of Zeroconf.

Apple also owns CUPS, a printing system that is used by a number of operating systems.

Apple also has a number of other open source projects, such as a streaming server, and they contribute to many more open source projects, such as gcc. You'll find more at opensource.apple.com and Mac OS forge. In addition to that, Mac OS X ships with hundreds of open source components from Apache to ZFS, most of which are not owned or maintained by Apple.

2
  • 2
    Wow, CUPS is from Apple?! That one's news for me... Jul 27, 2012 at 7:14
  • 2
    @CamiloMartin - well, Apple bought CUPS...
    – AstroFloyd
    May 20, 2015 at 19:09
13

The kernel is open source; the user interface and all the applications that the OS comes with are not.

Apple does maintain some open source projects, but for the most part, everything besides the core kernel is closed source. For example, WebKit (the HTML rendering engine behind Safari, Chrome, and other browsers) is open source, but the Safari browser itself is not. Finder, Spotlight, and most (if not all) of the applications that come with the OS are closed source.

5

Yes and no.

Unix isn't open sourced, and these days it's a certification for a family of OSes that match the Unix common standards. There are also still OSes that have a heritage in the original Unix versions - Solaris and some of the BSDs for example. None of these are GNU licensed - most BSD variants are BSD licensed, and some versions of Solaris were under the CDDL.

OS X is based off bits of FreeBSD, as well as a micro kernel called L7, and Apple has chosen to keep the source of this open - since they have the option to close it off under the BSD license.

Here's all of Apple's open source components.

The Darwin Kernel (based off BSD) is here - while in theory it's possible to build an OS off it - see OpenDarwin and PureDarwin. I'd note both projects appear dead, and you would lack many of the desktop components like the desktop and so on.

As such, well, it's sort of open sourced, but not in the same way as Linux or BSD. You couldn't build a working system off Apple's code, but you could pull in some other things and do so if you didn't mind losing much of the Apple UI.

Edit - as of Feb 2013, there appears to be a new release of PureDarwin, which claims fairly major changes. I have no idea if this means the project is alive or not. I also became aware that Darwin was released in compiled form here, which may be a useful starting point for hacking your way around things.

4
  • 2
    None of these are GNU licensed - most BSD varients are BSD licensed, reading this someone might think the BSD license is more restrictive than GNU... Jul 27, 2012 at 7:17
  • True, but cddl isn't. I've also mentioned that apple has the freedom to go completely closed off if they wished, which, practically is a major difference between BSD licensing and GPL. My answer also keeps talking about how the source of most of OS X is open, ut parts of it arn't. I wasn't going for a extensive discussion of the merits, demerits and relative freedom of various licences tho.
    – Journeyman Geek
    Jul 27, 2012 at 7:50
  • But, even if Apple were to close the source, the (old) BSD-licensed versions would still be "free", right? Also, just the kernel isn't "most of OS X"... and I'd assume the kernel is pretty limited (compared with Linux or Windows') considering OS X runs (officially) on just a handful of first-party computers. Jul 27, 2012 at 9:22
  • The ISOs are unfortunately only up to OS X 10.4 equivalent (2005).
    – Daniel Beck
    Feb 4, 2013 at 9:46
4

The Darwin OS, upon which OS X is based, is open source, as is the XNU kernel it uses. OS X's Aqua GUI is not open source, however. This effectively gives Apple the best of both worlds: they get an OS that has the stability and security of an open source, UNIX-like platform, while also having the profitability of a proprietary platform. This is like the McDonald's policy of giving you free water and charging you a quarter for the cup.

3

Many parts of OSX are open source - Apple is an active corporate participant in the community. Apple publishes the open-source portions of their software here. However, due to the non-open parts, the system is not free.

2

A few parts of OS X are open source (most notably the Darwin kernel), and it uses many open-source projects.

The "Mac OS X 10.5.7 Source" title is a bit misleading - the page lists all the open-source code used in OS X (such as Apache, Python, bash, etc)

Not much of what you probably consider "OS X" is open source - it's mostly underlying things (for example, the kernel, or the the SMB client/server used by the Windows-file-sharing feature)

1
  • 3
    Darwin is not the kernel in OSX. The kernel is called Mach. Darwin is the code name for the whole of the underlying ecosystem such as the filesystem, drivers, shell etc. i.e. Darwin is the OSX operating system and this is mostly open source.
    – hookenz
    Dec 8, 2015 at 20:26
1

Classic Unix does not have a GNU license. Ultimately, some parts of MacOS are available to the public, but it isn't "open source" or "free" in any meaningful way.

Apple do use many Open Source components, in full compliance with their license, in the overall product.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .