diff options
| author | Maarten ter Huurne <maarten@treewalker.org> | 2011-12-17 16:30:02 +0100 |
|---|---|---|
| committer | Maarten ter Huurne <maarten@treewalker.org> | 2011-12-17 16:30:02 +0100 |
| commit | ed1bfdf29360ec96bf8333b373dd526b7483d869 (patch) | |
| tree | 138a9b326f1c5292d675a275e33f88f7350a7910 /Source/Core/AudioCommon | |
| parent | a58c46be814398fa44bdbe92453d547f0becced4 (diff) | |
| parent | 83bf5790a66363d445b4e4e53cba91c260781e75 (diff) | |
Merge branch 'cmake-osx2'
Diffstat (limited to 'Source/Core/AudioCommon')
| -rw-r--r-- | Source/Core/AudioCommon/CMakeLists.txt | 50 | ||||
| -rw-r--r-- | Source/Core/AudioCommon/Src/aldlist.cpp | 3 |
2 files changed, 28 insertions, 25 deletions
diff --git a/Source/Core/AudioCommon/CMakeLists.txt b/Source/Core/AudioCommon/CMakeLists.txt index 51476a6ea6..be8c58d14a 100644 --- a/Source/Core/AudioCommon/CMakeLists.txt +++ b/Source/Core/AudioCommon/CMakeLists.txt @@ -6,33 +6,33 @@ set(SRCS Src/AudioCommon.cpp set(LIBS "") +if(ALSA_FOUND) + set(SRCS ${SRCS} Src/AlsaSoundStream.cpp) + set(LIBS ${LIBS} ${ALSA_LIBRARIES}) +endif(ALSA_FOUND) + +if(AO_FOUND) + set(SRCS ${SRCS} Src/AOSoundStream.cpp) + set(LIBS ${LIBS} ${AO_LIBRARIES}) +endif(AO_FOUND) + +if(OPENAL_FOUND) + set(SRCS ${SRCS} Src/OpenALStream.cpp Src/aldlist.cpp) + set(LIBS ${LIBS} ${OPENAL_LIBRARY}) +endif(OPENAL_FOUND) + +if(PULSEAUDIO_FOUND) + set(SRCS ${SRCS} Src/PulseAudioStream.cpp) + set(LIBS ${LIBS} ${PULSEAUDIO_LIBRARIES}) +endif(PULSEAUDIO_FOUND) + +if(WIN32) + set(SRCS ${SRCS} Src/DSoundStream.cpp) + set(SRCS ${SRCS} Src/XAudio2Stream.cpp) +endif(WIN32) + if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") set(SRCS ${SRCS} Src/CoreAudioSoundStream.cpp) -else() - if(ALSA_FOUND) - set(SRCS ${SRCS} Src/AlsaSoundStream.cpp) - set(LIBS ${LIBS} ${ALSA_LIBRARIES}) - endif(ALSA_FOUND) - - if(AO_FOUND) - set(SRCS ${SRCS} Src/AOSoundStream.cpp) - set(LIBS ${LIBS} ${AO_LIBRARIES}) - endif(AO_FOUND) - - if(OPENAL_FOUND) - set(SRCS ${SRCS} Src/OpenALStream.cpp Src/aldlist.cpp) - set(LIBS ${LIBS} openal) - endif(OPENAL_FOUND) - - if(PULSEAUDIO_FOUND) - set(SRCS ${SRCS} Src/PulseAudioStream.cpp) - set(LIBS ${LIBS} ${PULSEAUDIO_LIBRARIES}) - endif(PULSEAUDIO_FOUND) - - if(WIN32) - set(SRCS ${SRCS} Src/DSoundStream.cpp) - set(SRCS ${SRCS} Src/XAudio2Stream.cpp) - endif(WIN32) endif() add_library(audiocommon STATIC ${SRCS}) diff --git a/Source/Core/AudioCommon/Src/aldlist.cpp b/Source/Core/AudioCommon/Src/aldlist.cpp index 2008842486..69d42148ae 100644 --- a/Source/Core/AudioCommon/Src/aldlist.cpp +++ b/Source/Core/AudioCommon/Src/aldlist.cpp @@ -27,6 +27,9 @@ #ifdef _WIN32 #include "../../../../Externals/OpenAL/include/al.h" #include "../../../../Externals/OpenAL/include/alc.h" +#elif defined(__APPLE__) +#include <al.h> +#include <alc.h> #else #include <AL/al.h> #include <AL/alc.h> |
