An attempt at resolving #8 by getting the GCC compilation step to have
GNU-based `sed` and other commands available. At the very least, I'm
assuming this won't break things. Fingers crossed.
The `feature/native-comp-macos-fixes` has seemingly been updated about
once a week with latest changes from `feature/native-comp`.
As the fix in the branch is desired, a custom function that applies the
same kind of fix has been added. This should be more reliable than just
downloading the git diff as a patch.
As detailed in Update 11 (https://akrl.sdf.org/gccemacs.html#org4b11ea1)
the `*.eln` cache location has been changed, which initially broke
builds.
This fixes those issues, and also simplifies usage of the build-script
by:
- Auto-detecting native-comp support if not explicitly enabled/disabled
with CLI flags.
- Auto-detecting number of logical CPU cores on your machine, and
defaulting the `-j` option to said number to ensure fast builds.
- Enable XWidgets by default, only skip if `configure` script doesn't
support it (Emacs 26.x and earlier).
Instead of just installing a pre-patched gcc formula, copy the local
formula from Homebrew and apply a patch to it, before then installing
it. This should be a lot more future-proof.
Notes:
- The sRGB patch is now a simple text-replacement, as diff/patch files
seem to just fail. Even Homebrew's emacs formula does it this way.
- Removed fullscreen patch, as Emacs 24.4 includes fullscreen support on
OS X, both native and pre-Lion style fullscreen. More details here:
http://www.emacswiki.org/emacs/FullScreen#toc23
This also applies some kind of convention for the available options.
`--srgb` is still defined for backwards compatibility, but it technically
does nothing.