mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-20 19:16:11 +00:00
lwan: no jemalloc w/musl
This commit is contained in:
parent
0341e3d535
commit
5ca306875c
@ -1,4 +1,4 @@
|
||||
{ lib, stdenv, fetchFromGitHub, pkg-config, zlib, cmake, jemalloc }:
|
||||
{ lib, stdenv, fetchFromGitHub, pkg-config, zlib, cmake, enableJemalloc ? !stdenv.hostPlatform.isMusl, jemalloc }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "lwan";
|
||||
@ -13,10 +13,10 @@ stdenv.mkDerivation rec {
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
|
||||
buildInputs = [ jemalloc zlib ];
|
||||
buildInputs = [ zlib ] ++ lib.optional enableJemalloc jemalloc;
|
||||
|
||||
# Note: tcmalloc and mimalloc are also supported (and normal malloc)
|
||||
cmakeFlags = [ "-DUSE_ALTERNATIVE_MALLOC=jemalloc" ];
|
||||
cmakeFlags = lib.optional enableJemalloc "-DUSE_ALTERNATIVE_MALLOC=jemalloc";
|
||||
|
||||
meta = with lib; {
|
||||
description = "Lightweight high-performance multi-threaded web server";
|
||||
|
Loading…
Reference in New Issue
Block a user