For splicing to work, callPackage needs to be able to attach extra
attributes (e. g. nativeDrv) to pkgsHostTarget.mandoc. If we have the
assert like before, pkgsHostTarget.mandoc would fail to evaluate,
preventing buildPackages.mandoc (which works as expected) to be attached
to the former. This affected cross compilation of the netbsd package set
in particular.
isCompatible concerns itself with architecture compatibility which does
not constitute executability by itself, since there are other key
factors like the Kernel/syscall interface targeted. As mode switching is
considered compatible (e.g. ppc64le and ppc64), we can't even use
isCompatible to establish the architecture subset of executability.
For the lack of a better alternative, we'll just compare the system
tuples for now which will loose us support for x86_64-linux ->
i686-linux, but this is probably a bearable consequence.
To make makewhatis(8) index manual pages which are symlinks to the nix
store, we need to set READ_ALLOWED_PATH to include
`builtins.storeDir`. For background and discussion see:
https://inbox.vuxu.org/mandoc-tech/c9932669-e9d4-1454-8708-7c8e36967e8e@systemli.org/T/
This is a small change required as a prerequisite for #139333 which
causes a mass-rebuild for darwin, so it has to go through staging.
Since the change is trivial and has basically no chance of breaking
anything, we'll let it go through staging on its own, the modules
can be reviewed and merged into master later.
MANPATH_BASE is used by mandoc -T lint to check if man pages that are
referenced exist on the system. While this feature is a bit problematic
for us (e. g. it will never work correctly in the nix sandbox), it
hasn't even worked in an impure context before since MANPATH_BASE
defaults to /usr/share/man:/usr/X11R6/man.
mandoc can't be cross compiled easily since all configure checks rely on
executing a binary built using $CC. We can however still do “native”
cross compilation like pkgsStatic and pkgsLLVM. To facilitate this, the
following changes are required:
* Set the correct AR to use in configure.local
* Inform users that cross compilation will fail via a throw if the build
platform can't execute the host platform's binaries.
locale(1) is not available in pkgsMusl.stdenv, but it is also not really
necessary. We just need to tell mandoc about *any* UTF-8 locale that is
also available at runtime.
For macOS C.UTF-8 is not available sadly, so we need to use
en_US.UTF-8. Using locale(1) for this is out of the question as NetBSD's
locale(1) depends on mandoc.
* pkgs: refactor needless quoting of homepage meta attribute
A lot of packages are needlessly quoting the homepage meta attribute
(about 1400, 22%), this commit refactors all of those instances.
* pkgs: Fixing some links that were wrongfully unquoted in the previous
commit
* Fixed some instances