Files
nixpkgs/pkgs/by-name/un/units-llnl/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

43 lines
1.1 KiB
Nix

{
lib,
stdenv,
fetchFromGitHub,
cmake,
# This is the baseType needed by scipp - the main package that depends on
# this package.
baseType ? "uint64_t",
}:
stdenv.mkDerivation (finalAttrs: {
pname = "units-llnl";
version = "0.13.1";
src = fetchFromGitHub {
owner = "LLNL";
repo = "units";
tag = "v${finalAttrs.version}";
hash = "sha256-thJnBT+wQPF9obzXk/T6H9lvPEAH5REx3YhBXEd7n7c=";
fetchSubmodules = true;
};
nativeBuildInputs = [
cmake
];
cmakeFlags = [
(lib.cmakeBool "BUILD_SHARED_LIBS" true)
(lib.cmakeFeature "UNITS_BASE_TYPE" baseType)
];
doCheck = true;
meta = {
description = "Run-time C++ library for working with units of measurement and conversions between them and with string representations of units and measurements";
homepage = "https://github.com/llnl/units";
changelog = "https://github.com/llnl/units/blob/${finalAttrs.src.tag}/CHANGELOG.md";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ doronbehar ];
mainProgram = "units-llnl";
platforms = lib.platforms.all;
};
})