CMakeLists.txt
changeset 12249 4f358c108da1
parent 12248 a65c2e471570
child 12257 d7a3aac08fc1
     1.1 --- a/CMakeLists.txt	Fri Sep 28 11:30:50 2018 +0300
     1.2 +++ b/CMakeLists.txt	Fri Sep 28 13:41:04 2018 +0300
     1.3 @@ -1212,6 +1212,11 @@
     1.4      set(CMAKE_REQUIRED_FLAGS ${ORIG_CMAKE_REQUIRED_FLAGS})
     1.5    endif()
     1.6  
     1.7 +  # headers needed elsewhere ...
     1.8 +  check_include_file(mmdeviceapi.h HAVE_MMDEVICEAPI_H)
     1.9 +  check_include_file(audioclient.h HAVE_AUDIOCLIENT_H)
    1.10 +  check_include_file(endpointvolume.h HAVE_ENDPOINTVOLUME_H)
    1.11 +
    1.12    if(SDL_AUDIO)
    1.13      set(SDL_AUDIO_DRIVER_WINMM 1)
    1.14      file(GLOB WINMM_AUDIO_SOURCES ${SDL2_SOURCE_DIR}/src/audio/winmm/*.c)
    1.15 @@ -1224,10 +1229,6 @@
    1.16        set(SOURCE_FILES ${SOURCE_FILES} ${DSOUND_AUDIO_SOURCES})
    1.17      endif()
    1.18  
    1.19 -    # headers needed for WASAPI support:
    1.20 -    check_include_file(mmdeviceapi.h HAVE_MMDEVICEAPI_H)
    1.21 -    check_include_file(audioclient.h HAVE_AUDIOCLIENT_H)
    1.22 -
    1.23      if(WASAPI AND HAVE_AUDIOCLIENT_H AND HAVE_MMDEVICEAPI_H)
    1.24        set(SDL_AUDIO_DRIVER_WASAPI 1)
    1.25        file(GLOB WASAPI_AUDIO_SOURCES ${SDL2_SOURCE_DIR}/src/audio/wasapi/*.c)