diff options
| author | Khem Raj <raj.khem@gmail.com> | 2025-05-02 17:05:28 -0700 |
|---|---|---|
| committer | Khem Raj <raj.khem@gmail.com> | 2025-05-04 23:18:20 -0700 |
| commit | 2464c020bb95df0511690302e4058f1d538c75fa (patch) | |
| tree | b952e9f68c994d4f99ced15bd4ad08f1a9f73a3b | |
| parent | 5cac401d00bfdf0b243bcca247b4dd691fe4aa43 (diff) | |
| download | meta-openembedded-2464c020bb95df0511690302e4058f1d538c75fa.tar.gz | |
fluent-bit: Upgrade to 4.0.1 release
Refresh and forward port patches
Add -std=gnu17 to fix build with GCC-15
Signed-off-by: Khem Raj <raj.khem@gmail.com>
| -rw-r--r-- | meta-oe/recipes-extended/fluentbit/fluentbit/0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch | 16 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch | 2 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/fluentbit/fluentbit/0003-CMakeLists.txt-Revise-init-manager-deduction.patch | 18 | ||||
| -rw-r--r-- | meta-oe/recipes-extended/fluentbit/fluentbit_4.0.1.bb (renamed from meta-oe/recipes-extended/fluentbit/fluentbit_3.2.8.bb) | 23 |
4 files changed, 26 insertions, 33 deletions
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch index fae98f1f5d..32f4fdec51 100644 --- a/meta-oe/recipes-extended/fluentbit/fluentbit/0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch +++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch | |||
| @@ -28,8 +28,6 @@ Upstream-Status: Submitted [https://github.com/fluent/fluent-bit/pull/9450] | |||
| 28 | lib/monkey/CMakeLists.txt | 4 +--- | 28 | lib/monkey/CMakeLists.txt | 4 +--- |
| 29 | 4 files changed, 7 insertions(+), 21 deletions(-) | 29 | 4 files changed, 7 insertions(+), 21 deletions(-) |
| 30 | 30 | ||
| 31 | diff --git a/lib/cfl/CMakeLists.txt b/lib/cfl/CMakeLists.txt | ||
| 32 | index 2193cb29c..e2a5cba37 100644 | ||
| 33 | --- a/lib/cfl/CMakeLists.txt | 31 | --- a/lib/cfl/CMakeLists.txt |
| 34 | +++ b/lib/cfl/CMakeLists.txt | 32 | +++ b/lib/cfl/CMakeLists.txt |
| 35 | @@ -40,12 +40,8 @@ if(NOT MSVC) | 33 | @@ -40,12 +40,8 @@ if(NOT MSVC) |
| @@ -47,8 +45,6 @@ index 2193cb29c..e2a5cba37 100644 | |||
| 47 | 45 | ||
| 48 | 46 | ||
| 49 | 47 | ||
| 50 | diff --git a/lib/cmetrics/CMakeLists.txt b/lib/cmetrics/CMakeLists.txt | ||
| 51 | index 18582997d..8f7176dd6 100644 | ||
| 52 | --- a/lib/cmetrics/CMakeLists.txt | 48 | --- a/lib/cmetrics/CMakeLists.txt |
| 53 | +++ b/lib/cmetrics/CMakeLists.txt | 49 | +++ b/lib/cmetrics/CMakeLists.txt |
| 54 | @@ -60,12 +60,8 @@ if(NOT MSVC) | 50 | @@ -60,12 +60,8 @@ if(NOT MSVC) |
| @@ -66,12 +62,10 @@ index 18582997d..8f7176dd6 100644 | |||
| 66 | 62 | ||
| 67 | # Configuration options | 63 | # Configuration options |
| 68 | option(CMT_DEV "Enable development mode" No) | 64 | option(CMT_DEV "Enable development mode" No) |
| 69 | diff --git a/lib/ctraces/CMakeLists.txt b/lib/ctraces/CMakeLists.txt | ||
| 70 | index e47ba022d..0ddfd5f97 100644 | ||
| 71 | --- a/lib/ctraces/CMakeLists.txt | 65 | --- a/lib/ctraces/CMakeLists.txt |
| 72 | +++ b/lib/ctraces/CMakeLists.txt | 66 | +++ b/lib/ctraces/CMakeLists.txt |
| 73 | @@ -30,12 +30,8 @@ set(CTR_VERSION_MINOR 6) | 67 | @@ -30,12 +30,8 @@ set(CTR_VERSION_MINOR 6) |
| 74 | set(CTR_VERSION_PATCH 0) | 68 | set(CTR_VERSION_PATCH 4) |
| 75 | set(CTR_VERSION_STR "${CTR_VERSION_MAJOR}.${CTR_VERSION_MINOR}.${CTR_VERSION_PATCH}") | 69 | set(CTR_VERSION_STR "${CTR_VERSION_MAJOR}.${CTR_VERSION_MINOR}.${CTR_VERSION_PATCH}") |
| 76 | 70 | ||
| 77 | -# Define __FILENAME__ consistently across Operating Systems | 71 | -# Define __FILENAME__ consistently across Operating Systems |
| @@ -85,8 +79,6 @@ index e47ba022d..0ddfd5f97 100644 | |||
| 85 | 79 | ||
| 86 | # Configuration options | 80 | # Configuration options |
| 87 | option(CTR_DEV "Enable development mode" No) | 81 | option(CTR_DEV "Enable development mode" No) |
| 88 | diff --git a/lib/monkey/CMakeLists.txt b/lib/monkey/CMakeLists.txt | ||
| 89 | index 028240bcc..b386cb726 100644 | ||
| 90 | --- a/lib/monkey/CMakeLists.txt | 82 | --- a/lib/monkey/CMakeLists.txt |
| 91 | +++ b/lib/monkey/CMakeLists.txt | 83 | +++ b/lib/monkey/CMakeLists.txt |
| 92 | @@ -15,10 +15,8 @@ include(GNUInstallDirs) | 84 | @@ -15,10 +15,8 @@ include(GNUInstallDirs) |
| @@ -95,9 +87,9 @@ index 028240bcc..b386cb726 100644 | |||
| 95 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -Wall -Wextra") | 87 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -Wall -Wextra") |
| 96 | -set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$$(subst ${CMAKE_SOURCE_DIR}/,,$$(abspath \$$<))\"'") | 88 | -set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__='\"$$(subst ${CMAKE_SOURCE_DIR}/,,$$(abspath \$$<))\"'") |
| 97 | -else() | 89 | -else() |
| 98 | +endif() | 90 | -set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__") |
| 99 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__") | 91 | endif() |
| 100 | -endif() | 92 | +set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__FILENAME__=__FILE__") |
| 101 | 93 | ||
| 102 | # Monkey Version | 94 | # Monkey Version |
| 103 | set(MK_VERSION_MAJOR 1) | 95 | set(MK_VERSION_MAJOR 1) |
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch index 01a11e3be7..025f8729ea 100644 --- a/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch +++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch | |||
| @@ -13,8 +13,6 @@ Upstream-Status: Pending | |||
| 13 | include/fluent-bit/flb_info.h.in | 2 +- | 13 | include/fluent-bit/flb_info.h.in | 2 +- |
| 14 | 1 file changed, 1 insertion(+), 1 deletion(-) | 14 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 15 | 15 | ||
| 16 | diff --git a/include/fluent-bit/flb_info.h.in b/include/fluent-bit/flb_info.h.in | ||
| 17 | index 3a08f8051..aa6a48f29 100644 | ||
| 18 | --- a/include/fluent-bit/flb_info.h.in | 16 | --- a/include/fluent-bit/flb_info.h.in |
| 19 | +++ b/include/fluent-bit/flb_info.h.in | 17 | +++ b/include/fluent-bit/flb_info.h.in |
| 20 | @@ -23,7 +23,7 @@ | 18 | @@ -23,7 +23,7 @@ |
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit/0003-CMakeLists.txt-Revise-init-manager-deduction.patch b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-CMakeLists.txt-Revise-init-manager-deduction.patch index 8dd4da47ec..909d1be28d 100644 --- a/meta-oe/recipes-extended/fluentbit/fluentbit/0003-CMakeLists.txt-Revise-init-manager-deduction.patch +++ b/meta-oe/recipes-extended/fluentbit/fluentbit/0003-CMakeLists.txt-Revise-init-manager-deduction.patch | |||
| @@ -14,23 +14,21 @@ Upstream-Status: Inappropriate [configuration] | |||
| 14 | src/CMakeLists.txt | 4 ++-- | 14 | src/CMakeLists.txt | 4 ++-- |
| 15 | 1 file changed, 2 insertions(+), 2 deletions(-) | 15 | 1 file changed, 2 insertions(+), 2 deletions(-) |
| 16 | 16 | ||
| 17 | diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt | ||
| 18 | index 8404b65c1..0c7876058 100644 | ||
| 19 | --- a/src/CMakeLists.txt | 17 | --- a/src/CMakeLists.txt |
| 20 | +++ b/src/CMakeLists.txt | 18 | +++ b/src/CMakeLists.txt |
| 21 | @@ -546,7 +546,7 @@ if(FLB_BINARY) | 19 | @@ -569,7 +569,7 @@ if(FLB_BINARY) |
| 22 | set(SYSTEMD_UNITDIR /lib/systemd/system) | 20 | set(SYSTEMD_UNITDIR /lib/systemd/system) |
| 23 | endif() | 21 | endif() |
| 24 | 22 | ||
| 25 | - if(SYSTEMD_UNITDIR) | 23 | - if(SYSTEMD_UNITDIR) |
| 26 | + if(@INIT_MANAGER_IS_SYSTEMD@) | 24 | + if(@INIT_MANAGER_IS_SYSTEMD@) |
| 27 | set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service") | 25 | if (FLB_AMAZON_LINUX2) |
| 28 | configure_file( | 26 | set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service") |
| 29 | "${PROJECT_SOURCE_DIR}/init/systemd.in" | 27 | configure_file( |
| 30 | @@ -554,7 +554,7 @@ if(FLB_BINARY) | 28 | @@ -594,7 +594,7 @@ if(FLB_BINARY) |
| 31 | ) | 29 | install(FILES ${FLB_SYSTEMD_SCRIPT} COMPONENT binary DESTINATION ${SYSTEMD_UNITDIR}) |
| 32 | install(FILES ${FLB_SYSTEMD_SCRIPT} COMPONENT binary DESTINATION ${SYSTEMD_UNITDIR}) | 30 | install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR} COMPONENT binary) |
| 33 | install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR} COMPONENT binary) | 31 | endif() |
| 34 | - elseif(IS_DIRECTORY /usr/share/upstart) | 32 | - elseif(IS_DIRECTORY /usr/share/upstart) |
| 35 | + elseif(@INIT_MANAGER_IS_UPSTART@) | 33 | + elseif(@INIT_MANAGER_IS_UPSTART@) |
| 36 | set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf") | 34 | set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf") |
diff --git a/meta-oe/recipes-extended/fluentbit/fluentbit_3.2.8.bb b/meta-oe/recipes-extended/fluentbit/fluentbit_4.0.1.bb index 59e23567b1..4d82abc783 100644 --- a/meta-oe/recipes-extended/fluentbit/fluentbit_3.2.8.bb +++ b/meta-oe/recipes-extended/fluentbit/fluentbit_4.0.1.bb | |||
| @@ -17,9 +17,9 @@ DEPENDS = "\ | |||
| 17 | " | 17 | " |
| 18 | DEPENDS:append:libc-musl = " fts" | 18 | DEPENDS:append:libc-musl = " fts" |
| 19 | 19 | ||
| 20 | SRCREV = "d13e8e4ab2029fa92600b7d1d0da28f8dcc350eb" | 20 | SRCREV = "b12e507090273576d1156342780c7c6d358fa579" |
| 21 | SRC_URI = "\ | 21 | SRC_URI = "\ |
| 22 | git://github.com/fluent/fluent-bit.git;branch=3.2;protocol=https \ | 22 | git://github.com/fluent/fluent-bit.git;branch=master;protocol=https \ |
| 23 | file://0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch \ | 23 | file://0001-lib-Do-not-use-private-makefile-targets-in-CMakelist.patch \ |
| 24 | file://0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch \ | 24 | file://0002-flb_info.h.in-Do-not-hardcode-compilation-directorie.patch \ |
| 25 | file://0003-CMakeLists.txt-Revise-init-manager-deduction.patch \ | 25 | file://0003-CMakeLists.txt-Revise-init-manager-deduction.patch \ |
| @@ -109,8 +109,8 @@ PACKAGECONFIG[windows-defaults] = "-DFLB_WINDOWS_DEFAULTS=Yes,-DFLB_WINDOWS_DEFA | |||
| 109 | # individual plugins then to enable (e.g. using EXTRA_OECMAKE:append = " -DFLB_FOOBAR=ON") | 109 | # individual plugins then to enable (e.g. using EXTRA_OECMAKE:append = " -DFLB_FOOBAR=ON") |
| 110 | PACKAGECONFIG[minimal] = "-DFLB_MINIMAL=Yes,-DFLB_MINIMAL=No" | 110 | PACKAGECONFIG[minimal] = "-DFLB_MINIMAL=Yes,-DFLB_MINIMAL=No" |
| 111 | 111 | ||
| 112 | PACKAGECONFIG[in-kafka] = "-DFLB_IN_KAFKA=ON,-DFLB_IN_KAFKA=OFF,librdkafka curl" | 112 | PACKAGECONFIG[in-kafka] = "-DFLB_KAFKA=ON -DFLB_IN_KAFKA=ON,-DFLB_KAFKA=OFF -DFLB_IN_KAFKA=OFF,librdkafka curl" |
| 113 | PACKAGECONFIG[out-kafka] = "-DFLB_OUT_KAFKA=ON,-DFLB_OUT_KAFKA=OFF,librdkafka curl" | 113 | PACKAGECONFIG[out-kafka] = "-DFLB_KAFKA=ON -DFLB_OUT_KAFKA=ON,-DFLB_KAFKA=OFF -DFLB_OUT_KAFKA=OFF,librdkafka curl" |
| 114 | 114 | ||
| 115 | SYSTEMD_SERVICE:${PN} = "fluent-bit.service" | 115 | SYSTEMD_SERVICE:${PN} = "fluent-bit.service" |
| 116 | 116 | ||
| @@ -124,13 +124,18 @@ FULL_OPTIMIZATION:remove = "${@'-O2' if bb.data.inherits_class('clang', d) else | |||
| 124 | TARGET_CC_ARCH += "${SELECTED_OPTIMIZATION}" | 124 | TARGET_CC_ARCH += "${SELECTED_OPTIMIZATION}" |
| 125 | TARGET_CC_ARCH:remove = "-D_FORTIFY_SOURCE=2" | 125 | TARGET_CC_ARCH:remove = "-D_FORTIFY_SOURCE=2" |
| 126 | EXTRA_OECMAKE += "-DCMAKE_DEBUG_SRCDIR=${TARGET_DBGSRC_DIR}/" | 126 | EXTRA_OECMAKE += "-DCMAKE_DEBUG_SRCDIR=${TARGET_DBGSRC_DIR}/" |
| 127 | EXTRA_OECMAKE:append:mips = " -DCMAKE_C_STANDARD_LIBRARIES=-latomic" | 127 | |
| 128 | EXTRA_OECMAKE:append:powerpc = " -DCMAKE_C_STANDARD_LIBRARIES=-latomic" | ||
| 129 | EXTRA_OECMAKE:append:riscv32 = " -DCMAKE_C_STANDARD_LIBRARIES=-latomic" | ||
| 130 | EXTRA_OECMAKE:append:riscv64 = " -DCMAKE_C_STANDARD_LIBRARIES=-latomic" | ||
| 131 | EXTRA_OECMAKE:append:x86 = " -DCMAKE_C_STANDARD_LIBRARIES=-latomic" | ||
| 132 | SECURITY_STRINGFORMAT:remove = "${@bb.utils.contains('PACKAGECONFIG', 'aws-error-reporter', '-Werror=format-security', '', d)}" | 128 | SECURITY_STRINGFORMAT:remove = "${@bb.utils.contains('PACKAGECONFIG', 'aws-error-reporter', '-Werror=format-security', '', d)}" |
| 133 | 129 | ||
| 130 | # GCC-15 uses C23 std and it does not yet compile with C23 | ||
| 131 | CFLAGS += "-std=gnu17" | ||
| 132 | # 64bit atomics builtins do not exist in compiler on these arches | ||
| 133 | LDFLAGS:append:mips = " -latomic" | ||
| 134 | LDFLAGS:append:powerpc = " -latomic" | ||
| 135 | LDFLAGS:append:riscv32 = " -latomic" | ||
| 136 | LDFLAGS:append:riscv64 = " -latomic" | ||
| 137 | LDFLAGS:append:x86 = " -latomic" | ||
| 138 | |||
| 134 | do_configure:prepend() { | 139 | do_configure:prepend() { |
| 135 | sed -i \ | 140 | sed -i \ |
| 136 | -e 's#@INIT_MANAGER_IS_SYSTEMD@#'${@'TRUE' if d.getVar('INIT_MANAGER') == 'systemd' else 'FALSE'}'#' \ | 141 | -e 's#@INIT_MANAGER_IS_SYSTEMD@#'${@'TRUE' if d.getVar('INIT_MANAGER') == 'systemd' else 'FALSE'}'#' \ |
