Skip to content

Commit

Permalink
build: CMake tweaks (#2015)
Browse files Browse the repository at this point in the history
  • Loading branch information
trisyoungs authored Nov 19, 2024
1 parent 9f77678 commit 6130ea2
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
4 changes: 0 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ endif()
# Find includes in corresponding build directories
set(CMAKE_INCLUDE_CURRENT_DIR ON)

# Make sure CMake won't try to generate rules for moc (we will do it ourselves)
set(CMAKE_AUTOMOC ON)

# Set policy for automatic linkage of Qt libs to project
cmake_policy(SET CMP0020 NEW)

Expand Down Expand Up @@ -136,7 +133,6 @@ if(GUI)
QuickControls2
REQUIRED
)
add_definitions(-DQT_NO_KEYWORDS)

# Make sure we enable automated handling of Qt files
set(CMAKE_AUTOMOC ON)
Expand Down
2 changes: 1 addition & 1 deletion src/gui-qml/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Target 'gui'
add_library(gui-qml)

target_include_directories(gui-qml PRIVATE ${PROJECT_SOURCE_DIR}/src ${PROJECT_BINARY_DIR}/src Qt6::Core)
target_include_directories(gui-qml PRIVATE ${PROJECT_SOURCE_DIR}/src ${PROJECT_BINARY_DIR}/src)

target_link_libraries(gui-qml PRIVATE models base Qt6::QuickWidgets)
8 changes: 4 additions & 4 deletions src/gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ target_include_directories(
gui
PRIVATE ${PROJECT_SOURCE_DIR}/src
${PROJECT_BINARY_DIR}/src
${Qt6Widgets_INCLUDE_DIRS}
${FREETYPE_INCLUDE_DIRS}
Qt6::OpenGL
Qt6::OpenGLWidgets
Qt6::Core
${Qt6Core_INCLUDE_DIRS}
${Qt6OpenGL_INCLUDE_DIRS}
${Qt6OpenGLWidgets_INCLUDE_DIRS}
${Qt6Widgets_INCLUDE_DIRS}
)

target_link_libraries(
Expand Down

0 comments on commit 6130ea2

Please sign in to comment.