From 34c3cf62db89d337190d3c8584269302dc499cda Mon Sep 17 00:00:00 2001 From: Hiroshi Hatake Date: Mon, 28 Oct 2024 20:16:39 +0900 Subject: [PATCH] packaging: Detect centos/6 or centos/7 to turn off simdutf stuffs Signed-off-by: Hiroshi Hatake --- packaging/build.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packaging/build.sh b/packaging/build.sh index cec48e8ad8c..fde06d52c3a 100755 --- a/packaging/build.sh +++ b/packaging/build.sh @@ -71,11 +71,18 @@ fi CMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX:-/opt/fluent-bit/} # This is required to ensure we set the defaults to off for 1.9 builds FLB_TD=${FLB_TD:-Off} +# This is provided for simplifying the build pipeline +FLB_UNICODE_ENCODER=${FLB_UNICODE_ENCODER:-On} + +if [ "${FLB_DISTRO}" = "centos/6" ] || [ "${FLB_DISTRO}" = "centos/7" ]; then + FLB_UNICODE_ENCODER=Off +fi echo "IMAGE_CONTEXT_DIR => $IMAGE_CONTEXT_DIR" echo "CMAKE_INSTALL_PREFIX => $CMAKE_INSTALL_PREFIX" echo "FLB_NIGHTLY_BUILD => $FLB_NIGHTLY_BUILD" echo "FLB_JEMALLOC => $FLB_JEMALLOC" +echo "FLB_UNICODE_ENCODER => $FLB_UNICODE_ENCODER" if [ "${DOCKER}" = "docker" ]; then export DOCKER_BUILDKIT=1 @@ -90,6 +97,7 @@ if ! ${DOCKER} build \ --build-arg FLB_NIGHTLY_BUILD="$FLB_NIGHTLY_BUILD" \ --build-arg FLB_JEMALLOC="$FLB_JEMALLOC" \ --build-arg FLB_TD="$FLB_TD" \ + --build-arg FLB_UNICODE_ENCODER="$FLB_UNICODE_ENCODER" \ $FLB_ARG \ -t "$MAIN_IMAGE" \ -f "$IMAGE_CONTEXT_DIR/Dockerfile" \