mstore: build with meson

This commit is contained in:
Nick Cao 2024-03-26 15:57:06 -04:00
parent 14e08254a2
commit 99da45c20f
No known key found for this signature in database
1 changed files with 6 additions and 9 deletions

View File

@ -1,8 +1,11 @@
{ stdenv
, lib
, fetchFromGitHub
, cmake
, gfortran
, meson
, ninja
, pkg-config
, python3
, mctc-lib
}:
@ -17,22 +20,16 @@ stdenv.mkDerivation rec {
hash = "sha256-dN2BulLS/ENRFVdJIrZRxgBV8S4d5+7BjTCGnhBbf4I=";
};
nativeBuildInputs = [ cmake gfortran ];
nativeBuildInputs = [ gfortran meson ninja pkg-config python3 ];
buildInputs = [ mctc-lib ];
outputs = [ "out" "dev" ];
# Fix the Pkg-Config files for doubled store paths
postPatch = ''
substituteInPlace config/template.pc \
--replace "\''${prefix}/" ""
patchShebangs --build config/install-mod.py
'';
cmakeFlags = [
"-DBUILD_SHARED_LIBS=${if stdenv.hostPlatform.isStatic then "OFF" else "ON"}"
];
meta = with lib; {
description = "Molecular structure store for testing";
license = licenses.asl20;