Tokenize the input with flex
This commit is contained in:
@@ -6,11 +6,14 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
||||
find_package(Boost COMPONENTS program_options REQUIRED)
|
||||
find_package(FLEX)
|
||||
include_directories(${Boost_INCLUDE_DIR})
|
||||
|
||||
add_executable(tester tests/tester.cpp include/elna/tester.hpp)
|
||||
target_include_directories(tester PRIVATE include)
|
||||
|
||||
FLEX_TARGET(scanner source/scanner.l ${CMAKE_CURRENT_BINARY_DIR}/scanner.cpp)
|
||||
|
||||
add_executable(elnsh shell/main.cpp
|
||||
shell/interactive.cpp include/elna/shell/interactive.hpp
|
||||
shell/history.cpp include/elna/shell/history.hpp
|
||||
@@ -26,6 +29,7 @@ add_executable(elna cli/main.cpp
|
||||
backend/riscv.cpp include/elna/backend/riscv.hpp
|
||||
backend/target.cpp include/elna/backend/target.hpp
|
||||
cli/cl.cpp include/elna/cli/cl.hpp
|
||||
${FLEX_scanner_OUTPUTS}
|
||||
)
|
||||
target_include_directories(elna PRIVATE include)
|
||||
target_link_libraries(elna LINK_PUBLIC ${Boost_LIBRARIES})
|
||||
|
||||
Reference in New Issue
Block a user