Skip to content

Commit 178a8c7

Browse files
committed
cpu_features: init at 0.9.0
1 parent 4390614 commit 178a8c7

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
lib,
3+
stdenv,
4+
fetchFromGitHub,
5+
cmake,
6+
static ? stdenv.hostPlatform.isStatic,
7+
}:
8+
9+
stdenv.mkDerivation rec {
10+
pname = "cpu_features";
11+
version = "0.9.0";
12+
13+
outputs = [
14+
"out"
15+
"dev"
16+
];
17+
18+
src = fetchFromGitHub {
19+
owner = "google";
20+
repo = "cpu_features";
21+
rev = "v${version}";
22+
hash = "sha256-uXN5crzgobNGlLpbpuOxR+9QVtZKrWhxC/UjQEakJwk=";
23+
};
24+
25+
nativeBuildInputs = [ cmake ];
26+
27+
cmakeFlags = [ "-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}" ];
28+
29+
meta = with lib; {
30+
description = "A cross platform C99 library to get cpu features at runtime";
31+
homepage = "https://github.com/google/cpu_features";
32+
license = licenses.asl20;
33+
platforms = platforms.all;
34+
maintainers = with maintainers; [ renesat ];
35+
};
36+
}

0 commit comments

Comments
 (0)