Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix build for systems without separate uuid library

  • Loading branch information...
commit 8be40a5e3f0b617aa70c740521033d9b124c42b4 1 parent 44e5990
Zachary Landau authored
Showing with 6 additions and 1 deletion.
  1. +1 −1  addons/UUID/CMakeLists.txt
  2. +5 −0 modules/FindUUID.cmake
View
2  addons/UUID/CMakeLists.txt
@@ -32,7 +32,7 @@ if(UUID_FOUND)
# Now build the shared library
add_library(IoUUID SHARED ${SRCS})
add_dependencies(IoUUID iovmall)
- target_link_libraries(IoUUID iovmall uuid)
+ target_link_libraries(IoUUID iovmall ${UUID_LIBRARY})
# Install the addon to our global addons hierarchy.
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} DESTINATION lib/io/addons)
View
5 modules/FindUUID.cmake
@@ -4,6 +4,11 @@
# Find libuuid
FIND_PATH(UUID_INCLUDE_DIR uuid/uuid.h)
+FIND_LIBRARY(UUID_LIBRARY NAMES uuid PATH)
+
+IF(NOT UUID_LIBRARY)
+ SET(UUID_LIBRARY "")
+ENDIF(NOT UUID_LIBRARY)
IF(UUID_INCLUDE_DIR)
SET(UUID_FOUND TRUE)
Please sign in to comment.
Something went wrong with that request. Please try again.