diff options
author | Artturin <Artturin@artturin.com> | 2022-03-24 07:01:29 +0200 |
---|---|---|
committer | Artturin <Artturin@artturin.com> | 2022-03-26 21:55:19 +0200 |
commit | c3c0444949ed44a718c20d49acf4a115c406b03a (patch) | |
tree | d0049a3011c27d0114bec70b436fb39ce7ab4dea /pkgs/tools/misc/findutils | |
parent | 77dc421883b42aff99b04b3077ae9ab36af7ed90 (diff) |
findutils: move {locate,updatedb} to a separate $locate output
https://github.com/NixOS/nixpkgs/issues/53925
Diffstat (limited to 'pkgs/tools/misc/findutils')
-rw-r--r-- | pkgs/tools/misc/findutils/default.nix | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/pkgs/tools/misc/findutils/default.nix b/pkgs/tools/misc/findutils/default.nix index 56d710c854549..3c3b15962a7be 100644 --- a/pkgs/tools/misc/findutils/default.nix +++ b/pkgs/tools/misc/findutils/default.nix @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { && (stdenv.hostPlatform.libc != "musl") && stdenv.hostPlatform == stdenv.buildPlatform; - outputs = [ "out" "info" ]; + outputs = [ "out" "info" "locate"]; configureFlags = [ # "sort" need not be on the PATH as a run-time dep, so we need to tell @@ -46,6 +46,18 @@ stdenv.mkDerivation rec { "-D__nonnull\\(params\\)=" ]; + postInstall = '' + moveToOutput bin/locate $locate + moveToOutput bin/updatedb $locate + ''; + + # can't move man pages in postInstall because the multi-output hook will move them back to $out + postFixup = '' + moveToOutput share/man/man5 $locate + moveToOutput share/man/man1/locate.1.gz $locate + moveToOutput share/man/man1/updatedb.1.gz $locate + ''; + enableParallelBuilding = true; meta = { @@ -62,9 +74,12 @@ stdenv.mkDerivation rec { The tools supplied with this package are: * find - search for files in a directory hierarchy; + * xargs - build and execute command lines from standard input. + + The following are available in the locate output: + * locate - list files in databases that match a pattern; * updatedb - update a file name database; - * xargs - build and execute command lines from standard input. ''; platforms = lib.platforms.all; |