about summary refs log tree commit diff
path: root/pkgs/tools/misc/mandoc
diff options
context:
space:
mode:
authorsternenseemann <sternenseemann@systemli.org>2021-11-15 11:59:04 +0100
committersterni <sternenseemann@systemli.org>2021-11-15 17:18:36 +0100
commitf16721775ee53a355733d9e18233234f6620070c (patch)
tree6250feea8075560d5d48321a22cb80177052457b /pkgs/tools/misc/mandoc
parentbb61b6aaef2f5740e04a48851f5586324f238f41 (diff)
mandoc: allow makewhatis(8) to index the nix store
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.
Diffstat (limited to 'pkgs/tools/misc/mandoc')
-rw-r--r--pkgs/tools/misc/mandoc/default.nix2
1 files changed, 2 insertions, 0 deletions
diff --git a/pkgs/tools/misc/mandoc/default.nix b/pkgs/tools/misc/mandoc/default.nix
index db0789c112671..1771f6515bc41 100644
--- a/pkgs/tools/misc/mandoc/default.nix
+++ b/pkgs/tools/misc/mandoc/default.nix
@@ -42,6 +42,8 @@ stdenv.mkDerivation rec {
     SBINDIR="$PREFIX/bin"
     CC=${stdenv.cc.targetPrefix}cc
     AR=${stdenv.cc.bintools.targetPrefix}ar
+    # Allow makewhatis(8) to follow symlinks from a manpath to the nix store
+    READ_ALLOWED_PATH=${builtins.storeDir}
     # Bypass the locale(1)-based check for UTF-8 support since it causes trouble:
     # * We only have meaningful locale(1) implementations for glibc and macOS
     # * NetBSD's locale(1) (used for macOS) depends on mandoc