picrin/contrib/10.regexp/CMakeLists.txt

17 lines
494 B
CMake

# regex
set(PICRIN_REGEX_DIR ${PICRIN_CONTRIB_DIR}/10.regexp)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PICRIN_REGEX_DIR}/cmake/")
find_package(REGEX)
if (REGEX_FOUND)
add_definitions(${REGEX_DEFINITIONS})
include_directories(${REGEX_INCLUDE_DIR})
file(GLOB PICRIN_REGEX_SOURCES ${PICRIN_REGEX_DIR}/src/*.c)
list(APPEND PICRIN_CONTRIB_INITS regexp)
list(APPEND PICRIN_CONTRIB_LIBRARIES ${REGEX_LIBRARIES})
list(APPEND PICRIN_CONTRIB_SOURCES ${PICRIN_REGEX_SOURCES})
endif()