2010-11-12 15:21:49 +05:30
|
|
|
project (ifchd)
|
|
|
|
|
|
|
|
cmake_minimum_required (VERSION 2.6)
|
|
|
|
|
2013-05-08 15:57:22 +05:30
|
|
|
set(RAGEL_IFCHD_PARSE ${CMAKE_CURRENT_BINARY_DIR}/ifchd-parse.c)
|
|
|
|
|
|
|
|
find_program(RAGEL ragel)
|
|
|
|
add_custom_command(
|
|
|
|
OUTPUT ${RAGEL_IFCHD_PARSE}
|
|
|
|
COMMAND ${RAGEL} -G2 -o ${RAGEL_IFCHD_PARSE} ifchd-parse.rl
|
|
|
|
DEPENDS ifchd-parse.rl
|
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
|
|
|
COMMENT "Compiling Ragel state machine: ifchd-parse.rl"
|
|
|
|
VERBATIM
|
|
|
|
)
|
|
|
|
|
2012-07-21 04:18:26 +05:30
|
|
|
file(GLOB IFCHD_SRCS "*.c")
|
2010-11-12 15:21:49 +05:30
|
|
|
|
2013-05-08 15:57:22 +05:30
|
|
|
add_executable(ifchd ${RAGEL_IFCHD_PARSE} ${IFCHD_SRCS})
|
2010-11-12 16:12:07 +05:30
|
|
|
target_link_libraries(ifchd ncmlib)
|