add_subdirectory(include) set(LLVM_LINK_COMPONENTS Support ) add_toy_chapter(toyc-ch2 toyc.cpp parser/AST.cpp mlir/MLIRGen.cpp mlir/Dialect.cpp ) include_directories(include/) include_directories(${CMAKE_CURRENT_BINARY_DIR}/include/) add_dependencies(toyc-ch2 ToyCh2OpsIncGen) target_link_libraries(toyc-ch2 PRIVATE MLIRAnalysis MLIRIR MLIRParser MLIRTransforms)