aboutsummaryrefslogtreecommitdiff
path: root/infra/libkookie/nixpkgs/pkgs/development/libraries/science/math/planarity/default.nix
blob: 7767e23934cf9695a54d07e8e09bc58a4b2c69f6 (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
29
30
31
32
33
34
35
36
37
38
39
{ stdenv
, fetchFromGitHub
, fetchpatch
, autoreconfHook
}:

stdenv.mkDerivation rec {
  pname = "planarity";
  version = "3.0.0.5";

  src = fetchFromGitHub {
    owner = "graph-algorithms";
    repo = "edge-addition-planarity-suite";
    rev = "Version_${version}";
    sha256 = "01cm7ay1njkfsdnmnvh5zwc7wg7x189hq1vbfhh9p3ihrbnmqzh8";
  };

  nativeBuildInputs = [
    autoreconfHook
  ];

  doCheck = true;

  patches = [
    # declare variables declared in headers as extern, not yet merged upstream
    (fetchpatch {
      url = "https://github.com/graph-algorithms/edge-addition-planarity-suite/pull/3.patch";
      sha256 = "1nqjc4clr326imz4jxqxcxv2hgh1sjgzll27k5cwkdin8lnmmil8";
    })
  ];

  meta = with stdenv.lib; {
    homepage = "https://github.com/graph-algorithms/edge-addition-planarity-suite";
    description = "A library for implementing graph algorithms";
    license = licenses.bsd3;
    maintainers = with maintainers; [ timokau ];
    platforms = platforms.unix;
  };
}