Skip to content

Commit 7d5d4d6

Browse files
committed
lib45d: init at 0.3.6
1 parent 93f86b0 commit 7d5d4d6

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

pkgs/by-name/li/lib45d/package.nix

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
stdenv,
3+
fetchFromGitHub,
4+
fetchpatch,
5+
lib,
6+
}:
7+
stdenv.mkDerivation (finalAttrs: {
8+
name = "lib45d";
9+
version = "0.3.6";
10+
src = fetchFromGitHub {
11+
owner = "45Drives";
12+
repo = "lib45d";
13+
tag = "v${finalAttrs.version}";
14+
hash = "sha256-42xB30Iu2WxNrBxomVBKd/uyIRt27y/Y1ah5mckOrc0=";
15+
};
16+
17+
patches = [
18+
# https://github.com/45Drives/lib45d/issues/3
19+
# fix "error: 'uintmax_t' has not been declared" build failure until next release
20+
(fetchpatch {
21+
url = "https://github.com/45Drives/lib45d/commit/a607e278182a3184c004c45c215aa22c15d6941d.patch";
22+
hash = "sha256-sMAvOp4EjBXGHa9PGuuEqJvpEvUlMuzRKCfq9oqQLgY=";
23+
})
24+
];
25+
26+
installPhase = ''
27+
runHook preInstall
28+
29+
install -Dm755 -t $out/lib dist/shared/lib45d.so
30+
31+
mkdir -p $out/include/45d
32+
cp -f -r src/incl/45d/* $out/include/45d/
33+
34+
runHook postInstall
35+
'';
36+
37+
meta = {
38+
homepage = "https://github.com/45Drives/lib45d";
39+
description = "45Drives C++ Library";
40+
license = lib.licenses.gpl3;
41+
maintainers = with lib.maintainers; [ philipwilk ];
42+
platforms = lib.platforms.linux;
43+
};
44+
})

0 commit comments

Comments
 (0)