aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorseptag <[email protected]>2016-11-03 01:52:40 +0330
committerseptag <[email protected]>2016-11-03 01:52:40 +0330
commitac26b209a6c3e19a85e3ca960c29f49939aa73bc (patch)
tree1b5a4251f463c0f27efb0dbf8df8d0bf3f9631af
parentd142ba1ab4d5d63f166f9236da21460ec90ce9bd (diff)
fixed minor check in FindDSound.cmake
-rw-r--r--cmake/FindDSound.cmake10
1 files changed, 6 insertions, 4 deletions
diff --git a/cmake/FindDSound.cmake b/cmake/FindDSound.cmake
index 70e94269..4078deb5 100644
--- a/cmake/FindDSound.cmake
+++ b/cmake/FindDSound.cmake
@@ -10,21 +10,23 @@
if (WIN32)
include(FindWindowsSDK)
- get_windowssdk_library_dirs(${WINDOWSSDK_PREFERRED_DIR} WINSDK_LIB_DIRS)
- get_windowssdk_include_dirs(${WINDOWSSDK_PREFERRED_DIR} WINSDK_INCLUDE_DIRS)
+ if (WINDOWSSDK_FOUND)
+ get_windowssdk_library_dirs(${WINDOWSSDK_PREFERRED_DIR} WINSDK_LIB_DIRS)
+ get_windowssdk_include_dirs(${WINDOWSSDK_PREFERRED_DIR} WINSDK_INCLUDE_DIRS)
+ endif()
endif()
# DSOUND_INCLUDE_DIR
find_path(DSOUND_INCLUDE_DIR
NAMES "dsound.h"
- PATHS ${WINSDK_INCLUDE_DIRS} "${DXSDK_DIR}"
+ PATHS "${DXSDK_DIR}" ${WINSDK_INCLUDE_DIRS}
PATH_SUFFIXES include
DOC "The DirectSound include directory")
# DSOUND_LIBRARY
find_library(DSOUND_LIBRARY
NAMES dsound
- PATHS ${WINSDK_LIB_DIRS} "${DXSDK_DIR}"
+ PATHS "${DXSDK_DIR}" ${WINSDK_LIB_DIRS}
PATH_SUFFIXES lib lib/x86 lib/x64
DOC "The DirectSound library")