summary refs log tree commit diff
diff options
context:
space:
mode:
authorMatthew Bauer <mjbauer95@gmail.com>2018-05-12 10:02:30 -0500
committerMatthew Bauer <mjbauer95@gmail.com>2018-05-12 10:02:30 -0500
commitd000198ab7f845406e055bdfd4d4ce4f76aca890 (patch)
tree09a9b79a125225a52b70c92d1b4522bdd05660a6
parent108cf05ff06618a5eed65267bcb68a140acc11dc (diff)
downloadnixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar.gz
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar.bz2
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar.lz
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar.xz
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.tar.zst
nixpkgs-d000198ab7f845406e055bdfd4d4ce4f76aca890.zip
darwin.architecture: correctly install headers
I’m not going to fix all of them but this is the best way to do this
in Apple things. Just add ‘EXPORT_DSTDIR’ to the installFlags & set
‘DSTDIR’ to $(out). Please do this instead of the patching!
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix12
1 files changed, 2 insertions, 10 deletions
diff --git a/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix b/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
index 8b3eb2017e2..4a155a4c403 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
@@ -3,17 +3,9 @@
 appleDerivation {
   dontBuild = true;
 
-  postPatch = ''
-    substituteInPlace $sourceRoot/Makefile \
-      --replace "/usr/include" "/include" \
-      --replace "/usr/bin/" "" \
-      --replace "/bin/" ""
-  '';
+  installFlags = [ "EXPORT_DSTDIR=/include/architecture" ];
 
-  installPhase = ''
-    export DSTROOT=$out
-    make install
-  '';
+  DSTROOT = "$(out)";
 
   meta = with stdenv.lib; {
     maintainers = with maintainers; [ copumpkin ];