nixpkgs/pkgs/development/libraries/nlohmann_json/default.nix
Ryan Mulligan 6c3855038a nlohmann_json: 3.1.1 -> 3.1.2
Semi-automatic update generated by https://github.com/ryantm/nix-update tools. These checks were done:

- built on NixOS
- Warning: no binary found that responded to help or version flags. (This warning appears even if the package isn't expected to have binaries.)
- found 3.1.2 with grep in /nix/store/ak7p93w4pkmjvx5fi82fg40rra5z6g44-nlohmann_json-3.1.2
- directory tree listing: https://gist.github.com/cebf8a5968a9c2ae65ec58227044fcad
2018-03-22 17:45:10 -07:00

37 lines
842 B
Nix

{ stdenv, fetchFromGitHub, cmake
, hostPlatform
}:
stdenv.mkDerivation rec {
name = "nlohmann_json-${version}";
version = "3.1.2";
src = fetchFromGitHub {
owner = "nlohmann";
repo = "json";
rev = "v${version}";
sha256 = "1mpr781fb2dfbyscrr7nil75lkxsazg4wkm749168lcf2ksrrbfi";
};
nativeBuildInputs = [ cmake ];
doCheck = true;
checkTarget = "test";
enableParallelBuilding = true;
crossAttrs = {
cmakeFlags = "-DBuildTests=OFF";
doCheck = false;
} // stdenv.lib.optionalAttrs (hostPlatform.libc == "msvcrt") {
cmakeFlags = "-DBuildTests=OFF -DCMAKE_SYSTEM_NAME=Windows";
};
meta = with stdenv.lib; {
description = "Header only C++ library for the JSON file format";
homepage = https://github.com/nlohmann/json;
license = licenses.mit;
platforms = platforms.all;
};
}