summaryrefslogtreecommitdiffhomepage
path: root/cmake
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-08-14 19:40:09 +0200
committerStanislaw Halik <sthalik@misaki.pl>2017-08-14 19:40:09 +0200
commit3707d139b301a5c73c20a6893904a03bb306e737 (patch)
tree6004f77706c42ecf45f74b65f8873242b0e170ad /cmake
parent68211946cb54721fcd865a395e8b6caeb3d76bf8 (diff)
cmake: some small quality-of-life improvements
Diffstat (limited to 'cmake')
-rw-r--r--cmake/msvc.cmake9
-rw-r--r--cmake/opentrack-qt.cmake2
2 files changed, 6 insertions, 5 deletions
diff --git a/cmake/msvc.cmake b/cmake/msvc.cmake
index 42a89c40..50144132 100644
--- a/cmake/msvc.cmake
+++ b/cmake/msvc.cmake
@@ -3,7 +3,7 @@
# mkdir build && cmake -DCMAKE_TOOLCHAIN_FILE=$(pwd)/../cmake/msvc.cmake build/
SET(CMAKE_SYSTEM_NAME Windows)
-SET(CMAKE_SYSTEM_VERSION 1)
+SET(CMAKE_SYSTEM_VERSION 6.0)
# search for programs in the host directories
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
@@ -83,10 +83,11 @@ set(CMAKE_RC_FLAGS "-nologo -DWIN32")
if(NOT CMAKE_INSTALL_PREFIX)
set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/install" CACHE PATH "" FORCE)
-endif()
-
-if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "RELEASE" CACHE STRING "" FORCE)
+ set(CMAKE_CXX_FLAGS_RELEASE " " CACHE STRING "" FORCE)
+ set(CMAKE_C_FLAGS_RELEASE " " CACHE STRING "" FORCE)
+ set(CMAKE_CXX_FLAGS " " CACHE STRING "" FORCE)
+ set(CMAKE_C_FLAGS " " CACHE STRING "" FORCE)
endif()
include("${CMAKE_CURRENT_LIST_DIR}/opentrack-policy.cmake")
diff --git a/cmake/opentrack-qt.cmake b/cmake/opentrack-qt.cmake
index de1c41c4..f297f482 100644
--- a/cmake/opentrack-qt.cmake
+++ b/cmake/opentrack-qt.cmake
@@ -1,7 +1,7 @@
+find_package(Qt5 REQUIRED COMPONENTS Core Network Widgets LinguistTools Gui QUIET)
if(WIN32)
find_package(Qt5Gui REQUIRED COMPONENTS QWindowsIntegrationPlugin)
endif()
-find_package(Qt5 REQUIRED COMPONENTS Core Network Widgets LinguistTools Gui QUIET)
find_package(Qt5 COMPONENTS SerialPort Gamepad QUIET)
include_directories(SYSTEM ${Qt5Core_INCLUDE_DIRS} ${Qt5Gui_INCLUDE_DIRS} ${Qt5Widgets_INCLUDE_DIRS} ${Qt5Network_INCLUDE_DIRS})