# - Try to find the PLplot libraries # Once done this will define # # PLplot_FOUND - flag that indicates libcurl is installed # PLplot_INCLUDE_DIR - the plplot include directory # PLplot_LIBRARIES - the libplplotcxxd library directory # QSAS_LIBRARIES - the libqsastime library directory FIND_PATH(PLplot_INCLUDE_DIR plplot.h PATHS /include/curl /usr/include/plplot /usr/local/include/plplot ${USERLOCAL_ROOT}/include/plplot) FIND_LIBRARY(PLplot_LIBRARIES NAMES plplotcxxd PATHS /lib /usr/lib ${USERLOCAL_ROOT}/lib /usr/local/lib NO_DEFAULT_PATH) FIND_LIBRARY(QSAS_LIBRARIES NAMES qsastime PATHS /lib /usr/lib ${USERLOCAL_ROOT}/lib /usr/local/lib NO_DEFAULT_PATH) # set FOUND flag IF(PLplot_INCLUDE_DIR AND PLplot_LIBRARIES AND QSAS_LIBRARIES) SET(PLplot_FOUND 1) #remove last /plplot string STRING(REGEX REPLACE "/plplot" "" PLplot_INCLUDE_DIR_SUP_LEVEL ${PLplot_INCLUDE_DIR}) SET (PLplot_INCLUDE_DIR ${PLplot_INCLUDE_DIR_SUP_LEVEL} ${PLplot_INCLUDE_DIR} ) if(NOT PLplot_FIND_QUIETLY) message(STATUS "Found PLplot: ${PLplot_LIBRARIES}") message(STATUS "Found QSAStime: ${QSAS_LIBRARIES}") endif(NOT PLplot_FIND_QUIETLY) ELSE(PLplot_INCLUDE_DIR AND PLplot_LIBRARIES AND QSAS_LIBRARIES) SET(PLplot_FOUND 0 CACHE BOOL "Not found PLplot library") message(STATUS "NOT Found PLplot, disabling it") ENDIF(PLplot_INCLUDE_DIR AND PLplot_LIBRARIES AND QSAS_LIBRARIES) MARK_AS_ADVANCED(PLplot_INCLUDE_DIR PLplot_LIBRARIES QSAS_LIBRARIES)