xcbuild: Get rid of developer.nix, move to wrapper

also:

- add custom outputs "specs" for xcbuild
- get rid of unneeded tools
- update xcbuild
- add more comments
- fixup xcbuild derivations

Affected xcbuild derivations include:

- adv_cmds
- network_cmds
- basic_cmds
This commit is contained in:
Matthew Bauer
2016-11-15 19:13:23 -06:00
parent 4685bd7853
commit fc1f6f55ea
7 changed files with 35 additions and 55 deletions
+11 -6
View File
@@ -23,10 +23,6 @@ let
inherit sdk platformName xcbuild;
};
developer = callPackage ./developer.nix {
inherit platform toolchain xcbuild;
};
xcconfig = writeText "nix.xcconfig" ''
SDKROOT=${sdkName}
'';
@@ -50,13 +46,22 @@ stdenv.mkDerivation {
ln -s $file
done
mkdir -p $out/Library/Xcode/
ln -s ${xcbuild}/Library/Xcode/Specifications $out/Library/Xcode/Specifications
mkdir -p $out/Platforms/
ln -s ${platform} $out/Platforms/
mkdir -p $out/Toolchains/
ln -s ${toolchain} $out/Toolchains/
wrapProgram $out/bin/xcodebuild \
--add-flags "-xcconfig ${xcconfig}" \
--add-flags "DERIVED_DATA_DIR=." \
--set DEVELOPER_DIR "${developer}"
--set DEVELOPER_DIR "$out"
wrapProgram $out/bin/xcrun \
--add-flags "-sdk ${sdkName}" \
--set DEVELOPER_DIR "${developer}"
--set DEVELOPER_DIR "$out"
'';
passthru = {