Files
nixpkgs/pkgs/by-name/to/toml11/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

61 lines
2.0 KiB
Nix

{
lib,
stdenv,
fetchFromGitHub,
cmake,
fetchpatch,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "toml11";
version = "4.4.0";
src = fetchFromGitHub {
owner = "ToruNiina";
repo = "toml11";
tag = "v${finalAttrs.version}";
hash = "sha256-NnM+I43UVcd72Y9h+ysAAc7s5gZ78mjVwIMReTJ7G5M=";
fetchSubmodules = true;
};
patches = [
(fetchpatch {
name = "literal-operator-whitespace.patch";
url = "https://patch-diff.githubusercontent.com/raw/ToruNiina/toml11/pull/285.patch";
hash = "sha256-LZPr/cY6BZXC6/rBIAMCcqEdnhJs1AvbrPjpHF76uKg=";
})
];
nativeBuildInputs = [
cmake
];
cmakeFlags = [
(lib.cmakeBool "TOML11_BUILD_TOML_TESTS" true)
];
doCheck = true;
meta = {
changelog = "https://github.com/ToruNiina/toml11/blob/${finalAttrs.src.tag}/docs/content.en/docs/changelog/_index.md";
homepage = "https://github.com/ToruNiina/toml11";
description = "TOML for Modern C++";
longDescription = ''
toml11 is a C++11 (or later) header-only toml parser/encoder depending
only on C++ standard library.
- It complies with the latest TOML language specification.
- It passes all the standard TOML language test cases.
- It supports new features merged into the upcoming TOML version (v1.1.0).
- It provides clear error messages, including the location of the error.
- It parses and retains comments, associating them with corresponding values.
- It maintains formatting information such as hex integers and considers these during serialization.
- It provides exception-less parse function.
- It supports complex type conversions from TOML values.
- It allows customization of the types stored in toml::value.
- It provides some extensions not present in the TOML language standard.
'';
license = lib.licenses.mit;
maintainers = [ lib.maintainers.cobalt ];
platforms = lib.platforms.unix ++ lib.platforms.windows;
};
})