diff --git a/pkgs/stdenv/nix-linux-static/scripts/add-symlink.sh b/pkgs/stdenv/nix-linux-static/scripts/add-symlink.sh index b0a62794f602..c6429c803ce4 100644 --- a/pkgs/stdenv/nix-linux-static/scripts/add-symlink.sh +++ b/pkgs/stdenv/nix-linux-static/scripts/add-symlink.sh @@ -2,4 +2,6 @@ $extra2/bin/chmod u+w $out/include (cd $out/include && $extra2/bin/ln -s $extra/include/* .) || exit 1 cd $out +$extra3/bin/find . -not -type l -exec chmod u+w {} \; $extra3/bin/find . -exec $patchelf --interpreter $out/lib/ld-linux.so.2 --shrink-rpath {} \; +$extra3/bin/find . -not -type l -exec chmod u-w {} \;