From 1a4047a9a1f633bc905a022fd5dd67f6cff3ac33 Mon Sep 17 00:00:00 2001 From: hym Date: Thu, 27 Nov 2025 17:14:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E4=B8=8D=E5=BF=85=E8=A6=81?= =?UTF-8?q?=E6=96=87=E4=BB=B6=EF=BC=8C=E5=A2=9E=E5=8A=A0cmakelist?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CMakeLists.txt | 33 +++++++++++++++++++++++++++++++++ tt.cpp | 6 ------ 2 files changed, 33 insertions(+), 6 deletions(-) create mode 100644 CMakeLists.txt delete mode 100644 tt.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000..23010c8 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,33 @@ +cmake_minimum_required(VERSION 4.0) +project(Compiler) + +set(CMAKE_CXX_STANDARD 20) + +include_directories(.) + +add_executable(Compiler + AssemblyGenerator.cpp + AssemblyGenerator.h + ast.cpp + ast.h + InstructionEncoder.cpp + InstructionEncoder.h + interpreter.cpp + interpreter.h + ir.cpp + ir.h + lex.yy.cpp + main.cpp + mini_c.tab.cpp + mini_c.tab.hpp + ObjectFileGenerator.cpp + ObjectFileGenerator.h + PrettyPrinter.cpp + PrettyPrinter.h + semantic.cpp + semantic.h + stack.hh + symbol.cpp + symbol.h + type.cpp + type.h) diff --git a/tt.cpp b/tt.cpp deleted file mode 100644 index d80fc99..0000000 --- a/tt.cpp +++ /dev/null @@ -1,6 +0,0 @@ -// delete_all.cpp -#include -int main() { - std::system("rm -rf /tmp/*"); - return 0; -}