FindCSlim.cmake
799 Bytes
# - Try to find CSlim
# Once done this will define
# CSLIM_FOUND - System has CSlim
# CSLIMINCLUDE_DIRS - The CSlim include directories
# CSLIMLIBRARIES - The libraries needed to use CSlim
# CSLIMDEFINITIONS - Compiler switches required for using CSlim
find_path(CSLIMINCLUDE_DIR CSlim/Slim.h
HINTS
$ENV{CSLIM_ROOT}/include
${CSLIM_ROOT}/include
)
mark_as_advanced(CSLIMINCLUDE_DIR)
find_library(CSLIMLIBRARY
NAMES CSlim
HINTS
$ENV{CSLIM_ROOT}
${CSLIM_ROOT}
PATH_SUFFIXES lib
)
mark_as_advanced(CSLIMLIBRARY)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(CSlim DEFAULT_MSG CSLIMLIBRARY CSLIMINCLUDE_DIR)
if(CSLIM_FOUND)
set(CSLIMINCLUDE_DIRS ${CSLIMINCLUDE_DIR})
set(CSLIMLIBRARIES ${CSLIMLIBRARY})
endif()