Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bazel: use llvm6 on darwin #61112

Merged
merged 1 commit into from May 12, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkgs/development/tools/build-managers/bazel/default.nix
Expand Up @@ -153,7 +153,7 @@ stdenv.mkDerivation rec {
sed -i -e 's/<.*\*>//g' tools/osx/xcode_locator.m

# don't use system installed Xcode to run clang, use Nix clang instead
sed -i -e "s;/usr/bin/xcrun clang;${clang}/bin/clang $NIX_CFLAGS_COMPILE $NIX_LDFLAGS -framework CoreFoundation;g" \
sed -i -e "s;/usr/bin/xcrun clang;${stdenv.cc}/bin/clang $NIX_CFLAGS_COMPILE $NIX_LDFLAGS -framework CoreFoundation;g" \
scripts/bootstrap/compile.sh \
src/tools/xcode/realpath/BUILD \
src/tools/xcode/stdredirect/BUILD \
Expand Down Expand Up @@ -256,7 +256,7 @@ stdenv.mkDerivation rec {
makeWrapper
which
customBash
] ++ lib.optionals (stdenv.isDarwin) [ cctools clang libcxx CoreFoundation CoreServices Foundation ];
] ++ lib.optionals (stdenv.isDarwin) [ cctools libcxx CoreFoundation CoreServices Foundation ];

# Bazel makes extensive use of symlinks in the WORKSPACE.
# This causes problems with infinite symlinks if the build output is in the same location as the
Expand Down
5 changes: 4 additions & 1 deletion pkgs/top-level/all-packages.nix
Expand Up @@ -8660,13 +8660,16 @@ in

bam = callPackage ../development/tools/build-managers/bam {};

bazel_0_4 = callPackage ../development/tools/build-managers/bazel/0.4.nix { };
bazel_0_4 = callPackage ../development/tools/build-managers/bazel/0.4.nix {
stdenv = if stdenv.cc.isClang then llvmPackages_6.stdenv else stdenv;
};
bazel = callPackage ../development/tools/build-managers/bazel {
inherit (darwin) cctools;
inherit (darwin.apple_sdk.frameworks) CoreFoundation CoreServices Foundation;
buildJdk = jdk8;
buildJdkName = "jdk8";
runJdk = jdk11;
stdenv = if stdenv.cc.isClang then llvmPackages_6.stdenv else stdenv;
};

bazel-buildtools = callPackage ../development/tools/build-managers/bazel/buildtools { };
Expand Down