2021-06-23 05:28:12 +00:00
|
|
|
if(NOT LIBPREPROC_IS_EXTERNAL_PROJECT)
|
|
|
|
set(LIBPREPROC_PREFIX "" CACHE PATH "The path to the prefix of an libpreproc installation")
|
2021-06-23 04:34:59 +00:00
|
|
|
|
|
|
|
find_path(
|
|
|
|
LIBPREPROC_INCLUDE_DIRS
|
|
|
|
NAMES preproc/mark.hpp
|
|
|
|
PATHS ${LIBPREPROC_PREFIX}/include)
|
|
|
|
find_library(
|
|
|
|
LIBPREPROC_LIBRARY
|
|
|
|
NAMES preproc
|
|
|
|
PATHS ${LIBPREPROC_PREFIX}/lib)
|
|
|
|
|
|
|
|
if(LIBPREPROC_INCLUDE_DIRS AND LIBPREPROC_LIBRARY)
|
|
|
|
get_filename_component(LIBPREPROC_LIBRARY_DIR ${LIBPREPROC_LIBRARY}
|
|
|
|
DIRECTORY CACHE)
|
|
|
|
set(LIBPREPROC_FOUND TRUE)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
if(LIBPREPROC_FOUND)
|
|
|
|
if(NOT LIBPREPROC_FIND_QUIETLY)
|
|
|
|
message(STATUS "Found libpreproc")
|
|
|
|
endif()
|
|
|
|
set(HAVE_LIBPREPROC 1)
|
|
|
|
elseif(LIBPREPROC_FOUND)
|
|
|
|
if(LIBPREPROC_FIND_REQUIRED)
|
|
|
|
message(FATAL_ERROR "Could not find libpreproc")
|
|
|
|
endif()
|
|
|
|
endif()
|
|
|
|
endif()
|