Skip to content

Commit 65e2049

Browse files
nanobench: init at 4.3.11 (#374269)
2 parents e7d8d2c + e356d31 commit 65e2049

2 files changed

Lines changed: 60 additions & 0 deletions

File tree

maintainers/maintainer-list.nix

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15750,6 +15750,13 @@
1575015750
githubId = 2176611;
1575115751
name = "Marko Poikonen";
1575215752
};
15753+
mtpham99 = {
15754+
name = "Matthew Pham";
15755+
email = "mtpham.nixos@protonmail.com";
15756+
github = "mtpham99";
15757+
githubId = 72663763;
15758+
keys = [ { fingerprint = "DB3E A12D B291 594A 79C5 F6B3 10AB 6868 37F6 FA3F"; } ];
15759+
};
1575315760
mtreca = {
1575415761
email = "maxime.treca@gmail.com";
1575515762
github = "mtreca";
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
{
2+
lib,
3+
stdenv,
4+
fetchFromGitHub,
5+
fetchpatch,
6+
cmake,
7+
nix-update-script,
8+
}:
9+
10+
stdenv.mkDerivation rec {
11+
pname = "nanobench";
12+
version = "4.3.11";
13+
14+
src = fetchFromGitHub {
15+
owner = "martinus";
16+
repo = "nanobench";
17+
tag = "v${version}";
18+
hash = "sha256-6OoVU31cNY0pIYpK/PdB9Qej+9IJo7+fHFQCTymBVrk=";
19+
};
20+
21+
patches = [
22+
# Missing header from a test file. Required for compiling as of gcc13. Patched in commit from master branch.
23+
# Remove on next release.
24+
(fetchpatch {
25+
url = "https://github.com/martinus/nanobench/commit/e4327893194f06928012eb81cabc606c4e4791ac.patch";
26+
hash = "sha256-vmpohg9TbIxT+p4JerWh/QBcZ3/+1gPSNf15sqW6leM=";
27+
})
28+
29+
# Change cmake install directories to conventional locations. Patches from unmerged pull request.
30+
# Remove when merged upstream.
31+
(fetchpatch {
32+
url = "https://github.com/martinus/nanobench/pull/98/commits/92c6995ccaebbda87fed13de8eaf3d135d1af0c0.patch";
33+
hash = "sha256-JwCpwSRzV1qnwwcJIGEJWxthT4Vj12TXhAGG0bc8KGM=";
34+
})
35+
(fetchpatch {
36+
url = "https://github.com/martinus/nanobench/pull/98/commits/17a1f0b598a09d399dd492c72bca5b48ad76c794.patch";
37+
hash = "sha256-2lOD63qN7gywUQxrdSRVyddpzcQjjeWOrA3hqu7x+CY=";
38+
})
39+
];
40+
41+
nativeBuildInputs = [ cmake ];
42+
43+
passthru.updateScript = nix-update-script { };
44+
45+
meta = {
46+
description = "Simple, fast, accurate single-header microbenchmarking functionality for C++11/14/17/20";
47+
homepage = "https://nanobench.ankerl.com/";
48+
changelog = "https://github.com/martinus/nanobench/releases/tag/v${version}";
49+
platforms = lib.platforms.all;
50+
license = lib.licenses.mit;
51+
maintainers = with lib.maintainers; [ mtpham99 ];
52+
};
53+
}

0 commit comments

Comments
 (0)