Support build with OpenAL-Soft on Windows

This commit is contained in:
kaetemi 2019-05-01 10:17:44 +08:00
parent 1c422390e7
commit a249fcbab3
2 changed files with 11 additions and 8 deletions

View file

@ -36,8 +36,11 @@ NL_ADD_LIB_SUFFIX(${NLDRV_AL_LIB})
IF(WIN32)
# Find and include EFX-Util on Windows.
FIND_PACKAGE(EFXUtil)
IF(EFXUTIL_FOUND)
INCLUDE_DIRECTORIES(${EFXUTIL_INCLUDE_DIR})
TARGET_LINK_LIBRARIES(${NLDRV_AL_LIB} ${EFXUTIL_LIBRARY})
ADD_DEFINITIONS(-DEFX_CREATIVE_AVAILABLE=1)
ENDIF()
ENDIF()
IF(WITH_PCH)

View file

@ -17,11 +17,11 @@
#ifndef NL_EXT_AL_H
#define NL_EXT_AL_H
#ifdef NL_OS_WINDOWS
# define EFX_CREATIVE_AVAILABLE 1
# define EAX_AVAILABLE 0
#else
#ifndef EFX_CREATIVE_AVAILABLE
#define EFX_CREATIVE_AVAILABLE 0
#endif
#ifndef EAX_AVAILABLE
#define EAX_AVAILABLE 0
#endif