1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 gfortran,
6 gmp,
7}:
8
9stdenv.mkDerivation rec {
10 pname = "dalphaball";
11 version = "0-unstable-2023-06-15";
12
13 src = fetchFromGitHub {
14 owner = "outpace-bio";
15 repo = "DAlphaBall";
16 rev = "7b9dc05fa2a40f7ea36c6d89973d150eaed459d9";
17 hash = "sha256-mUxEL9b67z/mG+0pcM5uQ/jPAfEUpJlXOXPmqDea+U4=";
18 };
19
20 sourceRoot = "${src.name}/src";
21 strictDeps = true;
22
23 nativeBuildInputs = [
24 gfortran
25 ];
26
27 buildInputs = [
28 gfortran.cc.lib
29 gmp
30 ];
31
32 installPhase = ''
33 runHook preInstall
34 install -Dm755 DAlphaBall.gcc $out/bin/DAlphaBall
35 runHook postInstall
36 '';
37
38 meta = {
39 description = "Computes the surface area and volume of unions of many balls";
40 mainProgram = "DAlphaBall";
41 homepage = "https://github.com/outpace-bio/DAlphaBall";
42 license = lib.licenses.lgpl21Only;
43 maintainers = with lib.maintainers; [ aschleck ];
44 platforms = lib.platforms.unix;
45 };
46}