1{
2 lib,
3 rustPlatform,
4 fetchFromGitHub,
5 llvmPackages_13,
6 libxml2,
7 ncurses,
8 zlib,
9 stdenv,
10}:
11
12rustPlatform.buildRustPackage rec {
13 pname = "bfc";
14 version = "1.12.0";
15
16 src = fetchFromGitHub {
17 owner = "Wilfred";
18 repo = "bfc";
19 rev = version;
20 hash = "sha256-5pcvwCtXWEexvV3TS62dZ6Opg8ANP2L8B0Z8u/OQENU=";
21 };
22
23 cargoHash = "sha256-S8Fy0PRSUftljcX34Sj8MmlPW7Oob2yayPUA1RRxf8E=";
24
25 buildInputs = [
26 libxml2
27 ncurses
28 zlib
29 ];
30
31 env.LLVM_SYS_130_PREFIX = llvmPackages_13.llvm.dev;
32
33 # process didn't exit successfully: <...> SIGSEGV
34 doCheck = false;
35
36 meta = with lib; {
37 description = "Industrial-grade brainfuck compiler";
38 mainProgram = "bfc";
39 homepage = "https://bfc.wilfred.me.uk";
40 license = licenses.gpl2Plus;
41 maintainers = with maintainers; [ figsoda ];
42 broken = stdenv.hostPlatform.isAarch64 && stdenv.hostPlatform.isLinux;
43 };
44}