Main coves client
1cmake_minimum_required(VERSION 3.14)
2project(runner LANGUAGES CXX)
3
4# Define the application target. To change its name, change BINARY_NAME in the
5# top-level CMakeLists.txt, not the value here, or `flutter run` will no longer
6# work.
7#
8# Any new source files that you add to the application should be added here.
9add_executable(${BINARY_NAME} WIN32
10 "flutter_window.cpp"
11 "main.cpp"
12 "utils.cpp"
13 "win32_window.cpp"
14 "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
15 "Runner.rc"
16 "runner.exe.manifest"
17)
18
19# Apply the standard set of build settings. This can be removed for applications
20# that need different build settings.
21apply_standard_settings(${BINARY_NAME})
22
23# Add preprocessor definitions for the build version.
24target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION=\"${FLUTTER_VERSION}\"")
25target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MAJOR=${FLUTTER_VERSION_MAJOR}")
26target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MINOR=${FLUTTER_VERSION_MINOR}")
27target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_PATCH=${FLUTTER_VERSION_PATCH}")
28target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_BUILD=${FLUTTER_VERSION_BUILD}")
29
30# Disable Windows macros that collide with C++ standard library functions.
31target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX")
32
33# Add dependency libraries and include directories. Add any application-specific
34# dependencies here.
35target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app)
36target_link_libraries(${BINARY_NAME} PRIVATE "dwmapi.lib")
37target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}")
38
39# Run the Flutter tool portions of the build. This must not be removed.
40add_dependencies(${BINARY_NAME} flutter_assemble)