Unverified Commit 80893e00 authored by Weijia Wang's avatar Weijia Wang Committed by GitHub
Browse files

bazel_{5,6,7}: use new apple sdk pattern (#370672)

parents 7f5756b0 ff65ee04
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -94,6 +94,7 @@ buildPythonPackage rec {
      # AssertionError (flaky numerical tests)
      "test_logreg_with_intercept_manual_loop3"
      "test_binary_logit_log_likelihood"
      "test_inv_hessian_product_pytree3"
    ];

  meta = {
+2 −0
Original line number Diff line number Diff line
@@ -92,6 +92,8 @@ buildPythonPackage rec {
      "test_min_max_norm"
    ]
    ++ lib.optionals stdenv.isDarwin [
      # TypeError: Cannot convert a MPS Tensor to float64 dtype as the MPS framework doesn't support float64. Please use float32 instead.
      "test_dynamic_backend_torch"
      # AttributeError: module 'numpy' has no attribute 'float128'. Did you mean: 'float16'?
      "test_spectrogram_error"
    ];
+0 −10
Original line number Diff line number Diff line
@@ -30,9 +30,6 @@
  cctools,
  libcxx,
  sigtool,
  CoreFoundation,
  CoreServices,
  Foundation,
  # Allow to independently override the jdks used to build and run respectively
  buildJdk,
  runJdk,
@@ -455,10 +452,6 @@ stdenv.mkDerivation rec {
        # Explicitly configure gcov since we don't have it on Darwin, so autodetection fails
        export GCOV=${coreutils}/bin/false

        # Framework search paths aren't added by bintools hook
        # https://github.com/NixOS/nixpkgs/pull/41914
        export NIX_LDFLAGS+=" -F${CoreFoundation}/Library/Frameworks -F${CoreServices}/Library/Frameworks -F${Foundation}/Library/Frameworks"

        # libcxx includes aren't added by libcxx hook
        # https://github.com/NixOS/nixpkgs/pull/41589
        export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -isystem ${lib.getDev libcxx}/include/c++/v1"
@@ -633,9 +626,6 @@ stdenv.mkDerivation rec {
    ++ lib.optionals (stdenv.hostPlatform.isDarwin) [
      cctools
      libcxx
      CoreFoundation
      CoreServices
      Foundation
    ];

  # Bazel makes extensive use of symlinks in the WORKSPACE.
+2 −6
Original line number Diff line number Diff line
@@ -8,7 +8,7 @@
# updater
, python3, writeScript
# Apple dependencies
, cctools, libcxx, CoreFoundation, CoreServices, Foundation, sigtool
, cctools, libcxx, sigtool
# Allow to independently override the jdks used to build and run respectively
, buildJdk, runJdk
, runtimeShell
@@ -415,10 +415,6 @@ stdenv.mkDerivation rec {
      # Explicitly configure gcov since we don't have it on Darwin, so autodetection fails
      export GCOV=${coreutils}/bin/false

      # Framework search paths aren't added by bintools hook
      # https://github.com/NixOS/nixpkgs/pull/41914
      export NIX_LDFLAGS+=" -F${CoreFoundation}/Library/Frameworks -F${CoreServices}/Library/Frameworks -F${Foundation}/Library/Frameworks"

      # libcxx includes aren't added by libcxx hook
      # https://github.com/NixOS/nixpkgs/pull/41589
      export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -isystem ${lib.getDev libcxx}/include/c++/v1"
@@ -583,7 +579,7 @@ stdenv.mkDerivation rec {
    which
    zip
    python3.pkgs.absl-py   # Needed to build fish completion
  ] ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ cctools libcxx sigtool CoreFoundation CoreServices Foundation ];
  ] ++ lib.optionals (stdenv.hostPlatform.isDarwin) [ cctools libcxx sigtool ];

  # 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
+0 −11
Original line number Diff line number Diff line
@@ -37,10 +37,6 @@
  libcxx,
  libtool,
  sigtool,
  CoreFoundation,
  CoreServices,
  Foundation,
  IOKit,
  # Allow to independently override the jdks used to build and run respectively
  buildJdk,
  runJdk,
@@ -410,10 +406,6 @@ stdenv.mkDerivation rec {
        # Explicitly configure gcov since we don't have it on Darwin, so autodetection fails
        export GCOV=${coreutils}/bin/false

        # Framework search paths aren't added by bintools hook
        # https://github.com/NixOS/nixpkgs/pull/41914
        export NIX_LDFLAGS+=" -F${CoreFoundation}/Library/Frameworks -F${CoreServices}/Library/Frameworks -F${Foundation}/Library/Frameworks -F${IOKit}/Library/Frameworks"

        # libcxx includes aren't added by libcxx hook
        # https://github.com/NixOS/nixpkgs/pull/41589
        export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -isystem ${lib.getDev libcxx}/include/c++/v1"
@@ -564,9 +556,6 @@ stdenv.mkDerivation rec {
    ++ lib.optionals (stdenv.hostPlatform.isDarwin) [
      cctools
      libcxx
      Foundation
      CoreFoundation
      CoreServices
    ];

  # Bazel makes extensive use of symlinks in the WORKSPACE.
Loading