ResultTest.cmake 673 B

1234567891011121314151617181920212223
  1. message(STATUS "Testing configuration ${activeConfig}.")
  2. macro(TestExists exeName)
  3. set(exeFile "${dir}/${activeConfig}/${exeName}.exe")
  4. if(${ARGN} EXISTS "${exeFile}")
  5. message(STATUS "File ${exeFile} was correctly found ${ARGN} to exist.")
  6. else()
  7. message(FATAL_ERROR "File ${exeFile} was expected ${ARGN} to exist!")
  8. endif()
  9. endmacro()
  10. TestExists(DefaultBuilt)
  11. TestExists(AlwaysBuilt)
  12. TestExists(NeverBuilt NOT)
  13. foreach(config ${allConfigs})
  14. if(config STREQUAL activeConfig)
  15. TestExists(BuiltIn${config})
  16. TestExists(ExcludedIn${config} NOT)
  17. else()
  18. TestExists(BuiltIn${config} NOT)
  19. TestExists(ExcludedIn${config})
  20. endif()
  21. endforeach()