simple-dftd3: enable shared builds on !isStatic platforms

This commit is contained in:
Phillip Seeber 2024-01-11 17:28:38 +01:00
parent a3f4b8c7da
commit 6631798926

View File

@ -26,10 +26,16 @@ stdenv.mkDerivation rec {
buildInputs = [ mctc-lib mstore toml-f blas ];
postInstall = ''
substituteInPlace $out/lib/pkgconfig/s-dftd3.pc \
--replace "''${prefix}/" ""
outputs = [ "out" "dev" ];
# Fix the Pkg-Config files for doubled store paths
postPatch = ''
substituteInPlace config/template.pc \
--replace "\''${prefix}/" ""
'';
cmakeFlags = [
"-DBUILD_SHARED_LIBS=${if stdenv.hostPlatform.isStatic then "OFF" else "ON"}"
];
doCheck = true;
preCheck = ''