Merge pull request #177147 from trofi/workaround-fno-common-for-fluent-bit
fluent-bit: add -fcommon workaround
This commit is contained in:
commit
881810d9b3
|
@ -19,7 +19,13 @@ stdenv.mkDerivation rec {
|
|||
cmakeFlags = [ "-DFLB_METRICS=ON" "-DFLB_HTTP_SERVER=ON" ];
|
||||
|
||||
# _FORTIFY_SOURCE requires compiling with optimization (-O)
|
||||
NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isGNU "-O";
|
||||
NIX_CFLAGS_COMPILE = lib.optionals stdenv.cc.isGNU [ "-O" ]
|
||||
# Workaround build failure on -fno-common toolchains:
|
||||
# ld: /monkey/mk_tls.h:81: multiple definition of `mk_tls_server_timeout';
|
||||
# flb_config.c.o:include/monkey/mk_tls.h:81: first defined here
|
||||
# TODO: drop when upstream gets a fix for it:
|
||||
# https://github.com/fluent/fluent-bit/issues/5537
|
||||
++ lib.optionals stdenv.isDarwin [ "-fcommon" ];
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
|
||||
|
|
Loading…
Reference in a new issue