diff --git a/pkgs/development/libraries/tomlplusplus/default.nix b/pkgs/development/libraries/tomlplusplus/default.nix index 529a9c349a49..38217f3f2b57 100644 --- a/pkgs/development/libraries/tomlplusplus/default.nix +++ b/pkgs/development/libraries/tomlplusplus/default.nix @@ -1,6 +1,7 @@ { cmake, fetchFromGitHub, + fetchpatch2, glibcLocales, lib, meson, @@ -22,6 +23,15 @@ stdenv.mkDerivation (finalAttrs: { hash = "sha256-h5tbO0Rv2tZezY58yUbyRVpsfRjY3i+5TPkkxr6La8M="; }; + patches = [ + # https://github.com/marzer/tomlplusplus/pull/233 + (fetchpatch2 { + name = "tomlplusplus-install-example-programs.patch"; + url = "https://github.com/marzer/tomlplusplus/commit/8128eb632325d1820f4d17dd8250dcda6ab07743.patch"; + hash = "sha256-7m2P+e1/OASHrzm9LSy6RnayS/kGxFC82xOyGBGXeG0="; + }) + ]; + nativeBuildInputs = [ meson cmake @@ -34,7 +44,10 @@ stdenv.mkDerivation (finalAttrs: { ]; doCheck = true; - mesonFlags = [ "-Dbuild_tests=${lib.boolToString finalAttrs.doCheck}" ]; + mesonFlags = [ + "-Dbuild_tests=${lib.boolToString finalAttrs.doCheck}" + "-Dbuild_examples=true" + ]; passthru = { updateScript = nix-update-script { };