Skip to content
Snippets Groups Projects
Commit d7fa6d34 authored by Leonid Vasiliev's avatar Leonid Vasiliev Committed by Kirill Yukhin
Browse files

build: fix compilation on Alpine 3.5

The cbus hang test uses glibc pthread mutex implementation details.
The reason why mutex implementation details is used:
"For the bug reproducing the canceled thread must be canceled
during processing cpipe_flush_cb. We need to synchronize
the main thread and the canceled worker thread for that.
So, thread synchronization has been realized by means of
endpoint's mutex internal field(__data.__lock)."
Therefore, it should not compile in case of using another library.
parent 09832455
No related branches found
No related tags found
No related merge requests found
...@@ -104,7 +104,9 @@ target_link_libraries(cbus_stress.test core stat) ...@@ -104,7 +104,9 @@ target_link_libraries(cbus_stress.test core stat)
add_executable(cbus.test cbus.c) add_executable(cbus.test cbus.c)
target_link_libraries(cbus.test core unit stat) target_link_libraries(cbus.test core unit stat)
if (${CMAKE_HOST_SYSTEM_NAME} MATCHES "Linux") include(CheckSymbolExists)
check_symbol_exists(__GLIBC__ features.h GLIBC_USED)
if (GLIBC_USED)
add_executable(cbus_hang.test cbus_hang.c) add_executable(cbus_hang.test cbus_hang.c)
target_link_libraries(cbus_hang.test core unit stat) target_link_libraries(cbus_hang.test core unit stat)
endif () endif ()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment