1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 cmake,
6 pkg-config,
7 heatshrink,
8 zlib,
9 boost,
10 catch2_3,
11}:
12stdenv.mkDerivation {
13 pname = "libbgcode";
14 version = "0-unstable-2025-02-19";
15
16 src = fetchFromGitHub {
17 owner = "prusa3d";
18 repo = "libbgcode";
19 rev = "5041c093b33e2748e76d6b326f2251310823f3df";
20 hash = "sha256-EaxVZerH2v8b1Yqk+RW/r3BvnJvrAelkKf8Bd+EHbEc=";
21 };
22
23 nativeBuildInputs = [
24 cmake
25 pkg-config
26 ];
27
28 buildInputs = [
29 heatshrink
30 zlib
31 boost
32 catch2_3
33 ];
34
35 meta = with lib; {
36 homepage = "https://github.com/prusa3d/libbgcode";
37 description = "Prusa Block & Binary G-code reader / writer / converter";
38 mainProgram = "bgcode";
39 license = licenses.agpl3Only;
40 maintainers = with maintainers; [ lach ];
41 platforms = platforms.unix;
42 };
43}