From 484a7ada0070dc576bfb90f324c9b8592b119584 Mon Sep 17 00:00:00 2001 From: YingJie Fu Date: Mon, 5 Aug 2024 23:27:16 -0700 Subject: [PATCH] build: use the system lib luajit for s390x Signed-off-by: YingJie Fu --- README.md | 4 ++-- cmake/s390x.cmake | 8 ++++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index a6ba08be9e8..005ff774e91 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ Fluent Bit allows to collect log events or metrics from different sources, proce Fluent Bit comes with full SQL [Stream Processing](https://docs.fluentbit.io/manual/stream-processing/introduction) capabilities: data manipulation and analytics using SQL queries. -Fluent Bit runs on x86_64, x86, arm32v7, and arm64v8 architectures. +Fluent Bit runs on x86_64, x86, s390x, arm32v7, and arm64v8 architectures. @@ -104,7 +104,7 @@ Fluent Bit is fully supported on Windows environments, get started with [these i #### Running on s390x -Fluent Bit is supported on Linux on IBM Z(s390x), but the WASM and LUA filter plugins are not. +Fluent Bit is supported on Linux on IBM Z(s390x), but the WASM filter plugin is not. For the LUA filter plugin, it is only supported when `libluajit` is installed on the system and fluent bit is built with `FLB_LUAJIT` and `FLB_PREFER_SYSTEM_LIB_LUAJIT` on. ### Plugins: Inputs, Filters and Outputs diff --git a/cmake/s390x.cmake b/cmake/s390x.cmake index af70127ceb4..c93633636a0 100644 --- a/cmake/s390x.cmake +++ b/cmake/s390x.cmake @@ -3,6 +3,10 @@ if(CMAKE_SYSTEM_PROCESSOR MATCHES "^(SystemZ|s390x)") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsigned-char") message(STATUS "Cannot build WAMR on this platform, so WASM support is disabled.") set(FLB_WASM OFF) - message(STATUS "This platform does not support LuaJIT, so it's disabled.") - set(FLB_LUAJIT OFF) + if(FLB_LUAJIT) + if(NOT FLB_PREFER_SYSTEM_LIB_LUAJIT) + message(WARNING "LuaJIT is disabled, this platform does not support built-in LuaJIT. To use lua filter on this platform, install LuaJIT as system lib and build again with both FLB_LUAJIT and FLB_PREFER_SYSTEM_LIB_LUAJIT on.") + set(FLB_LUAJIT OFF) + endif() + endif() endif ()