Skip to content

Commit

Permalink
Add/conveyorlc (#5)
Browse files Browse the repository at this point in the history
* store state of adding conveylorlc
Signed-off-by: Vanessasaurus <814322+vsoch@users.noreply.github.com>
  • Loading branch information
vsoch committed Nov 29, 2022
1 parent a4a1772 commit 82b3774
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ FROM ubuntu:22.04
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
ENV EDITOR=vim

RUN apt-get update && apt-get upgrade
RUN apt-get install --yes \
RUN apt-get update && \
apt-get install --yes \
ca-certificates \
bash-completion \
build-essential \
Expand Down
8 changes: 6 additions & 2 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,15 @@ rec {
adiak = pkgs.callPackage ./pkgs/hpc/adiak {
inherit maintainers;
};
caliper = pkgs.callPackage ./pkgs/hpc/caliper {
inherit adiak;
inherit maintainers;
};
conduit = pkgs.callPackage ./pkgs/hpc/conduit {
inherit maintainers;
};
caliper = pkgs.callPackage ./pkgs/hpc/caliper {
inherit adiak;
conveyorlc = pkgs.callPackage ./pkgs/hpc/conveyorlc {
inherit conduit;
inherit maintainers;
};
}
9 changes: 4 additions & 5 deletions pkgs/hpc/conduit/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
, withFortran? false
, pythonSupport ? true
, zfpSupport ? true
, hdf5Support ? true
, shared ? !stdenv.hostPlatform.isStatic,
...
}:
Expand Down Expand Up @@ -60,12 +59,11 @@ stdenv.mkDerivation rec {
# depends_on("hdf5", when="+hdf5")
# depends_on("hdf5~shared", when="+hdf5~shared")

nativeBuildInputs = [cmake pkgs.bash pkgs.extra-cmake-modules pkgs.tree];
nativeBuildInputs = [cmake pkgs.bash pkgs.extra-cmake-modules pkgs.tree pkgs.hdf5];
buildInputs =
lib.optional pythonSupport pkgs.python39 ++
lib.optional pythonSupport pkgs.python39Packages.numpy ++
lib.optional pythonSupport pkgs.python39Packages.mpi4py ++
lib.optional hdf5Support pkgs.hdf5 ++
lib.optional zfpSupport pkgs.zfp ++

# These shouldn't be both provided
Expand All @@ -83,8 +81,9 @@ stdenv.mkDerivation rec {
"-DBUILD_SHARED_LIBS=${onOffBool shared}"
"-DENABLE_FORTRAN=${onOffBool withFortran}"
"-DENABLE_PYTHON=${onOffBool pythonSupport}"
"-DENABLE_UTILS=OFF"
"-DENABLE_EXAMPLES=OFF"
"-DHDF5_DIR=${lib.getDev pkgs.hdf5}"
"-DENABLE_UTILS=ON"
"-DENABLE_EXAMPLES=ON"
"-DBUILD_TESTS=OFF"
"-DBUILD_DOCS=OFF"
];
Expand Down
62 changes: 62 additions & 0 deletions pkgs/hpc/conveyorlc/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{ lib, stdenv, pkgs, fetchurl, fetchFromGitHub, cmake, maintainers, conduit
, shared ? !stdenv.hostPlatform.isStatic,
...
}:

let
onOffBool = b: if b then "ON" else "OFF";
boost = pkgs.boost172.override { useMpi = true; };
in


stdenv.mkDerivation rec {
pname = "conveyorlc";
version = "1.1.0";

src = fetchFromGitHub {
owner = "XiaohuaZhangLLNL";
repo = "conveyorlc";
rev = "efb98b021edd5ef230eaff257ce2534ea01ab1ba";
sha256 = "sha256-L/pWqKFM1/68X9HPHKMBYODlDI3Jh4IVqffDGjVNCrc=";
fetchSubmodules = true;
};

nativeBuildInputs = [cmake pkgs.extra-cmake-modules];
buildInputs = [
boost
pkgs.openmpi
pkgs.openbabel2
pkgs.zlib
pkgs.hdf5-cpp
pkgs.sqlite
conduit
];

# We set the conduit paths from Nix instead
preConfigure = ''
rm cmake/FindConduit.cmake
'';

cmakeFlags = [
"-DCONDUIT_DIR=${lib.getDev conduit}"
"-DCONDUIT_FOUND=TRUE"
"-DCONDUIT_INCLUDE_DIRS=${lib.getDev conduit}/include/conduit"
"-DCONDUIT_CMAKE_CONFIG_DIR=${lib.getDev conduit}/lib/cmake/conduit"
"-DCMAKE_CXX_FLAGS=-lhdf5"
"-DHDF5_ROOT=${lib.getDev pkgs.hdf5-cpp}"
"-DOPENBABEL3_INCLUDE_DIRS=${lib.getDev pkgs.openbabel2}/include/openbabel-2.0"
];

meta = with lib; {
description = "A Parallel Virtual Screening Pipeline for Docking and MM/GSBA";
longDescription = ''
An open source project from Lawrence Livermore National
Laboratory that provides a parallel virtual screening pipeline
for docking and MM/GSBA
'';
homepage = "https://github.com/XiaohuaZhangLLNL/conveyorlc";
license = licenses.gpl3;
maintainers = [ maintainers.vsoch ];
platforms = platforms.linux;
};
}

0 comments on commit 82b3774

Please sign in to comment.