Haojian Wu fe66aebd75 [pseudo] Define a clangPseudoCLI library.
- define a common data structure Language which is a compiled result of the
  bnf grammar. It is defined in Language.h;
- creates a clangPseudoCLI lib which defines a grammar commandline flag and
  expose a function to get the Language. It supports --grammar=cxx,
  --grammmar=/path/to/file.bnf;
- use the clangPseudoCLI in clang-pseudo, fuzzer, and benchmark tools (
  simplify the code and use the prebuilt cxx grammar);

Split out from https://reviews.llvm.org/D127448.

Differential Revision: https://reviews.llvm.org/D128679
2022-07-01 08:31:34 +02:00

17 lines
236 B
CMake

set(LLVM_LINK_COMPONENTS
FuzzerCLI
Support
)
add_llvm_fuzzer(clang-pseudo-fuzzer
Fuzzer.cpp
DUMMY_MAIN Main.cpp
)
target_link_libraries(clang-pseudo-fuzzer
PRIVATE
clangPseudo
clangPseudoCLI
clangPseudoGrammar
)