1
0

CMakeLists.txt 438 B

1234567891011
  1. # a target with the same name as a target in a different dir
  2. ADD_EXECUTABLE(mytest_exe conly.c)
  3. SET_TARGET_PROPERTIES(mytest_exe PROPERTIES OUTPUT_NAME mytest)
  4. TARGET_LINK_LIBRARIES(mytest_exe mytest)
  5. # and two targets in the same dir with the same name
  6. ADD_LIBRARY(mytest2 ../Lib1/libc1.c)
  7. ADD_EXECUTABLE(mytest2_exe conly.c)
  8. SET_TARGET_PROPERTIES(mytest2_exe PROPERTIES OUTPUT_NAME mytest2)
  9. TARGET_LINK_LIBRARIES(mytest2_exe mytest2)