about summary refs log tree commit diff
path: root/pkgs/by-name/ac/acc/package.nix
blob: a74227284a900b888859d26a987be7989f707a5f (plain) (blame)
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
29
30
31
32
33
34
35
36
37
38
39
40
{ lib
, stdenv
, fetchFromGitHub
, cmake
}:
stdenv.mkDerivation (finalAttrs: {
  pname = "acc";
  version = "1.60";

  src = fetchFromGitHub {
    owner = "zdoom";
    repo = "acc";
    rev = finalAttrs.version;
    hash = "sha256-HGF4O4LcMDY4f/ZuBbkvx5Wd86+8Ict624eKTJ88/rQ=";
  };

  patches = [
    # Don't force static builds
    ./disable-static.patch
  ];

  nativeBuildInputs = [ cmake ];

  installPhase = ''
    runHook preInstall

    install -D acc $out/bin/acc

    runHook postInstall
  '';

  meta = with lib; {
    description = "ACS script compiler for use with ZDoom and Hexen";
    homepage = "https://zdoom.org/wiki/ACC";
    license = licenses.activision;
    maintainers = with maintainers; [ emilytrau ];
    platforms = platforms.all;
    mainProgram = "acc";
  };
})