re-fix evaluation of libSystemClosure

+9 -8
+9 -8
pkgs/stdenv/pure-darwin/default.nix
··· 6 6 7 7 let 8 8 # libSystem and its transitive dependencies. Get used to this; it's a recurring theme in darwin land 9 - libSystemClosure = if system == "x86_64-darwin" 10 - then [ 9 + libSystemClosure = [ 11 10 "/usr/lib/libSystem.dylib" 12 11 "/usr/lib/libSystem.B.dylib" 13 12 "/usr/lib/libobjc.A.dylib" ··· 17 16 "/usr/lib/libc++.1.dylib" 18 17 "/usr/lib/libDiagnosticMessagesClient.dylib" 19 18 "/usr/lib/system" 20 - ] 21 - else []; 19 + ]; 22 20 23 - fetch = { file, sha256 }: derivation ((import <nix/fetchurl.nix> { 21 + fetch = { file, sha256 }: let drv = import <nix/fetchurl.nix> { 24 22 url = "https://dl.dropboxusercontent.com/u/2857322/${file}"; 25 23 inherit sha256; 26 24 executable = true; 27 - }).drvAttrs // { 28 - __impureHostDeps = libSystemClosure; 29 - }); 25 + }; in 26 + if drv.drvAttrs.system == "x86_64-darwin" 27 + then derivation (drv.drvAttrs // { 28 + __impureHostDeps = libSystemClosure; 29 + }) 30 + else drv; 30 31 31 32 bootstrapFiles = { 32 33 sh = fetch { file = "sh"; sha256 = "1qakpg37vl61jnkplz13m3g1csqr85cg8ybp6jwiv6apmg26isnm"; };