summary refs log tree commit diff
path: root/pkgs/rpi-fbcp.nix
blob: 4de2ea6fd8a59ecd158784ac7604ce41aea21163 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{ stdenv, fetchFromGitHub, cmake, libraspberrypi, ... }:

let
  rev = "af8d32246c23cb23e4030e6588668a14341f5ddc";
in
stdenv.mkDerivation {
  pname = "rpi-fbcp";
  version = "unstable-${rev}";

  src = fetchFromGitHub {
    inherit rev;
    owner = "tasanakorn";
    repo = "rpi-fbcp";
    hash = "sha256-herbC+rh7A8VBjuQjnCI3v4J1zN+PcxjqZ3FyaSonoM=";
  };

  nativeBuildInputs = [ cmake ];
  buildInputs = [ libraspberrypi ];

  installPhase = ''
    runHook preInstall

    mkdir -p $out/bin
    cp ./fbcp $out/bin/fbcp

    runHook postInstall
  '';
}