These files don't even parse using `nix-instantiate --parse`:
> error: undefined variable 'haskell-mode'
> error: undefined variable 'lib'
While these issues could be trivially fixed, the fact that these files
are not even parsable by nix-instantiate shows me that they are probably
unnecessary.
As discussed in [1], this improves readability.
Not all --with options have a corresponding --without (and vice-versa),
but Emacs's configure script can endure this. Additionally, this
"encodes" the default options in system-configuration-options.
[1]: https://github.com/NixOS/nixpkgs/pull/267946#issuecomment-1815394037
The invocation of the install.sh script changed in 8.1.0 or 8.0 to no
longer accept the --prefix flag, instead the path needs to be given as
the first argument alone.
When enabled (the default), Emacs compresses its files (.c, .el, .info,
and so on) before installing them.
Disabling the option with `withCompressInstall = false` results in the
suppression of that compression step. This increases disk space, but is
slightly faster for some operations; Emacs does not have to decompress
these files on the fly when, for example, jumping to the definition of a
built-in function.
stdenv.targetPlatform really shouldn't be used by software that
doesn't generate or manipulate binaries. I reviewed all uses of
targetPlatform outside of pkgs/development/compilers and pkgs/stdenv
and replaced those which weren't involved in something which fits
these criteria.
Quoting from the Emacs 29 release notes:
> Building Emacs includes generation of a Japanese dictionary, which is
> used by Japanese input methods. Previously, the build included a step
> of reducing the size of this dictionary's vocabulary. This vocabulary
> reduction is now optional, by default off. If you need the Emacs
> build to include the vocabulary reduction, configure Emacs with the
> option '--with-small-ja-dic'.
The `osx-dictionary` emacs package tries to build a helper executable
if it is not found at runtime. This fails with `nix` installations of
the package, so we build it at build time.