You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
9 lines
401 B
9 lines
401 B
3 years ago
|
enable_language(CXX)
|
||
|
|
||
|
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/dummy_executable.cpp" "int main(int,char**) { return 0; }\n")
|
||
|
add_executable(executableTarget "${CMAKE_CURRENT_BINARY_DIR}/dummy_executable.cpp")
|
||
|
add_executable(aliasTarget ALIAS executableTarget)
|
||
|
|
||
|
cmake_policy(SET CMP0070 NEW)
|
||
|
file(GENERATE OUTPUT TARGET_NAME_IF_EXISTS-generated-alias.txt CONTENT "$<TARGET_NAME_IF_EXISTS:aliasTarget>")
|