depot/third_party/nixpkgs/pkgs/development/libraries/precice/default.nix
Default email 1693fb2285 Project import generated by Copybara.
GitOrigin-RevId: 420f89ceb267b461eed5d025b6c3c0e57703cc5c
2020-10-07 11:15:18 +02:00

36 lines
1 KiB
Nix

{ lib, stdenv, fetchFromGitHub, cmake, gcc, boost, eigen, libxml2, openmpi, python3, petsc }:
stdenv.mkDerivation rec {
pname = "precice";
version = "2.1.0";
src = fetchFromGitHub {
owner = "precice";
repo = pname;
rev = "v${version}";
sha256 = "1268dz39sx3gygnm7vpg59k1wdhy6rhf72i8i0kz4jckll0s9102";
};
cmakeFlags = [
"-DPRECICE_PETScMapping=OFF"
"-DBUILD_SHARED_LIBS=ON"
"-DPYTHON_LIBRARIES=${python3.libPrefix}"
"-DPYTHON_INCLUDE_DIR=${python3}/include/${python3.libPrefix}m"
];
NIX_CFLAGS_COMPILE = lib.optional stdenv.isDarwin [ "-D_GNU_SOURCE" ];
nativeBuildInputs = [ cmake gcc ];
buildInputs = [ boost eigen libxml2 openmpi python3 python3.pkgs.numpy ];
enableParallelBuilding = true;
meta = {
description = "preCICE stands for Precise Code Interaction Coupling Environment";
license = with lib.licenses; [ gpl3 ];
homepage = "https://www.precice.org/";
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ Scriptkiddi ];
};
}