Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,16 @@ if(WOLFTPM_SINGLE_THREADED)
endif()

# Mutex locking
set(WOLFTPM_NO_LOCK "no" CACHE STRING
"Enable thread mutex locking (default: enabled)")
if(WOLFTPM_SINGLE_THREADED)
set(_WOLFTPM_NO_LOCK_DEFAULT "yes")
else()
set(_WOLFTPM_NO_LOCK_DEFAULT "no")
endif()
set(WOLFTPM_NO_LOCK "${_WOLFTPM_NO_LOCK_DEFAULT}" CACHE STRING
"Disable thread mutex locking (default: ${_WOLFTPM_NO_LOCK_DEFAULT})")
set_property(CACHE WOLFTPM_NO_LOCK
PROPERTY STRINGS "yes;no")
if(NOT WOLFTPM_NO_LOCK)
if(WOLFTPM_NO_LOCK)
list(APPEND WOLFTPM_DEFINITIONS
"-DWOLFTPM_NO_LOCK")
endif()
Expand Down
Loading