find_path(LIBURCU_INCLUDE_DIR NAMES urcu.h)
mark_as_advanced(LIBURCU_INCLUDE_DIR)

find_library(LIBURCU_LIBRARY NAMES urcu)
mark_as_advanced(LIBURCU_LIBRARY)

include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(
  LIBURCU
  REQUIRED_VARS LIBURCU_LIBRARY LIBURCU_INCLUDE_DIR)

if(LIBURCU_FOUND)
  set(LIBURCU_LIBRARIES ${LIBURCU_LIBRARY})
  set(LIBURCU_INCLUDE_DIRS ${LIBURCU_INCLUDE_DIR})
endif()
