double-conversion: Allow static linking (#322738)

This commit is contained in:
Artturin 2024-09-12 02:49:56 +03:00 committed by GitHub
commit bcd43fb105
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,4 +1,4 @@
{ stdenv, lib, fetchFromGitHub, cmake }:
{ stdenv, lib, fetchFromGitHub, cmake, enableStatic ? stdenv.hostPlatform.isStatic }:
stdenv.mkDerivation rec {
pname = "double-conversion";
@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake ];
cmakeFlags = [ "-DBUILD_SHARED_LIBS=ON" ];
cmakeFlags = lib.optional (! enableStatic) "-DBUILD_SHARED_LIBS=ON";
# Case sensitivity issue
preConfigure = lib.optionalString stdenv.isDarwin ''