Make valgrind work on Fedora 30
This commit is contained in:
parent
8590cd4286
commit
4c62458172
|
@ -1,5 +1,13 @@
|
|||
set(FORCE_ALL_COMPONENTS OFF CACHE BOOL "Fails cmake if not all dependencies are found")
|
||||
|
||||
################################################################################
|
||||
# Valgrind
|
||||
################################################################################
|
||||
|
||||
if(USE_VALGRIND)
|
||||
find_package(Valgrind REQUIRED)
|
||||
endif()
|
||||
|
||||
################################################################################
|
||||
# LibreSSL
|
||||
################################################################################
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
find_path(VALGRIND_INCLUDE_DIR
|
||||
NAMES
|
||||
valgrind.h
|
||||
PATH_SUFFIXES include valgrind)
|
||||
|
||||
find_package_handle_standard_args(Valgrind
|
||||
REQUIRED_VARS VALGRIND_INCLUDE_DIR
|
||||
FAIL_MESSAGE "Could not find Valgrind header files, try set the path to the Valgrind headers in the variable Valgrind_ROOT")
|
||||
|
||||
if(VALGRIND_FOUND)
|
||||
add_library(Valgrind INTERFACE)
|
||||
target_include_directories(Valgrind INTERFACE "${VALGRIND_INCLUDE_DIR}")
|
||||
endif()
|
|
@ -57,6 +57,9 @@ add_library(thirdparty ${FDBRPC_THIRD_PARTY_SRCS})
|
|||
if(NOT WIN32)
|
||||
target_compile_options(thirdparty BEFORE PRIVATE -w) # disable warnings for third party
|
||||
endif()
|
||||
if(USE_VALGRIND)
|
||||
target_link_libraries(thirdparty PUBLIC Valgrind)
|
||||
endif()
|
||||
|
||||
set(FDBRPC_SRCS_DISABLE_ACTOR_WITHOUT_WAIT_WARNING
|
||||
ActorFuzz.actor.cpp
|
||||
|
|
|
@ -89,6 +89,9 @@ elseif(WIN32)
|
|||
endif()
|
||||
target_link_libraries(flow PRIVATE ${FLOW_LIBS})
|
||||
target_link_libraries(flow PUBLIC boost_target Threads::Threads ${CMAKE_DL_LIBS})
|
||||
if(USE_VALGRIND)
|
||||
target_link_libraries(flow PUBLIC Valgrind)
|
||||
endif()
|
||||
if(NOT WITH_TLS)
|
||||
target_compile_definitions(flow PUBLIC TLS_DISABLED)
|
||||
else()
|
||||
|
|
Loading…
Reference in New Issue