File: default.nix

package info (click to toggle)
aac-tactics 8.8.0+1.gbp069dc3b-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 384 kB
  • sloc: ml: 2,941; makefile: 39
file content (28 lines) | stat: -rw-r--r-- 713 bytes parent folder | download
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
{ pkgs ? (import <nixpkgs> {}), coq-version-or-url, shell ? false }:

let
  coq-version-parts = builtins.match "([0-9]+).([0-9]+)" coq-version-or-url;
  coqPackages =
    if coq-version-parts == null then
      pkgs.mkCoqPackages (import (fetchTarball coq-version-or-url) {})
    else
      pkgs."coqPackages_${builtins.concatStringsSep "_" coq-version-parts}";
in

with coqPackages;

pkgs.stdenv.mkDerivation {

  name = "aac-tactics";

  buildInputs = with coq.ocamlPackages; [ ocaml findlib camlp5 ]
    ++ pkgs.lib.optionals shell [ merlin ocp-indent ocp-index ];

  propagatedBuildInputs = [
    coq
  ];

  src = if shell then null else ./.;

  installFlags = "COQLIB=$(out)/lib/coq/${coq.coq-version}/";
}