@@ -36,7 +36,7 @@
3636, libidn
3737, libedit
3838, readline
39−, sdk
39+, apple_sdk
4040, libGL
4141, libGLU
4242, mesa
@@ -167,13 +167,15 @@ stdenv.mkDerivation rec {
167167 ]) ++ lib.optionals stdenv.isDarwin [
168168 libedit
169169 readline
170+ ] ++ lib.optional (stdenv.isDarwin && !stdenv.isAarch64) (
170171 # Pull a header that contains a definition of proc_pid_rusage().
171172 # (We pick just that one because using the other headers from `sdk` is not
172− # compatible with our C++ standard library)
173− (runCommandNoCC "${pname}_headers" {} ''
174− install -Dm444 "${lib.getDev sdk}"/include/libproc.h "$out"/include/libproc.h
175− '')
176− ] ++ lib.optionals stdenv.isLinux [
173+ # compatible with our C++ standard library. This header is already in
174+ # the standard library on aarch64)
175+ runCommandNoCC "${pname}_headers" {} ''
176+ install -Dm444 "${lib.getDev apple_sdk.sdk}"/include/libproc.h "$out"/include/libproc.h
177+ ''
178+ ) ++ lib.optionals stdenv.isLinux [
177179 bubblewrap
178180 libseccomp
179181 systemd