[clang][modules] Don't prevent translation of FW_Private includes when explicitly...
[llvm-project.git] / mlir / examples / toy / Ch7 / CMakeLists.txt
blob362ab512b6b2e5da35fa2aa9dd1cea825db0c098
1 # This chapter depends on JIT support enabled.
2 if(NOT MLIR_ENABLE_EXECUTION_ENGINE)
3   return()
4 endif()
6 # For a better template to copy, see examples/standalone
7 include_directories(include)
8 add_subdirectory(include)
10 set(LLVM_LINK_COMPONENTS
11   Core
12   Support
13   nativecodegen
14   OrcJIT
15   )
17 set(LLVM_TARGET_DEFINITIONS mlir/ToyCombine.td)
18 mlir_tablegen(ToyCombine.inc -gen-rewriters)
19 add_public_tablegen_target(ToyCh7CombineIncGen)
21 add_toy_chapter(toyc-ch7
22   toyc.cpp
23   parser/AST.cpp
24   mlir/MLIRGen.cpp
25   mlir/Dialect.cpp
26   mlir/LowerToAffineLoops.cpp
27   mlir/LowerToLLVM.cpp
28   mlir/ShapeInferencePass.cpp
29   mlir/ToyCombine.cpp
31   DEPENDS
32   ToyCh7ShapeInferenceInterfaceIncGen
33   ToyCh7OpsIncGen
34   ToyCh7CombineIncGen
35   )
37 include_directories(${CMAKE_CURRENT_BINARY_DIR})
38 include_directories(${CMAKE_CURRENT_BINARY_DIR}/include/)
39 get_property(dialect_libs GLOBAL PROPERTY MLIR_DIALECT_LIBS)
40 get_property(conversion_libs GLOBAL PROPERTY MLIR_CONVERSION_LIBS)
41 get_property(extension_libs GLOBAL PROPERTY MLIR_EXTENSION_LIBS)
42 target_link_libraries(toyc-ch7
43   PRIVATE
44     ${dialect_libs}
45     ${conversion_libs}
46     ${extension_libs}
47     MLIRAnalysis
48     MLIRBuiltinToLLVMIRTranslation
49     MLIRCallInterfaces
50     MLIRCastInterfaces
51     MLIRExecutionEngine
52     MLIRFunctionInterfaces
53     MLIRIR
54     MLIRLLVMCommonConversion
55     MLIRLLVMToLLVMIRTranslation
56     MLIRMemRefDialect
57     MLIRParser
58     MLIRPass
59     MLIRSideEffectInterfaces
60     MLIRTargetLLVMIRExport
61     MLIRTransforms
62     )