summaryrefslogtreecommitdiffstats
path: root/cmake/FindUcommon.cmake
blob: 75dd53c12b8672656156cfc0315117c1b90c91cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
FIND_PATH(UCOMMON_INCLUDE_DIR ucommon/ucommon.h)
FIND_LIBRARY(UCOMMON_LIBRARIES NAMES ucommon)
FIND_LIBRARY(USECURE_LIBRARIES NAMES usecure)

IF(UCOMMON_INCLUDE_DIR AND UCOMMON_LIBRARIES AND USECURE_LIBRARIES)
	SET(UCOMMON_FOUND TRUE)
	SET(UCOMMON_LIBRARIES ${UCOMMON_LIBRARIES} ${USECURE_LIBRARIES})
ENDIF(UCOMMON_INCLUDE_DIR AND UCOMMON_LIBRARIES AND USECURE_LIBRARIES)

IF(UCOMMON_FOUND)
	IF (NOT Ucommon_FIND_QUIETLY)
		MESSAGE(STATUS "Found ucommon includes:	${UCOMMON_INCLUDE_DIR}/ucommon/ucommon.h")
		MESSAGE(STATUS "Found ucommon library:	${UCOMMON_LIBRARIES}")
	ENDIF (NOT Ucommon_FIND_QUIETLY)
ELSE(UCOMMON_FOUND)
	IF (Ucommon_FIND_REQUIRED)
		MESSAGE(FATAL_ERROR "Could NOT find ucommon development files")
	ENDIF (Ucommon_FIND_REQUIRED)
ENDIF(UCOMMON_FOUND)