Files
meta-openembedded/meta-oe/recipes-extended/fluentbit/fluentbit/cross-build-init-system-detection.patch
Khem Raj 0b80ef1431 fluentbit: Upgrade to 1.3.5
Sync recipe with the one in sourcecode
Record Accessor feature requires Flex and Bison
fts dependency is needed on musl
Delete cmake_multilib.patch its fixed upstream
Use builtin nan funciton to avoid linking with libm

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2019-12-31 11:06:23 -08:00

39 lines
1.7 KiB
Diff

Define CMake variables to indicate init system for target
incase of cross compile, detecting systemd support based on
host directory structure is not right thing to do
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.kheem@gmail.com>
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -317,7 +317,7 @@ if(FLB_BINARY)
install(TARGETS fluent-bit-bin RUNTIME DESTINATION ${FLB_INSTALL_BINDIR})
# Detect init system, install upstart, systemd or init.d script
- if(IS_DIRECTORY /lib/systemd/system)
+ if(IS_DIRECTORY /lib/systemd/system OR FLB_SYSTEMD)
set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service")
configure_file(
"${PROJECT_SOURCE_DIR}/init/systemd.in"
@@ -325,7 +325,7 @@ if(FLB_BINARY)
)
install(FILES ${FLB_SYSTEMD_SCRIPT} DESTINATION /lib/systemd/system)
install(DIRECTORY DESTINATION ${FLB_INSTALL_CONFDIR})
- elseif(IS_DIRECTORY /usr/share/upstart)
+ elseif(IS_DIRECTORY /usr/share/upstart OR FLB_UPSTART)
set(FLB_UPSTART_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.conf")
configure_file(
"${PROJECT_SOURCE_DIR}/init/upstart.in"
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -70,6 +70,8 @@ option(FLB_RECORD_ACCESSOR "Enable re
option(FLB_SYSTEM_STRPTIME "Use strptime in system libc" Yes)
option(FLB_STATIC_CONF "Build binary using static configuration")
option(FLB_STREAM_PROCESSOR "Enable Stream Processor" Yes)
+option(FLB_SYSTEMD "Enable systemd init system" No)
+option(FLB_UPSTART "Enable upstart init system" No)
option(FLB_CORO_STACK_SIZE "Set coroutine stack size")
# Metrics: Experimental Feature, disabled by default on 0.12 series