diff options
author | Adrian Thurston <thurston@colm.net> | 2019-09-08 21:14:08 -0600 |
---|---|---|
committer | Adrian Thurston <thurston@colm.net> | 2019-09-08 21:14:08 -0600 |
commit | 01b426837b1aa72d3535ec0f27b13e43993311bc (patch) | |
tree | 2dec36611a823f80ee677bd649b0f04ce5d885ee /ragel/host-csharp/CMakeLists.txt | |
parent | 1058d1029a9a1dda7d6d4c4e07fc775bb1ae4cd0 (diff) | |
download | colm-01b426837b1aa72d3535ec0f27b13e43993311bc.tar.gz |
moved /ragel-repos/src to /ragel
This will be what we build after building colm.
Diffstat (limited to 'ragel/host-csharp/CMakeLists.txt')
-rw-r--r-- | ragel/host-csharp/CMakeLists.txt | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/ragel/host-csharp/CMakeLists.txt b/ragel/host-csharp/CMakeLists.txt new file mode 100644 index 00000000..8d70e5a6 --- /dev/null +++ b/ragel/host-csharp/CMakeLists.txt @@ -0,0 +1,34 @@ +add_custom_command(OUTPUT + "${CMAKE_CURRENT_BINARY_DIR}/rlparse.c" + "${CMAKE_CURRENT_BINARY_DIR}/rlreduce.cc" + DEPENDS rlparse.lm + COMMAND colm::colm + ARGS -I.. -c -b rlparseCSharp + -o "${CMAKE_CURRENT_BINARY_DIR}/rlparse.c" + -m "${CMAKE_CURRENT_BINARY_DIR}/rlreduce.cc" + rlparse.lm + WORKING_DIRECTORY "${CMAKE_CURRENT_LIST_DIR}") + +add_custom_command(OUTPUT + "${CMAKE_CURRENT_BINARY_DIR}/rlhc.c" + DEPENDS rlhc.lm + COMMAND colm::colm + ARGS -I.. -c -b rlhcCSharp + -o "${CMAKE_CURRENT_BINARY_DIR}/rlhc.c" + rlhc.lm + WORKING_DIRECTORY "${CMAKE_CURRENT_LIST_DIR}") + +add_executable(ragel-csharp main.cc + "${CMAKE_CURRENT_BINARY_DIR}/rlhc.c" + "${CMAKE_CURRENT_BINARY_DIR}/rlparse.c" + "${CMAKE_CURRENT_BINARY_DIR}/rlreduce.cc") + +target_link_libraries(ragel-csharp PRIVATE libragel libfsm) + +if(${PROJECT_NAME}_MAKE_INSTALL) + install(TARGETS ragel-csharp + EXPORT ${_PACKAGE_NAME}-targets + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" + LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" + ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}") +endif() |