[pulse] move detection to module
This commit is contained in:
parent
f06c027824
commit
f977de89e3
@ -509,7 +509,6 @@ endif(APPLE)
|
|||||||
# OpenBSD
|
# OpenBSD
|
||||||
if(OPENBSD)
|
if(OPENBSD)
|
||||||
set(WITH_MANPAGES "ON")
|
set(WITH_MANPAGES "ON")
|
||||||
set(WITH_PULSE "OFF")
|
|
||||||
set(WITH_OSS "OFF")
|
set(WITH_OSS "OFF")
|
||||||
set(WITH_SNDIO "ON")
|
set(WITH_SNDIO "ON")
|
||||||
set(WITH_WAYLAND "OFF")
|
set(WITH_WAYLAND "OFF")
|
||||||
@ -599,10 +598,6 @@ set(SNDIO_FEATURE_TYPE "OPTIONAL")
|
|||||||
set(SNDIO_FEATURE_PURPOSE "sound")
|
set(SNDIO_FEATURE_PURPOSE "sound")
|
||||||
set(SNDIO_FEATURE_DESCRIPTION "OpenBSD audio input/output")
|
set(SNDIO_FEATURE_DESCRIPTION "OpenBSD audio input/output")
|
||||||
|
|
||||||
set(PULSE_FEATURE_TYPE "RECOMMENDED")
|
|
||||||
set(PULSE_FEATURE_PURPOSE "sound")
|
|
||||||
set(PULSE_FEATURE_DESCRIPTION "audio input, audio output and multimedia redirection")
|
|
||||||
|
|
||||||
set(PCSC_FEATURE_TYPE "RECOMMENDED")
|
set(PCSC_FEATURE_TYPE "RECOMMENDED")
|
||||||
set(PCSC_FEATURE_PURPOSE "smart card")
|
set(PCSC_FEATURE_PURPOSE "smart card")
|
||||||
set(PCSC_FEATURE_DESCRIPTION "smart card device redirection")
|
set(PCSC_FEATURE_DESCRIPTION "smart card device redirection")
|
||||||
@ -655,7 +650,6 @@ if(WIN32)
|
|||||||
set(WAYLAND_FEATURE_TYPE "DISABLED")
|
set(WAYLAND_FEATURE_TYPE "DISABLED")
|
||||||
set(OSS_FEATURE_TYPE "DISABLED")
|
set(OSS_FEATURE_TYPE "DISABLED")
|
||||||
set(SNDIO_FEATURE_TYPE "DISABLED")
|
set(SNDIO_FEATURE_TYPE "DISABLED")
|
||||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
|
||||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||||
set(FFMPEG_FEATURE_TYPE "OPTIONAL")
|
set(FFMPEG_FEATURE_TYPE "OPTIONAL")
|
||||||
set(VAAPI_FEATURE_TYPE "DISABLED")
|
set(VAAPI_FEATURE_TYPE "DISABLED")
|
||||||
@ -668,7 +662,6 @@ if(APPLE)
|
|||||||
set(OSS_FEATURE_TYPE "DISABLED")
|
set(OSS_FEATURE_TYPE "DISABLED")
|
||||||
set(SNDIO_FEATURE_TYPE "DISABLED")
|
set(SNDIO_FEATURE_TYPE "DISABLED")
|
||||||
if(IOS)
|
if(IOS)
|
||||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
|
||||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
@ -692,7 +685,6 @@ if(ANDROID)
|
|||||||
set(WAYLAND_FEATURE_TYPE "DISABLED")
|
set(WAYLAND_FEATURE_TYPE "DISABLED")
|
||||||
set(OSS_FEATURE_TYPE "DISABLED")
|
set(OSS_FEATURE_TYPE "DISABLED")
|
||||||
set(SNDIO_FEATURE_TYPE "DISABLED")
|
set(SNDIO_FEATURE_TYPE "DISABLED")
|
||||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
|
||||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||||
set(VAAPI_FEATURE_TYPE "DISABLED")
|
set(VAAPI_FEATURE_TYPE "DISABLED")
|
||||||
endif()
|
endif()
|
||||||
@ -703,7 +695,6 @@ find_feature(OpenSSL ${OPENSSL_FEATURE_TYPE} ${OPENSSL_FEATURE_PURPOSE} ${OPENSS
|
|||||||
find_feature(MbedTLS ${MBEDTLS_FEATURE_TYPE} ${MBEDTLS_FEATURE_PURPOSE} ${MBEDTLS_FEATURE_DESCRIPTION})
|
find_feature(MbedTLS ${MBEDTLS_FEATURE_TYPE} ${MBEDTLS_FEATURE_PURPOSE} ${MBEDTLS_FEATURE_DESCRIPTION})
|
||||||
|
|
||||||
find_feature(OSS ${OSS_FEATURE_TYPE} ${OSS_FEATURE_PURPOSE} ${OSS_FEATURE_DESCRIPTION})
|
find_feature(OSS ${OSS_FEATURE_TYPE} ${OSS_FEATURE_PURPOSE} ${OSS_FEATURE_DESCRIPTION})
|
||||||
find_feature(Pulse ${PULSE_FEATURE_TYPE} ${PULSE_FEATURE_PURPOSE} ${PULSE_FEATURE_DESCRIPTION})
|
|
||||||
|
|
||||||
find_feature(PCSC ${PCSC_FEATURE_TYPE} ${PCSC_FEATURE_PURPOSE} ${PCSC_FEATURE_DESCRIPTION})
|
find_feature(PCSC ${PCSC_FEATURE_TYPE} ${PCSC_FEATURE_PURPOSE} ${PCSC_FEATURE_DESCRIPTION})
|
||||||
|
|
||||||
|
@ -17,15 +17,19 @@
|
|||||||
|
|
||||||
define_channel_client_subsystem("audin" "pulse" "")
|
define_channel_client_subsystem("audin" "pulse" "")
|
||||||
|
|
||||||
|
find_package(PulseAudio REQUIRED)
|
||||||
|
|
||||||
set(${MODULE_PREFIX}_SRCS
|
set(${MODULE_PREFIX}_SRCS
|
||||||
audin_pulse.c)
|
audin_pulse.c)
|
||||||
|
|
||||||
set(${MODULE_PREFIX}_LIBS
|
set(${MODULE_PREFIX}_LIBS
|
||||||
winpr
|
winpr
|
||||||
freerdp
|
freerdp
|
||||||
|
${PULSEAUDIO_LIBRARY}
|
||||||
|
${PULSEAUDIO_MAINLOOP_LIBRARY}
|
||||||
)
|
)
|
||||||
|
|
||||||
include_directories(..)
|
include_directories(..)
|
||||||
include_directories(${PULSE_INCLUDE_DIR})
|
include_directories(${PULSEAUDIO_INCLUDE_DIR})
|
||||||
|
|
||||||
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
||||||
|
@ -17,6 +17,8 @@
|
|||||||
|
|
||||||
define_channel_client_subsystem("rdpsnd" "pulse" "")
|
define_channel_client_subsystem("rdpsnd" "pulse" "")
|
||||||
|
|
||||||
|
find_package(PulseAudio REQUIRED)
|
||||||
|
|
||||||
set(${MODULE_PREFIX}_SRCS
|
set(${MODULE_PREFIX}_SRCS
|
||||||
rdpsnd_pulse.c
|
rdpsnd_pulse.c
|
||||||
)
|
)
|
||||||
@ -24,10 +26,11 @@ set(${MODULE_PREFIX}_SRCS
|
|||||||
set(${MODULE_PREFIX}_LIBS
|
set(${MODULE_PREFIX}_LIBS
|
||||||
winpr
|
winpr
|
||||||
freerdp
|
freerdp
|
||||||
${PULSE_LIBRARY}
|
${PULSEAUDIO_LIBRARY}
|
||||||
|
${PULSEAUDIO_MAINLOOP_LIBRARY}
|
||||||
)
|
)
|
||||||
|
|
||||||
include_directories(..)
|
include_directories(..)
|
||||||
include_directories(${PULSE_INCLUDE_DIR})
|
include_directories(${PULSEAUDIO_INCLUDE_DIR})
|
||||||
|
|
||||||
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
||||||
|
@ -17,16 +17,19 @@
|
|||||||
|
|
||||||
define_channel_client_subsystem("tsmf" "pulse" "audio")
|
define_channel_client_subsystem("tsmf" "pulse" "audio")
|
||||||
|
|
||||||
|
find_package(PulseAudio REQUIRED)
|
||||||
|
|
||||||
set(${MODULE_PREFIX}_SRCS
|
set(${MODULE_PREFIX}_SRCS
|
||||||
tsmf_pulse.c
|
tsmf_pulse.c
|
||||||
)
|
)
|
||||||
|
|
||||||
set(${MODULE_PREFIX}_LIBS
|
set(${MODULE_PREFIX}_LIBS
|
||||||
winpr
|
winpr
|
||||||
${PULSE_LIBRARY}
|
${PULSEAUDIO_LIBRARY}
|
||||||
|
${PULSEAUDIO_MAINLOOP_LIBRARY}
|
||||||
)
|
)
|
||||||
|
|
||||||
include_directories(..)
|
include_directories(..)
|
||||||
include_directories(${PULSE_INCLUDE_DIR})
|
include_directories(${PULSEAUDIO_INCLUDE_DIR})
|
||||||
|
|
||||||
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
||||||
|
@ -1,32 +0,0 @@
|
|||||||
|
|
||||||
find_package(PkgConfig)
|
|
||||||
|
|
||||||
if(PKG_CONFIG_FOUND)
|
|
||||||
pkg_check_modules(PULSE libpulse)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
find_path(PULSE_INCLUDE_DIR pulse/pulseaudio.h PATHS ${PULSE_INCLUDE_DIRS} PATH_SUFFIXES pulse )
|
|
||||||
find_library(PULSE_LIBRARY pulse PATHS ${PULSE_LIBRARY_DIRS})
|
|
||||||
|
|
||||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Pulse DEFAULT_MSG PULSE_INCLUDE_DIR PULSE_LIBRARY)
|
|
||||||
|
|
||||||
if(PULSE_LIBRARY)
|
|
||||||
set(PULSE_FOUND 1)
|
|
||||||
|
|
||||||
file(STRINGS "${PULSE_INCLUDE_DIR}/pulse/version.h" STR1 REGEX "PA_MAJOR")
|
|
||||||
file(STRINGS "${PULSE_INCLUDE_DIR}/pulse/version.h" STR2 REGEX "PA_MINOR")
|
|
||||||
file(STRINGS "${PULSE_INCLUDE_DIR}/pulse/version.h" STR3 REGEX "PA_MICRO")
|
|
||||||
|
|
||||||
string(REGEX MATCHALL "[0-9]+" PULSE_VERSION_MAJOR ${STR1})
|
|
||||||
string(REGEX MATCHALL "[0-9]+" PULSE_VERSION_MINOR ${STR2})
|
|
||||||
string(REGEX MATCHALL "[0-9]+" PULSE_VERSION_PATCH ${STR3})
|
|
||||||
|
|
||||||
if(PULSE_VERSION_PATCH EQUAL 0)
|
|
||||||
set(PULSE_VERSION "${PULSE_VERSION_MAJOR}.${PULSE_VERSION_MINOR}")
|
|
||||||
else()
|
|
||||||
set(PULSE_VERSION "${PULSE_VERSION_MAJOR}.${PULSE_VERSION_MINOR}.${PULSE_VERSION_PATCH}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
mark_as_advanced(PULSE_INCLUDE_DIR PULSE_LIBRARY PULSE_VERSION PULSE_VERSION_MAJOR PULSE_VERSION_MINOR PULSE_VERSION_PATCH)
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user