Skip to content

Commit

Permalink
Merge pull request #364 from arene-os-services-cockpit-tmc-wa/jw/comp…
Browse files Browse the repository at this point in the history
…iler-thread

Move thread detection into compiler
  • Loading branch information
Joel Winarske authored and GitHub Enterprise committed Feb 3, 2025
2 parents d5161a6 + a42091a commit e1bd3bd
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
15 changes: 11 additions & 4 deletions cmake/compiler.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,22 @@ if (ENABLE_LTO)
endif ()

#
# Compiler specific settings
# Toolchain target
#
message(STATUS "CMAKE_CXX_COMPILER_ID .. ${CMAKE_CXX_COMPILER_ID}")
message(STATUS "CMAKE_CXX_COMPILER_VERSION: ${CMAKE_CXX_COMPILER_VERSION}")
message(STATUS "Compiler ............... ${CMAKE_CXX_COMPILER_ID}")
message(STATUS "Compiler Version ....... ${CMAKE_CXX_COMPILER_VERSION}")

if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
include(compiler_clang)
endif ()

if (CMAKE_CXX_COMPILER_ID MATCHES "GNU")
include(compiler_gnu)
endif ()
endif ()

#
# Threads
#
set(THREADS_PREFER_PTHREAD_FLAG ON)
find_package(Threads REQUIRED)
target_link_libraries(toolchain INTERFACE Threads::Threads)
4 changes: 0 additions & 4 deletions shell/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,6 @@ target_link_libraries(${PROJECT_NAME} PRIVATE
platform_homescreen
)

if (NOT LLVM_ENABLE_THREADS)
target_link_libraries(${PROJECT_NAME} PUBLIC Threads::Threads)
endif ()

target_link_directories(${PROJECT_NAME} PRIVATE
${CMAKE_BINARY_DIR}
)
Expand Down
2 changes: 1 addition & 1 deletion third_party/waypp

0 comments on commit e1bd3bd

Please sign in to comment.