15 stdenv.mkDerivation (finalAttrs: {
16 pname = "tomlplusplus";
19 src = fetchFromGitHub {
21 repo = "tomlplusplus";
22 rev = "refs/tags/v${finalAttrs.version}";
23 hash = "sha256-h5tbO0Rv2tZezY58yUbyRVpsfRjY3i+5TPkkxr6La8M=";
27 # TODO: Remove this patch at the next update
28 # https://github.com/marzer/tomlplusplus/pull/233
30 name = "tomlplusplus-install-example-programs.patch";
31 url = "https://github.com/marzer/tomlplusplus/commit/8128eb632325d1820f4d17dd8250dcda6ab07743.patch";
32 hash = "sha256-7m2P+e1/OASHrzm9LSy6RnayS/kGxFC82xOyGBGXeG0=";
48 "-Dbuild_tests=${lib.boolToString finalAttrs.doCheck}"
49 "-Dbuild_examples=true"
52 # almost all tests fail on Darwin with the following exception:
53 # libc++abi: terminating due to uncaught exception of type std::runtime_error: collate_byname<char>::collate_byname failed to construct for
54 doCheck = !stdenv.hostPlatform.isDarwin;
57 updateScript = nix-update-script { };
58 tests.pkg-config = testers.hasPkgConfigModules {
59 package = finalAttrs.finalPackage;
64 homepage = "https://github.com/marzer/tomlplusplus";
65 description = "Header-only TOML config file parser and serializer for C++17";
66 license = licenses.mit;
67 maintainers = with maintainers; [ Scrumplex ];
68 pkgConfigModules = [ "tomlplusplus" ];
69 platforms = platforms.unix;