CMakeLists.txt 974 B

1234567891011121314151617181920212223242526
  1. cmake_minimum_required(VERSION 3.13)
  2. project(runner LANGUAGES CXX)
  3. # Define the application target. To change its name, change BINARY_NAME in the
  4. # top-level CMakeLists.txt, not the value here, or `flutter run` will no longer
  5. # work.
  6. #
  7. # Any new source files that you add to the application should be added here.
  8. add_executable(${BINARY_NAME}
  9. "main.cc"
  10. "my_application.cc"
  11. "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc"
  12. )
  13. # Apply the standard set of build settings. This can be removed for applications
  14. # that need different build settings.
  15. apply_standard_settings(${BINARY_NAME})
  16. # Add preprocessor definitions for the application ID.
  17. add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}")
  18. # Add dependency libraries. Add any application-specific dependencies here.
  19. target_link_libraries(${BINARY_NAME} PRIVATE flutter)
  20. target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK)
  21. target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}")