2013-02-21 17:00:44 -05:00
|
|
|
# Look for json, use our own if not found
|
|
|
|
|
|
|
|
#FIND_PATH(JSON_INCLUDE_DIR json.h)
|
|
|
|
|
2013-03-05 15:51:05 -05:00
|
|
|
#FIND_LIBRARY(JSON_LIBRARY NAMES jsoncpp)
|
2013-02-21 17:00:44 -05:00
|
|
|
|
|
|
|
#IF(JSON_LIBRARY AND JSON_INCLUDE_DIR)
|
|
|
|
# SET( JSON_FOUND TRUE )
|
|
|
|
#ENDIF(JSON_LIBRARY AND JSON_INCLUDE_DIR)
|
|
|
|
|
|
|
|
#IF(JSON_FOUND)
|
2013-03-05 15:51:05 -05:00
|
|
|
# MESSAGE(STATUS "Found system jsoncpp header file in ${JSON_INCLUDE_DIR}")
|
|
|
|
# MESSAGE(STATUS "Found system jsoncpp library ${JSON_LIBRARY}")
|
2013-02-21 17:00:44 -05:00
|
|
|
#ELSE(JSON_FOUND)
|
|
|
|
SET(JSON_INCLUDE_DIR ${PROJECT_SOURCE_DIR}/json)
|
2013-03-05 15:51:05 -05:00
|
|
|
SET(JSON_LIBRARY jsoncpp)
|
|
|
|
MESSAGE(STATUS "Using project jsoncpp library")
|
2013-02-21 17:00:44 -05:00
|
|
|
#ENDIF(JSON_FOUND)
|