+ # With VS 2011 and Windows 8 SDK, the DirectX SDK is included as part of
+ # the Windows SDK.
+ #
+ # See also:
+ # - http://msdn.microsoft.com/en-us/library/windows/desktop/ee663275.aspx
+ # TODO: Allow using DirectX SDK with VS 2011
+ if (DEFINED MSVC_VERSION AND NOT ${MSVC_VERSION} LESS 1700)
+ find_path (WIN8_SDK_ROOT_DIR
+ Include/um/windows.h
+ PATHS
+ "$ENV{ProgramFiles}/Windows Kits/8.0"
+ "$ENV{ProgramFiles(x86)}/Windows Kits/8.0"
+ DOC "Windows 8 SDK root directory"
+ )
+
+ if (WIN8_SDK_ROOT_DIR)
+ set (DirectX_INC_SEARCH_PATH "${WIN8_SDK_ROOT_DIR}/Include/um" "${WIN8_SDK_ROOT_DIR}/Include/shared")
+ set (DirectX_LIB_SEARCH_PATH "${WIN8_SDK_ROOT_DIR}/Lib/Win8/um/${DirectX_ARCHITECTURE}")
+ set (DirectX_BIN_SEARCH_PATH "${WIN8_SDK_ROOT_DIR}/bin/x86")
+ endif ()