stduuid/cmake/FindLibuuid.cmake
Egor Kuzmin 6ac13af81a modern cmake project struct
Added ability to add as a dependency to another cmake project via add_subdirectory
2020-11-03 18:25:37 +03:00

17 lines
499 B
CMake

find_path(Libuuid_INCLUDE_DIRS uuid/uuid.h)
find_library(Libuuid_LIBRARIES uuid)
if (Libuuid_LIBRARIES AND Libuuid_INCLUDE_DIRS)
set(Libuuid_FOUND YES)
if (NOT Libuuid_FIND_QUIETLY)
message(STATUS "Found libuuid: ${Libuuid_LIBRARIES}")
endif ()
else ()
if (Libuuid_FIND_REQUIRED)
message(SEND_ERROR "Could NOT find libuuid")
else ()
if (NOT Libuuid_FIND_QUIETLY)
message(STATUS "Could NOT find libuuid")
endif ()
endif ()
endif ()