Skip to content

Commit

Permalink
Tidy up macos SDK update for intel (#114)
Browse files Browse the repository at this point in the history
  • Loading branch information
ThetaSinner authored Jan 3, 2025
1 parent b73f921 commit a1f275b
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,6 @@

# Crane doesn't know which version to select from a workspace, so we tell it where to look
crateInfo = craneLib.crateNameFromCargoToml { cargoToml = inputs.holochain + "/crates/holochain/Cargo.toml"; };

# On intel macs, the default SDK is still 10.12 and Holochain won't build against that because we're
# using a newer Go version. So override with the newest SDK available for x86_64-darwin.
apple_sdk = if system == "x86_64-darwin" then [ pkgs.apple-sdk_10_15 ] else [ ];
in
craneLib.buildPackage {
pname = "holochain";
Expand All @@ -105,7 +101,10 @@
buildInputs = [
pkgs.go
pkgs.perl
] ++ (pkgs.lib.optionals pkgs.stdenv.isDarwin apple_sdk);
]
# On intel macs, the default SDK is still 10.12 and Holochain won't build against that because we're
# using a newer Go version. So override with the newest SDK available for x86_64-darwin.
++ (pkgs.lib.optional (system == "x86_64-darwin") pkgs.apple-sdk_10_15);

# Build Holochain, CLI and local services (bootstrap + signal server) binaries.
# Pass extra arguments like feature flags to build command.
Expand Down

0 comments on commit a1f275b

Please sign in to comment.