Fix cmake so it is possible to build without bluetooth support, and the typo that tells you bluetooth is enabled when it is not.
Fixes issue 3464. Also make the check for portaudio really check the version of portaudio. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6359 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
2e0274dd1f
commit
57f01776ef
|
@ -125,7 +125,7 @@ if(BLUEZ_FOUND)
|
|||
message("bluez found, enabling bluetooth support")
|
||||
else()
|
||||
add_definitions(-DHAVE_BLUEZ=0)
|
||||
message("bluez NOT found, enabling bluetooth support")
|
||||
message("bluez NOT found, disabling bluetooth support")
|
||||
endif(BLUEZ_FOUND)
|
||||
|
||||
include_directories(${OPENGL_INCLUDE_DIR})
|
||||
|
@ -185,13 +185,14 @@ else()
|
|||
message("Xrandr NOT found")
|
||||
endif(XRANDR_FOUND)
|
||||
|
||||
find_library(PORTAUDIO portaudio)
|
||||
include(CheckCXXSourceRuns)
|
||||
set(CMAKE_REQUIRED_LIBRARIES portaudio)
|
||||
CHECK_CXX_SOURCE_RUNS(
|
||||
"#include <portaudio.h>
|
||||
int main(int argc, char **argv)
|
||||
{ if(Pa_GetVersion() >= 1890) return 0; else return 1; }"
|
||||
PORTAUDIO)
|
||||
if(PORTAUDIO)
|
||||
include(CheckFunctionExists)
|
||||
set(CMAKE_REQUIRED_LIBRARIES portaudio)
|
||||
CHECK_FUNCTION_EXISTS(Pa_GetVersion PORTAUDIO_VERSION_CHECK)
|
||||
endif(PORTAUDIO)
|
||||
if(PORTAUDIO AND PORTAUDIO_VERSION_CHECK)
|
||||
message("PortAudio found, enabling mic support")
|
||||
add_definitions(-DHAVE_PORTAUDIO=1)
|
||||
set(PORTAUDIO_FOUND TRUE)
|
||||
|
@ -199,7 +200,7 @@ else()
|
|||
message("PortAudio not found, disabling mic support")
|
||||
add_definitions(-DHAVE_PORTAUDIO=0)
|
||||
set(PORTAUDIO_FOUND FALSE)
|
||||
endif(PORTAUDIO AND PORTAUDIO_VERSION_CHECK)
|
||||
endif(PORTAUDIO)
|
||||
|
||||
find_library(OPENCL OpenCL)
|
||||
find_path(OPENCL_INCLUDE CL/cl.h)
|
||||
|
|
|
@ -3,11 +3,13 @@ set(SRCS Src/ir.c
|
|||
|
||||
if(APPLE)
|
||||
set(SRCS ${SRCS} Src/io_osx.m)
|
||||
elseif(UNIX)
|
||||
elseif(UNIX AND BLUEZ_FOUND)
|
||||
set(SRCS ${SRCS} Src/io_nix.c)
|
||||
set(LIBS ${LIBS} bluetooth)
|
||||
elseif(WIN32)
|
||||
set(SRCS ${SRCS} Src/io_win.c)
|
||||
else()
|
||||
set(SRCS ${SRCS} Src/io_dummy.c)
|
||||
endif()
|
||||
|
||||
add_library(wiiuse STATIC ${SRCS})
|
||||
|
|
|
@ -27,9 +27,9 @@ if(wxWidgets_FOUND)
|
|||
endif(wxWidgets_FOUND)
|
||||
|
||||
if(APPLE AND NOT wxWidgets_FOUND)
|
||||
set(SRCS ${SRCS} cocoaGL.m)
|
||||
set(SRCS ${SRCS} Src/cocoaGL.m)
|
||||
elseif(WIN32)
|
||||
set(SRCS ${SRCS} OS/Win32.cpp)
|
||||
set(SRCS ${SRCS} Src/OS/Win32.cpp)
|
||||
elseif(NOT APPLE AND OPENCL_FOUND)
|
||||
set(LIBS ${LIBS} OpenCL)
|
||||
endif()
|
||||
|
|
Loading…
Reference in New Issue