Tests/RunCMake/CommandLine/EnvGenerator/CMakeLists.txt
raw| 1 | cmake_minimum_required(VERSION 3.14) |
| 2 | project(EnvGenerator C) |
| 3 | if(CMAKE_GENERATOR MATCHES "Visual Studio") |
| 4 | message(STATUS "CMAKE_VS_PLATFORM_NAME='${CMAKE_VS_PLATFORM_NAME}'") |
| 5 | endif() |
| 6 | add_custom_command( |
| 7 | OUTPUT output.txt |
| 8 | COMMAND ${CMAKE_COMMAND} -E echo CustomCommand > output.txt |
| 9 | ) |
| 10 | add_custom_target(CustomTarget ALL DEPENDS output.txt) |