-
-
Notifications
You must be signed in to change notification settings - Fork 14.5k
/
default.nix
35 lines (27 loc) · 910 Bytes
/
default.nix
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
{ stdenv, fetchFromGitHub, cmake, bpp-core, bpp-seq }:
stdenv.mkDerivation rec {
pname = "bpp-popgen";
inherit (bpp-core) version;
src = fetchFromGitHub {
owner = "BioPP";
repo = pname;
rev = "v${version}";
sha256 = "0bz0fhrq3dri6a0hvfc3zlvrns8mrzzlnicw5pyfa812gc1qwfvh";
};
nativeBuildInputs = [ cmake ];
buildInputs = [ bpp-core bpp-seq ];
preCheck = ''
export LD_LIBRARY_PATH=$(pwd)/src
'';
postFixup = ''
substituteInPlace $out/lib/cmake/${pname}/${pname}-targets.cmake \
--replace 'set(_IMPORT_PREFIX' '#set(_IMPORT_PREFIX'
'';
# prevents cmake from exporting incorrect INTERFACE_INCLUDE_DIRECTORIES
# of form /nix/store/.../nix/store/.../include,
# probably due to relative vs absolute path issue
doCheck = !stdenv.isDarwin;
meta = bpp-core.meta // {
changelog = "https://github.com/BioPP/bpp-popgen/blob/master/ChangeLog";
};
}