Skip to content

Commit

Permalink
build: macOS 15
Browse files Browse the repository at this point in the history
  • Loading branch information
qzhuyan committed Dec 17, 2024
1 parent 1f933bc commit b3d3fe2
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,19 @@ set(SOURCES
# @todo remove -DSO_ATTACH_REUSEPORT_CBPF=51
add_compile_options(-DSO_ATTACH_REUSEPORT_CBPF=51)

if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang")
string(REPLACE "." ";" set_version_list ${CMAKE_CXX_COMPILER_VERSION})
list(GET set_version_list 0 major_version)
# Check for Clang version >= 16.0
if (major_version GREATER_EQUAL 16)
message(STATUS "Clang version >= 16.0 detected, enabling '-Wno-invalid-unevaluated-string'.")
# Add the warning option
add_compile_options(-Wno-invalid-unevaluated-string)
else()
message(STATUS "Clang version < 16.0, skipping '-Wno-invalid-unevaluated-string'.")
endif()
endif()

# for lttng, quicer_tp.h
include_directories(c_src)
# for templ files
Expand Down

0 comments on commit b3d3fe2

Please sign in to comment.