Commit 50d30186 authored by Ben Siraphob's avatar Ben Siraphob
Browse files

dartsim: fix darwin build

parent 78ad9b7f
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -138,6 +138,8 @@ stdenv.mkDerivation (finalAttrs: {
    python3Packages.pythonImportsCheckHook
  ];

  env.NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=deprecated-literal-operator";

  doCheck = true;

  pythonImportsCheck = [ "dartpy" ];
+4 −1
Original line number Diff line number Diff line
@@ -54,7 +54,10 @@ stdenv.mkDerivation rec {
    })
  ];

  postPatch = ''
  # The LZ4 patch updates cmake_minimum_required to 3.12, but only for non-clang builds.
  # For clang builds (like Darwin), we need to manually update it.
  # ref. https://github.com/flann-lib/flann/pull/526 not merged yet
  postPatch = lib.optionalString stdenv.cc.isClang ''
    substituteInPlace CMakeLists.txt \
      --replace-fail "cmake_minimum_required(VERSION 2.6)" "cmake_minimum_required(VERSION 3.5)"
  '';