From fc094e2dbca2c352cf42a38048aed17db1f15b7e Mon Sep 17 00:00:00 2001 From: lethosor Date: Tue, 21 Jul 2015 16:26:41 -0400 Subject: [PATCH] OS X: Check for existence of SDL.framework before building --- library/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt index 845f8dd07..16cf03d1a 100644 --- a/library/CMakeLists.txt +++ b/library/CMakeLists.txt @@ -298,6 +298,9 @@ SET_TARGET_PROPERTIES(dfhack PROPERTIES DEBUG_POSTFIX "-debug" ) IF(APPLE) SET(SDL_LIBRARY ${CMAKE_INSTALL_PREFIX}/libs/SDL.framework) + IF(NOT EXISTS ${SDL_LIBRARY}) + MESSAGE(FATAL_ERROR "SDL framework not found. Make sure CMAKE_INSTALL_PREFIX is specified and correct.") + ENDIF() SET(CXX_LIBRARY ${CMAKE_INSTALL_PREFIX}/libs/libstdc++.6.dylib) SET(ZIP_LIBRARY /usr/lib/libz.dylib) TARGET_LINK_LIBRARIES(dfhack ${SDL_LIBRARY})