Skip to content

Commit

Permalink
macos cmake threads fix attempt #1
Browse files Browse the repository at this point in the history
  • Loading branch information
r3w0p committed May 27, 2024
1 parent bed3bd5 commit 5bd5274
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/building.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ jobs:
compiler_cc: clang
compiler_cpp: clang++

#- name: MacOS Clang
# os: macos-latest
# compiler_cc: clang
# compiler_cpp: clang++
- name: MacOS Clang
os: macos-latest
compiler_cc: clang
compiler_cpp: clang++

- name: Windows GCC
os: windows-latest
Expand Down
8 changes: 8 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,14 @@ set(FETCHCONTENT_QUIET FALSE)


# --- FTXUI
IF (APPLE)
set(CMAKE_THREAD_LIBS_INIT "-lpthread")
set(CMAKE_HAVE_THREADS_LIBRARY 1)
set(CMAKE_USE_WIN32_THREADS_INIT 0)
set(CMAKE_USE_PTHREADS_INIT 1)
set(THREADS_PREFER_PTHREAD_FLAG ON)
ENDIF ()

FetchContent_Declare(ftxui
GIT_REPOSITORY https://github.com/ArthurSonzogni/ftxui
GIT_TAG v5.0.0
Expand Down

0 comments on commit 5bd5274

Please sign in to comment.