From 1b3b41288caf7b6c928c46b7b48d4e3e24e607b6 Mon Sep 17 00:00:00 2001 From: VZstless Date: Mon, 16 Mar 2026 17:58:18 +0800 Subject: [PATCH] snmalloc: init at 0.7.4 --- pkgs/by-name/sn/snmalloc/package.nix | 42 ++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 pkgs/by-name/sn/snmalloc/package.nix diff --git a/pkgs/by-name/sn/snmalloc/package.nix b/pkgs/by-name/sn/snmalloc/package.nix new file mode 100644 index 000000000000..aaf7544b655b --- /dev/null +++ b/pkgs/by-name/sn/snmalloc/package.nix @@ -0,0 +1,42 @@ +{ + lib, + stdenv, + clangStdenv, + fetchFromGitHub, + cmake, + nix-update-script, +}: + +clangStdenv.mkDerivation (finalAttrs: { + pname = "snmalloc"; + version = "0.7.4"; + src = fetchFromGitHub { + owner = "microsoft"; + repo = "snmalloc"; + tag = finalAttrs.version; + hash = "sha256-+UCqUrfvhnB4leiYCnGJ8ORfVkTaGimaErP56XCJ5PM="; + }; + + outputs = [ + "out" + "dev" + ]; + + strictDeps = true; + __structuredAttrs = true; + + nativeBuildInputs = [ + cmake + ]; + + passthru.updateScript = nix-update-script { }; + + meta = { + description = "Message passing based memory allocator"; + homepage = "https://github.com/microsoft/snmalloc"; + downloadPage = "https://github.com/microsoft/snmalloc/releases"; + changelog = "https://github.com/microsoft/snmalloc/releases/tag/${finalAttrs.src.tag}"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ VZstless ]; + }; +})