From c0ebcab789af5927e67117baae97534b72fea207 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Thu, 3 May 2018 13:35:01 -0500 Subject: [PATCH 1/5] darwin.ICU: delete old /usr files This is a huge directory & not referenced anywhere. --- pkgs/os-specific/darwin/apple-source-releases/ICU/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/os-specific/darwin/apple-source-releases/ICU/default.nix b/pkgs/os-specific/darwin/apple-source-releases/ICU/default.nix index eef26f4b79a..6cf7ee07b70 100644 --- a/pkgs/os-specific/darwin/apple-source-releases/ICU/default.nix +++ b/pkgs/os-specific/darwin/apple-source-releases/ICU/default.nix @@ -20,5 +20,6 @@ appleDerivation { postInstall = '' mv $out/usr/local/include $out/include + rm -rf $out/usr ''; } From 69d1b7ab79cc5e46d4b419cfe95c30e58f801a85 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Thu, 3 May 2018 13:36:06 -0500 Subject: [PATCH 2/5] darwin.libSystem: multiple outputs adds 2 outputs for libSystem: - out - dev should shrink closure sizes --- .../darwin/apple-source-releases/Libsystem/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix index 28406c9751d..89dc6eb74de 100644 --- a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix +++ b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix @@ -7,6 +7,8 @@ appleDerivation rec { nativeBuildInputs = [ cpio ]; + outputs = [ "out" "dev" ]; + installPhase = '' export NIX_ENFORCE_PURITY= From e25efa9673f3b274132875a4a95aae012b0b3467 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Thu, 3 May 2018 13:36:38 -0500 Subject: [PATCH 3/5] gettext: add dev output --- pkgs/development/libraries/gettext/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/gettext/default.nix b/pkgs/development/libraries/gettext/default.nix index 6dec7747c7e..e64c045ad81 100644 --- a/pkgs/development/libraries/gettext/default.nix +++ b/pkgs/development/libraries/gettext/default.nix @@ -10,7 +10,7 @@ stdenv.mkDerivation rec { }; patches = [ ./absolute-paths.diff ]; - outputs = [ "out" "man" "doc" "info" ]; + outputs = [ "out" "dev" "man" "doc" "info" ]; hardeningDisable = [ "format" ]; From d88a61e43996ab6b1a5f72adabfd19f4c97b9275 Mon Sep 17 00:00:00 2001 From: Matthew Justin Bauer Date: Thu, 3 May 2018 15:11:00 -0500 Subject: [PATCH 4/5] libsystem: fix phases --- .../darwin/apple-source-releases/Libsystem/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix index 89dc6eb74de..8575e067625 100644 --- a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix +++ b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix @@ -3,7 +3,8 @@ removefile, libresolv, Libnotify, libplatform, libpthread, mDNSResponder, launchd, libutil, version }: appleDerivation rec { - phases = [ "unpackPhase" "installPhase" ]; + dontBuild = true; + dontConfigure = true; nativeBuildInputs = [ cpio ]; From 5206574be32cbcfa8464dbf83db7d93dee784b5c Mon Sep 17 00:00:00 2001 From: Matthew Justin Bauer Date: Thu, 3 May 2018 18:02:57 -0500 Subject: [PATCH 5/5] stdenv: add libSystem.dev to allowedRequisites --- pkgs/stdenv/darwin/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/stdenv/darwin/default.nix b/pkgs/stdenv/darwin/default.nix index 9563f52ea26..98102cd5654 100644 --- a/pkgs/stdenv/darwin/default.nix +++ b/pkgs/stdenv/darwin/default.nix @@ -225,7 +225,7 @@ in rec { allowedRequisites = [ bootstrapTools ] ++ (with pkgs; [ xz.bin xz.out libcxx libcxxabi ]) ++ - (with pkgs.darwin; [ dyld Libsystem CF ICU locale ]); + (with pkgs.darwin; [ dyld Libsystem Libsystem.dev CF ICU locale ]); overrides = persistent; }; @@ -263,7 +263,7 @@ in rec { allowedRequisites = [ bootstrapTools ] ++ (with pkgs; [ xz.bin xz.out bash libcxx libcxxabi ]) ++ - (with pkgs.darwin; [ dyld ICU Libsystem locale ]); + (with pkgs.darwin; [ dyld ICU Libsystem Libsystem.dev locale ]); overrides = persistent; }; @@ -383,7 +383,7 @@ in rec { binutils.bintools darwin.binutils darwin.binutils.bintools cc.expand-response-params ]) ++ (with pkgs.darwin; [ - dyld Libsystem CF cctools ICU libiconv locale + dyld Libsystem Libsystem.dev CF cctools ICU libiconv locale ]); overrides = self: super: