45 lines · plain
1# For a better template to copy, see examples/standalone2include_directories(include)3add_subdirectory(include)4 5set(LLVM_LINK_COMPONENTS6 Support7 )8 9set(LLVM_TARGET_DEFINITIONS mlir/ToyCombine.td)10mlir_tablegen(ToyCombine.inc -gen-rewriters)11add_public_tablegen_target(ToyCh5CombineIncGen)12 13add_toy_chapter(toyc-ch514 toyc.cpp15 parser/AST.cpp16 mlir/MLIRGen.cpp17 mlir/Dialect.cpp18 mlir/LowerToAffineLoops.cpp19 mlir/ShapeInferencePass.cpp20 mlir/ToyCombine.cpp21 22 DEPENDS23 ToyCh5ShapeInferenceInterfaceIncGen24 ToyCh5OpsIncGen25 ToyCh5CombineIncGen26 )27 28include_directories(${CMAKE_CURRENT_BINARY_DIR})29include_directories(${CMAKE_CURRENT_BINARY_DIR}/include/)30target_link_libraries(toyc-ch531 PRIVATE32 MLIRAnalysis33 MLIRCallInterfaces34 MLIRCastInterfaces35 MLIRFunctionInterfaces36 MLIRIR37 MLIRParser38 MLIRPass39 MLIRRegisterAllDialects40 MLIRRegisterAllExtensions41 MLIRSideEffectInterfaces42 MLIRSupport43 MLIRTransforms44 )45