All of lore.kernel.org
 help / color / mirror / Atom feed
From: thomas@devoogdt.com
To: buildroot@buildroot.org
Cc: Thomas Devoogdt <thomas@devoogdt.com>,
	Thomas Devoogdt <thomas.devoogdt@gmail.com>
Subject: [Buildroot] [PATCH v2 3/3] package/fluent-bit: fix builds on s390x architectures
Date: Sat, 11 Feb 2023 19:25:45 +0100	[thread overview]
Message-ID: <20230211182546.633728-3-thomas@devoogdt.com> (raw)
In-Reply-To: <20230211182546.633728-1-thomas@devoogdt.com>

From: Thomas Devoogdt <thomas.devoogdt@gmail.com>

Fixes:
 - http://autobuild.buildroot.net/results/856fd250f75a696694c70e3208ffcef7470a7082
 - http://autobuild.buildroot.net/results/dceb413fb5d459338417d8dd5a42d95aa23e849b

Signed-off-by: Thomas Devoogdt <thomas.devoogdt@gmail.com>
---
  v2: new patch in this serie

 package/fluent-bit/fluent-bit.mk | 19 ++++++++++++++-----
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/package/fluent-bit/fluent-bit.mk b/package/fluent-bit/fluent-bit.mk
index 4ecf813511..d618fdf1e2 100644
--- a/package/fluent-bit/fluent-bit.mk
+++ b/package/fluent-bit/fluent-bit.mk
@@ -12,6 +12,9 @@ FLUENT_BIT_CPE_ID_VENDOR = treasuredata
 FLUENT_BIT_CPE_ID_PRODUCT = fluent_bit
 FLUENT_BIT_DEPENDENCIES = host-bison host-flex libyaml openssl
 
+FLUENT_BIT_CFLAGS = $(TARGET_CFLAGS)
+FLUENT_BIT_CXXFLAGS = $(TARGET_CXXFLAGS)
+
 FLUENT_BIT_CONF_OPTS += \
 	-DFLB_DEBUG=No \
 	-DFLB_RELEASE=Yes \
@@ -42,12 +45,16 @@ FLUENT_BIT_CONF_OPTS += \
 FLUENT_BIT_CONF_OPTS += \
 	-DCMAKE_INSTALL_SYSCONFDIR="/etc/"
 
+# Fix multiple definition of `mk_tls_*'.
+# https://github.com/fluent/fluent-bit/issues/5537
+FLUENT_BIT_CFLAGS += -fcommon
+FLUENT_BIT_CXXFLAGS += -fcommon
+
 # Undefining _FILE_OFFSET_BITS here because of a "bug" with glibc fts.h
 # large file support.
-# See https://bugzilla.redhat.com/show_bug.cgi?id=574992 for more information.
-FLUENT_BIT_CONF_OPTS += \
-	-DCMAKE_C_FLAGS="$(TARGET_CFLAGS) -U_FILE_OFFSET_BITS" \
-	-DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -U_FILE_OFFSET_BITS"
+# https://bugzilla.redhat.com/show_bug.cgi?id=574992
+FLUENT_BIT_CFLAGS += -U_FILE_OFFSET_BITS
+FLUENT_BIT_CXXFLAGS += -U_FILE_OFFSET_BITS
 
 ifeq ($(BR2_TOOLCHAIN_USES_GLIBC),)
 FLUENT_BIT_DEPENDENCIES += musl-fts
@@ -60,7 +67,9 @@ FLUENT_BIT_LDFLAGS += -latomic
 endif
 
 FLUENT_BIT_CONF_OPTS += \
-	-DCMAKE_EXE_LINKER_FLAGS="$(FLUENT_BIT_LDFLAGS)"
+	-DCMAKE_EXE_LINKER_FLAGS="$(FLUENT_BIT_LDFLAGS)" \
+	-DCMAKE_C_FLAGS="$(FLUENT_BIT_CFLAGS)" \
+	-DCMAKE_CXX_FLAGS="$(FLUENT_BIT_CXXFLAGS)"
 
 define FLUENT_BIT_INSTALL_INIT_SYSV
 	$(INSTALL) -D -m 0755 package/fluent-bit/S99fluent-bit \
-- 
2.34.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

  parent reply	other threads:[~2023-02-11 18:26 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-11 18:25 [Buildroot] [PATCH v2 1/3] package/fluent-bit: bump to version 2.0.9 thomas
2023-02-11 18:25 ` [Buildroot] [PATCH v2 2/3] package/fluent-bit: add support for non glibc toolchain thomas
2023-02-15  9:21   ` Peter Korsgaard
2023-02-15 11:41     ` Thomas Devoogdt
2023-02-15 12:52       ` Peter Korsgaard
2023-02-11 18:25 ` thomas [this message]
2023-02-15  9:22   ` [Buildroot] [PATCH v2 3/3] package/fluent-bit: fix builds on s390x architectures Peter Korsgaard
2023-02-15  9:19 ` [Buildroot] [PATCH v2 1/3] package/fluent-bit: bump to version 2.0.9 Peter Korsgaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230211182546.633728-3-thomas@devoogdt.com \
    --to=thomas@devoogdt.com \
    --cc=buildroot@buildroot.org \
    --cc=thomas.devoogdt@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.