Skip to content

Commit 80f26c6

Browse files
committed
build: on macOS link to Foundation and IOKit frameworks
Signed-off-by: Eduardo Silva <[email protected]>
1 parent 40935fa commit 80f26c6

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/CMakeLists.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,13 @@ if(CMAKE_SYSTEM_NAME MATCHES "Linux")
277277
)
278278
endif()
279279

280+
if(FLB_SYSTEM_MACOS)
281+
set(FLB_DEPS
282+
${FLB_DEPS}
283+
"-framework Foundation"
284+
"-framework IOKit"
285+
)
286+
endif()
280287

281288
# Record Accessor
282289
# ---------------
@@ -524,7 +531,7 @@ if(FLB_BINARY)
524531
if(NOT SYSTEMD_UNITDIR AND IS_DIRECTORY /lib/systemd/system)
525532
set(SYSTEMD_UNITDIR /lib/systemd/system)
526533
endif()
527-
534+
528535
if(SYSTEMD_UNITDIR)
529536
set(FLB_SYSTEMD_SCRIPT "${PROJECT_SOURCE_DIR}/init/${FLB_OUT_NAME}.service")
530537
configure_file(

0 commit comments

Comments
 (0)