Merge pull request #54512 from vcunat/p/jemalloc-stripPrefix

jemalloc nitpick: better semantics for stripPrefix
This commit is contained in:
Silvan Mosberger 2019-01-24 00:19:32 +01:00 committed by GitHub
commit 328b0e4933
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,8 +4,8 @@
# then stops downstream builds (mariadb in particular) from detecting it. This
# option should remove the prefix and give us a working jemalloc.
# Causes segfaults with some software (ex. rustc), but defaults to true for backward
# compatibility. Ignored on non OSX.
, stripPrefix ? true
# compatibility.
, stripPrefix ? stdenv.hostPlatform.isDarwin
, disableInitExecTls ? false
}:
@ -22,8 +22,8 @@ stdenv.mkDerivation rec {
# see the comment on stripPrefix
configureFlags = []
++ optional (stdenv.isDarwin && stripPrefix) [ "--with-jemalloc-prefix=" ]
++ optional disableInitExecTls [ "--disable-initial-exec-tls" ]
++ optional stripPrefix "--with-jemalloc-prefix="
++ optional disableInitExecTls "--disable-initial-exec-tls"
;
doCheck = true;