Merge pull request #34088 from LnL7/xcbuild-platform-version
xcbuild: platform version
This commit is contained in:
commit
82de183455
|
@ -1,26 +1,30 @@
|
||||||
{ stdenv, writeText, toolchainName, sdkName, xcbuild }:
|
{ stdenv, writeText, toolchainName, sdkName, xcbuild }:
|
||||||
|
|
||||||
let
|
let
|
||||||
|
# TODO: expose MACOSX_DEPLOYMENT_TARGET in nix so we can use it here.
|
||||||
|
version = "10.10";
|
||||||
|
|
||||||
SDKSettings = {
|
SDKSettings = {
|
||||||
CanonicalName = sdkName;
|
CanonicalName = sdkName;
|
||||||
DisplayName = sdkName;
|
DisplayName = sdkName;
|
||||||
Toolchains = [ toolchainName ];
|
Toolchains = [ toolchainName ];
|
||||||
Version = "10.10";
|
Version = version;
|
||||||
MaximumDeploymentTarget = "10.10";
|
MaximumDeploymentTarget = version;
|
||||||
isBaseSDK = "YES";
|
isBaseSDK = "YES";
|
||||||
};
|
};
|
||||||
|
|
||||||
SystemVersion = {
|
SystemVersion = {
|
||||||
ProductName = "Mac OS X";
|
ProductName = "Mac OS X";
|
||||||
ProductVersion = "10.10";
|
ProductVersion = version;
|
||||||
};
|
};
|
||||||
|
|
||||||
in
|
in
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "MacOSX.sdk";
|
name = "MacOSX${version}.sdk";
|
||||||
|
inherit version;
|
||||||
|
|
||||||
buildInputs = [ xcbuild ];
|
buildInputs = [ xcbuild ];
|
||||||
|
|
||||||
buildCommand = ''
|
buildCommand = ''
|
||||||
mkdir -p $out/
|
mkdir -p $out/
|
||||||
plutil -convert xml1 -o $out/SDKSettings.plist ${writeText "SDKSettings.json" (builtins.toJSON SDKSettings)}
|
plutil -convert xml1 -o $out/SDKSettings.plist ${writeText "SDKSettings.json" (builtins.toJSON SDKSettings)}
|
||||||
|
|
|
@ -30,7 +30,7 @@ let
|
||||||
in
|
in
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "xcbuild-wrapper";
|
name = "xcbuild-wrapper-${xcbuild.version}";
|
||||||
|
|
||||||
buildInputs = [ xcbuild makeWrapper ];
|
buildInputs = [ xcbuild makeWrapper ];
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue