cc65 under OS X

cc65 runs perfectly fine under various versions of OS X. While at the moment there are no up to date binary installation packages distributed, one can quite easily build his own binaries from sources provided as either stable versions in form of “tarballs” or check out the bleeding edge from snapshot directory or subversion repository.

Please note that in order to build cc65 from sources one requires a working UNIX development environment (especially GCC compiler), which is not a part of the default system installation. The requirements are then:

  • Apple Developer's Tools (mandatory) - please download1) appropriate, latest package available for your OS version and install it with “UNIX Development” option checked2)
  • linuxdoc-tools (optional) - required only to build the documentation3)

If you have downloaded the source “tarball”, extract the files from the archive to a directory of your choice. Since cc65 is very cleanly written - no additional configuration processes are needed. Once the necessary prerequisites are in place, start your terminal and cd to the directory where you have either extracted or checked out the cc65 sources. Simple command:

$ make -f make/gcc.mak

given from the directory you just cd'ed to, should be enough to build binaries, libraries, and documentation (the last only if the optional linuxdoc tools are installed)4)

Once the build process is finished without errors, the next step is to install the files in their default locations:

$ sudo make -f make/gcc.mak install

installs all the required files in their default location of /usr/local/5)


OS X 10.6 "Snow Leopard" (i386)

Building from source works 100% - tested

OS X 10.5 "Leopard" (ppc)

Building from source works 100% - tested

OS X 10.5 "Leopard" (i386)

Building from source works 100% - tested

OS X 10.4 "Tiger" (ppc)

Building from source should work fine - untested

OS X 10.4 "Tiger" (i386)

Building from source should work fine - untested

OS X 10.3 "Panther" (ppc)

Building from source should work fine - tested, please consider switching to 10.4, which is (IMHO) the first mature OS X version

OS X 10.2 "Jaguar" (ppc)

Building from source works 100% - tested, but while 10.2 was probably the first usable OS X version, you shouldn't really be running it anymore these days

OS X 10.1 or earlier (ppc)

Those were not really usable (IMHO) - I don't believe you might still be running it…

1) At the time of writing Apple provides necessary developer tools free of charge but requires registration in order to download the software.
2) Checking this option places all necessary command line tools, headers, and other files required for typical UNIX style development, where they are expected to be in a working unix development environment (/usr/)
3) Probably the easiest way to obtain a working set of linuxdoc tools is to install them using MacPorts (formerly known as “Darwin Ports”) software distribution system, which in itself is a very good thing to have also for many other reasons
4) The most recent versions of cc65 recognise automatically whether linuxdoc tools are present and skip the documentation build process if none found. Earlier versions, which were expecting linuxdoc-tools to be always present, had a bad habit of stopping the building process with error when no linuxdoc-tools were installed on the host machine. Therefore, if you get errors when building documentation, you should most probably update your source tree.
5) Please use the recent (2.13.1+) cc65 sources - some earlier version installed in different default locations, interfering sometimes with system's own binaries!
cc65/host_platforms/osx.txt · Last modified: 2012-10-01 12:34 by polluks
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki