© 2018-2019 by Zack Smith. All rights reserved.
With MacOS, as with Windows, a great many useful free/libre open-source programs and libraries are not included with the operating system. They are missing by default, so you have to go through some effort to add them. Whereas on Windows people usually rely on Cygwin for this purpose, which lets you select and download a huge number of precompiled binaries, on the Mac people often go with Github's Homebrew or MacPorts.
The problem with downloading binaries is that, whether they are executables and libraries, there is always the risk that they can contain malware, such as spyware or worse. Few people take care to verify who it is that provided these binaries. The exact responsible person is often completely concealed. But there are many bad players out there, so you should beware. They don't want you to think critically, to be skeptical, to question at all.
Just one example: When the CIA brags that they have a presence on many developers' MacOS computers, you have to wonder. If true, how did they achieve that? Even with the wealth of information about their hacks, could there be more?
I assert that the wise choice of action is to never download binaries. Always build from source code yourself, as the Gentoo Linux project does. Herein I shall describe how this can be done.
There are four situations you will encounter when building from source code:
- The software builds easily, typically with a provided configure script.
- The software builds but this requires light-to-moderate effort because it calls for a special procedure.
- The software was made for whatever reason nearly impossible to build, and no one except a paid specialist would endure the horrible experience of doing a build, because it is basically a software enema. These packages are onerous to build. (Example: TOR Browser)
- The software is incompatible with MacOS e.g. it is Linux-only, or is abandonware, or relies on incompatible libraries. (Examples: links, gnupg)
1a. Easy (using
Most software falls into the first category. Software in this category sometimes requires using an older version, because newer MacOSes break some things. The following seem build just fine using my installer usual.sh:
- libvorbis-1.3.6 # requires ogg
- fontconfig-2.8.0 # later versions do not build.
Note that the above order is not strict. Certain packages rely on other packages so in some cases the above ordering reflects these dependencies but for the most part it doesn't.
The International Components for Unicode
package has to be renamed to from
icu.tar.gz for the above script to accept it.
1b. Easy (using
Lots of programs don't have a
configure script but rather use
For this purpose, a revised installer is needed,
which I call usualc.sh:
This script works for these:
- usualc.sh libzip-1.5.1
- usualc.sh glfw-3.2.1
- usualc.sh openjpeg-2.3.0
This is easy but it's sensitive to the order of compilation, which is:
Several applications require special procedures.
./configure --with-included-unistring --without-p11-kit)
./configure --enable-cocoa --target-list=i386-softmmu,x86_64-softmmu --audio-drv-list=coreaudio
- glib-2.58.1 (see script below)
- MPlayer-1.3.0 -- requires an older ffmpeg e.g. 3.0, the latest code doesn't work.
- WebKit -- note, this is 19 GB when built.
To build 1.8.1:
glib is required for
qemu 3.0.0. The script to build it is in the Scripts section below.
This is needed for
wget. It requires
libunistring but after that's installed,
gnutls configure script ignores it. It requires p11-kit but this does not build on MacOS.
During the final stage of
gnutls installation, it fails because MacOS's
is incompatible with GNU
This is needed for
wget. It builds fine however wget's configure script ignores it
and ignores MacOS's built-in OpenSSL.
- TOR Browser
- rawtherapee (depends on GTK)
- db-4.4.20 -- C++ headers are the problem.
- bitcoin-0.16.2 -- relies on db.
- Dillo (relies on FLTK)
- wine -- requires 32-bit executables, which as of MacOS Mojave maybe aren't allowed.