Browse Source

Platform: add helpful error messages to application test build files.

pull/580/head
Vladimír Vondruš 4 years ago
parent
commit
9297cd74ab
  1. 6
      src/Magnum/Platform/Test/CMakeLists.txt

6
src/Magnum/Platform/Test/CMakeLists.txt

@ -85,6 +85,9 @@ if(MAGNUM_WITH_GLFWAPPLICATION)
# HiDPi.manifest not needed, as GLFW sets that on its own # HiDPi.manifest not needed, as GLFW sets that on its own
target_link_libraries(PlatformGlfwApplicationTest PRIVATE MagnumGlfwApplication Corrade::Main) target_link_libraries(PlatformGlfwApplicationTest PRIVATE MagnumGlfwApplication Corrade::Main)
# Window icon loading # Window icon loading
if(NOT MAGNUM_WITH_TRADE)
message(FATAL_ERROR "GlfwApplication tests need the Trade library enabled")
endif()
target_sources(PlatformGlfwApplicationTest PRIVATE ${Platform_RESOURCES}) target_sources(PlatformGlfwApplicationTest PRIVATE ${Platform_RESOURCES})
target_link_libraries(PlatformGlfwApplicationTest PRIVATE MagnumTrade) target_link_libraries(PlatformGlfwApplicationTest PRIVATE MagnumTrade)
if(CORRADE_TARGET_APPLE) if(CORRADE_TARGET_APPLE)
@ -112,6 +115,9 @@ if(MAGNUM_WITH_SDL2APPLICATION)
endif() endif()
target_link_libraries(PlatformSdl2ApplicationTest PRIVATE MagnumSdl2Application Corrade::Main) target_link_libraries(PlatformSdl2ApplicationTest PRIVATE MagnumSdl2Application Corrade::Main)
# Window icon loading # Window icon loading
if(NOT MAGNUM_WITH_TRADE)
message(FATAL_ERROR "GlfwApplication tests need the Trade library enabled")
endif()
if(NOT CORRADE_TARGET_EMSCRIPTEN) if(NOT CORRADE_TARGET_EMSCRIPTEN)
target_sources(PlatformSdl2ApplicationTest PRIVATE ${Platform_RESOURCES}) target_sources(PlatformSdl2ApplicationTest PRIVATE ${Platform_RESOURCES})
target_link_libraries(PlatformSdl2ApplicationTest PRIVATE MagnumTrade) target_link_libraries(PlatformSdl2ApplicationTest PRIVATE MagnumTrade)

Loading…
Cancel
Save