3
0
Fork 0
forked from mirrors/nixpkgs

nlohmann_json: Don't use stdenv.cross

This commit is contained in:
hsloan 2017-06-28 16:23:34 -04:00 committed by John Ericson
parent 8b726dc116
commit 51856df2a1

View file

@ -1,4 +1,6 @@
{ stdenv, fetchFromGitHub, cmake }: { stdenv, fetchFromGitHub, cmake
, hostPlatform
}:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "nlohmann_json-${version}"; name = "nlohmann_json-${version}";
@ -21,7 +23,7 @@ stdenv.mkDerivation rec {
crossAttrs = { crossAttrs = {
cmakeFlags = "-DBuildTests=OFF"; cmakeFlags = "-DBuildTests=OFF";
doCheck = false; doCheck = false;
} // stdenv.lib.optionalAttrs (stdenv.cross.libc == "msvcrt") { } // stdenv.lib.optionalAttrs (hostPlatform.libc == "msvcrt") {
cmakeFlags = "-DBuildTests=OFF -DCMAKE_SYSTEM_NAME=Windows"; cmakeFlags = "-DBuildTests=OFF -DCMAKE_SYSTEM_NAME=Windows";
}; };