summaryrefslogtreecommitdiff
path: root/gui/CMakeLists.txt
diff options
context:
space:
mode:
authorbd <bdunahu@operationnull.com>2025-03-24 12:17:41 -0400
committerbd <bdunahu@operationnull.com>2025-03-24 12:17:41 -0400
commit895b5ddd6fe4db906720ecbf0de0cab5acdb35ec (patch)
tree8d2d9df8054214d4c019ace03e33f74e6ba571d0 /gui/CMakeLists.txt
parente05f5306f50029b0f5f471b70cfe45749d0d21f6 (diff)
Added gui folder with its own CMake to house GUI+main.cc
Diffstat (limited to 'gui/CMakeLists.txt')
-rw-r--r--gui/CMakeLists.txt30
1 files changed, 30 insertions, 0 deletions
diff --git a/gui/CMakeLists.txt b/gui/CMakeLists.txt
new file mode 100644
index 0000000..6b5eb22
--- /dev/null
+++ b/gui/CMakeLists.txt
@@ -0,0 +1,30 @@
+cmake_minimum_required(VERSION 3.5)
+set(CMAKE_CXX_COMPILER "g++")
+
+add_compile_options(-Wall -lstdc++)
+add_compile_options(-Wextra -Wpedantic)
+
+# cpp standard
+set(CMAKE_CXX_STANDARD 17)
+set(CMAKE_CXX_STANDARD_REQUIRED ON)
+
+# find QT components
+find_package(Qt6 COMPONENTS Widgets REQUIRED)
+qt_standard_project_setup()
+
+file(GLOB SRCS
+ "*.h"
+ "*.cc"
+ "*.ui"
+)
+
+# gather gui source files
+qt_add_resources(GUI_RESOURCES "resources.qrc")
+
+add_executable(risc_vector ${SRCS} ${GUI_RESOURCES})
+target_link_libraries(${PROJECT_NAME} PRIVATE ${PROJECT_NAME}_lib Qt6::Widgets)
+
+set_target_properties(risc_vector PROPERTIES
+ RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}"
+)
+