diff options
| author | Ahmad Fatoum <[email protected]> | 2018-07-27 18:17:18 +0200 |
|---|---|---|
| committer | Ahmad Fatoum <[email protected]> | 2018-07-29 12:13:00 +0200 |
| commit | 69e147417b68c4d650e0a87be07bc7d96824229b (patch) | |
| tree | 88b38cf827a06c5715df3059190f94d5ae4b8b21 /cmake | |
| parent | cf021e38117723b655a2399e62f8d5f87ce3d413 (diff) | |
| download | raylib-69e147417b68c4d650e0a87be07bc7d96824229b.tar.gz raylib-69e147417b68c4d650e0a87be07bc7d96824229b.zip | |
Travis CI: Add OpenAL-Configuration
Diffstat (limited to 'cmake')
| -rw-r--r-- | cmake/utils.cmake | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/cmake/utils.cmake b/cmake/utils.cmake index 417384ad..57829407 100644 --- a/cmake/utils.cmake +++ b/cmake/utils.cmake @@ -3,8 +3,10 @@ cmake_minimum_required(VERSION 2.8.0) add_definitions("-DRAYLIB_CMAKE=1") -# Linking for OS X -framework options -# Will do nothing on other OSes +if (${USE_OPENAL_BACKEND}) + find_package(OpenAL REQUIRED) +endif() + if(${PLATFORM} MATCHES "Android") find_library(OPENGL_LIBRARY OpenGL) set(LIBS_PRIVATE m log android EGL GLESv2 OpenSLES atomic c) @@ -22,8 +24,6 @@ else() set(OPENGL_LIBRARIES "GL") endif() - include_directories(${OPENGL_INCLUDE_DIR}) - if ("${CMAKE_SYSTEM_NAME}" MATCHES "(Net|Open)BSD") find_library(OSS_LIBRARY ossaudio) endif() @@ -31,6 +31,9 @@ else() set(LIBS_PRIVATE m pthread ${OPENGL_LIBRARIES} ${OSS_LIBRARY}) endif() +include_directories(${OPENGL_INCLUDE_DIR} ${OPENAL_INCLUDE_DIR}) +set(LIBS_PRIVATE ${LIBS_PRIVATE} ${OPENAL_LIBRARY}) + if(${PLATFORM} MATCHES "Desktop") if(USE_EXTERNAL_GLFW STREQUAL "ON") find_package(glfw3 3.2.1 REQUIRED) |
