-
Notifications
You must be signed in to change notification settings - Fork 353
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Remove the default SDK from stdenv. This is currently not easy to do. - Ensure users can set their own SDK if necessary via `packages`.
- Loading branch information
Showing
3 changed files
with
66 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ pkgs, ... }: | ||
|
||
{ | ||
packages = [ pkgs.apple-sdk ]; | ||
|
||
# Test that the above SDK is picked up by xcode-select. | ||
enterTest = '' | ||
if [ -v "$DEVELOPER_DIR" ]; then | ||
echo "DEVELOPER_DIR is not set." | ||
exit 1 | ||
fi | ||
xcode-select -p | grep -q /nix/store | ||
''; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
# Test that there is no default SDK set on macOS. | ||
enterTest = '' | ||
variables_to_check=( | ||
"DEVELOPER_DIR" | ||
"DEVELOPER_DIR_FOR_BUILD" | ||
"SDKROOT" | ||
"NIX_APPLE_SDK_VERSION" | ||
) | ||
for var in "''${variables_to_check[@]}"; do | ||
if [ -v "$var" ]; then | ||
echo "$var is set. Expected no default Apple SDK." >&2 | ||
exit 1 | ||
fi | ||
done | ||
''; | ||
} |