Skip to content

Commit

Permalink
Don't try to build on BSD (#142)
Browse files Browse the repository at this point in the history
The 'BSD' variable was added in CMake 3.25. Note that variables which
are not defined will evaluate to 'False', so this shouldn't regress
platforms using CMake versions older than 3.25.

Signed-off-by: Scott K Logan <[email protected]>
  • Loading branch information
cottsay authored Nov 21, 2024
1 parent f1e79eb commit 60170d7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lttngpy/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ endif()

find_package(ament_cmake REQUIRED)

if(WIN32 OR APPLE OR ANDROID)
if(WIN32 OR APPLE OR ANDROID OR BSD)
set(DISABLED_DEFAULT ON)
else()
set(DISABLED_DEFAULT OFF)
Expand Down Expand Up @@ -92,7 +92,7 @@ endif()

pybind11_add_module(_lttngpy_pybind11 SHARED ${SOURCES})

if(CMAKE_C_COMPILER_ID MATCHES "Clang" AND NOT APPLE)
if(CMAKE_C_COMPILER_ID MATCHES "Clang" AND NOT APPLE AND NOT BSD)
target_link_libraries(_lttngpy_pybind11 PRIVATE atomic)
endif()

Expand Down
2 changes: 1 addition & 1 deletion test_tracetools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ endif()

find_package(ament_cmake REQUIRED)

if(WIN32 OR APPLE OR ANDROID)
if(WIN32 OR APPLE OR ANDROID OR BSD)
set(DISABLED_DEFAULT ON)
else()
set(DISABLED_DEFAULT OFF)
Expand Down
2 changes: 1 addition & 1 deletion tracetools/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ endif()
find_package(ament_cmake_gen_version_h REQUIRED)
find_package(ament_cmake_ros REQUIRED)

if(WIN32 OR APPLE OR ANDROID)
if(WIN32 OR APPLE OR ANDROID OR BSD)
set(DISABLED_DEFAULT ON)
set(STATUS_CHECKING_TOOL_DEFAULT OFF)
else()
Expand Down

0 comments on commit 60170d7

Please sign in to comment.