darwin.binutils.bintools: propagate man pages from cctools

This commit is contained in:
Dmitry Kalinkin 2020-04-20 20:05:35 -04:00
parent c450617f99
commit 125c469d3e
No known key found for this signature in database
GPG key ID: 5157B3EC8B2CA333

View file

@ -16,7 +16,7 @@ in
stdenv.mkDerivation {
pname = "${targetPrefix}cctools-binutils-darwin";
inherit (cctools) version;
outputs = [ "out" "info" "man" ];
outputs = [ "out" "man" ];
buildCommand = ''
mkdir -p $out/bin $out/include
@ -42,12 +42,13 @@ stdenv.mkDerivation {
ln -s ${cctools}/libexec $out/libexec
mkdir -p "$info/nix-support" "$man/nix-support"
printWords ${binutils-unwrapped.info} \
>> $info/nix-support/propagated-build-inputs
# FIXME: cctools missing man pages
printWords ${binutils-unwrapped.man} \
>> $man/nix-support/propagated-build-inputs
mkdir -p "$man"/share/man/man{1,5}
for i in ${builtins.concatStringsSep " " cmds}; do
for path in "${cctools.man}"/share/man/man?/$i.*; do
dest_path="$man''${path#${cctools.man}}"
ln -sv "$path" "$dest_path"
done
done
'';
passthru = {