[opensles] moved detection to modules
* Rename variables to match package name * Move find_package to where it is actually used
This commit is contained in:
parent
f39eb91654
commit
046767b195
@ -592,10 +592,6 @@ set(MBEDTLS_FEATURE_TYPE "OPTIONAL")
|
||||
set(MBEDTLS_FEATURE_PURPOSE "cryptography")
|
||||
set(MBEDTLS_FEATURE_DESCRIPTION "encryption, certificate validation, hashing functions")
|
||||
|
||||
set(OPENSLES_FEATURE_TYPE "OPTIONAL")
|
||||
set(OPENSLES_FEATURE_PURPOSE "multimedia")
|
||||
set(OPENSLES_FEATURE_DESCRIPTION "OpenSLES audio / video")
|
||||
|
||||
set(OSS_FEATURE_TYPE "RECOMMENDED")
|
||||
set(OSS_FEATURE_PURPOSE "sound")
|
||||
set(OSS_FEATURE_DESCRIPTION "audio input, audio output and multimedia redirection")
|
||||
@ -669,7 +665,6 @@ if(WIN32)
|
||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||
set(FFMPEG_FEATURE_TYPE "OPTIONAL")
|
||||
set(VAAPI_FEATURE_TYPE "DISABLED")
|
||||
set(OPENSLES_FEATURE_TYPE "DISABLED")
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
@ -683,7 +678,6 @@ if(APPLE)
|
||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||
endif()
|
||||
set(OPENSLES_FEATURE_TYPE "DISABLED")
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT ANDROID)
|
||||
@ -709,14 +703,12 @@ if(ANDROID)
|
||||
set(PULSE_FEATURE_TYPE "DISABLED")
|
||||
set(PCSC_FEATURE_TYPE "DISABLED")
|
||||
set(VAAPI_FEATURE_TYPE "DISABLED")
|
||||
set(OPENSLES_FEATURE_TYPE "REQUIRED")
|
||||
endif()
|
||||
|
||||
find_feature(Wayland ${WAYLAND_FEATURE_TYPE} ${WAYLAND_FEATURE_PURPOSE} ${WAYLAND_FEATURE_DESCRIPTION})
|
||||
|
||||
find_feature(OpenSSL ${OPENSSL_FEATURE_TYPE} ${OPENSSL_FEATURE_PURPOSE} ${OPENSSL_FEATURE_DESCRIPTION})
|
||||
find_feature(MbedTLS ${MBEDTLS_FEATURE_TYPE} ${MBEDTLS_FEATURE_PURPOSE} ${MBEDTLS_FEATURE_DESCRIPTION})
|
||||
find_feature(OpenSLES ${OPENSLES_FEATURE_TYPE} ${OPENSLES_FEATURE_PURPOSE} ${OPENSLES_FEATURE_DESCRIPTION})
|
||||
|
||||
find_feature(OSS ${OSS_FEATURE_TYPE} ${OSS_FEATURE_PURPOSE} ${OSS_FEATURE_DESCRIPTION})
|
||||
find_feature(ALSA ${ALSA_FEATURE_TYPE} ${ALSA_FEATURE_PURPOSE} ${ALSA_FEATURE_DESCRIPTION})
|
||||
|
@ -17,6 +17,8 @@
|
||||
|
||||
define_channel_client_subsystem("audin" "opensles" "")
|
||||
|
||||
find_package(OpenSLES REQUIRED)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
opensl_io.c
|
||||
audin_opensl_es.c
|
||||
@ -25,10 +27,10 @@ set(${MODULE_PREFIX}_SRCS
|
||||
set(${MODULE_PREFIX}_LIBS
|
||||
winpr
|
||||
freerdp
|
||||
${OPENSLES_LIBRARIES}
|
||||
${OpenSLES_LIBRARIES}
|
||||
)
|
||||
|
||||
include_directories(..)
|
||||
include_directories(${OPENSLES_INCLUDE_DIRS})
|
||||
include_directories(${OpenSLES_INCLUDE_DIRS})
|
||||
|
||||
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
||||
|
@ -17,6 +17,8 @@
|
||||
|
||||
define_channel_client_subsystem("rdpsnd" "opensles" "")
|
||||
|
||||
find_package(OpenSLES REQUIRED)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
opensl_io.c
|
||||
rdpsnd_opensles.c)
|
||||
@ -24,10 +26,10 @@ set(${MODULE_PREFIX}_SRCS
|
||||
set(${MODULE_PREFIX}_LIBS
|
||||
winpr
|
||||
freerdp
|
||||
${OPENSLES_LIBRARIES}
|
||||
${OpenSLES_LIBRARIES}
|
||||
)
|
||||
|
||||
include_directories(..)
|
||||
include_directories(${OPENSLES_INCLUDE_DIRS})
|
||||
include_directories(${OpenSLES_INCLUDE_DIRS})
|
||||
|
||||
add_channel_client_subsystem_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} "" TRUE "")
|
||||
|
@ -1,30 +1,30 @@
|
||||
# - Find OpenSLES
|
||||
# Find the OpenSLES includes and libraries
|
||||
#
|
||||
# OPENSLES_INCLUDE_DIR - where to find dsound.h
|
||||
# OPENSLES_LIBRARIES - List of libraries when using dsound.
|
||||
# OPENSLES_FOUND - True if dsound found.
|
||||
# OpenSLES_INCLUDE_DIR - where to find dsound.h
|
||||
# OpenSLES_LIBRARIES - List of libraries when using dsound.
|
||||
# OpenSLES_FOUND - True if dsound found.
|
||||
|
||||
get_property(_FIND_LIBRARY_USE_LIB64_PATHS GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
|
||||
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS 1)
|
||||
|
||||
find_path(OPENSLES_INCLUDE_DIR SLES/OpenSLES.h)
|
||||
find_path(OpenSLES_INCLUDE_DIR SLES/OpenSLES.h)
|
||||
|
||||
find_library(OPENSLES_LIBRARY NAMES OpenSLES)
|
||||
find_library(OpenSLES_LIBRARY NAMES OpenSLES)
|
||||
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(OPENSLES DEFAULT_MSG
|
||||
OPENSLES_INCLUDE_DIR OPENSLES_LIBRARY)
|
||||
find_package_handle_standard_args(OpenSLES DEFAULT_MSG
|
||||
OpenSLES_INCLUDE_DIR OpenSLES_LIBRARY)
|
||||
|
||||
if(OPENSLES_FOUND)
|
||||
set(OPENSLES_INCLUDE_DIRS ${OPENSLES_INCLUDE_DIR})
|
||||
set(OPENSLES_LIBRARIES ${OPENSLES_LIBRARY})
|
||||
else(OPENSLES_FOUND)
|
||||
if(OpenSLES_FOUND)
|
||||
set(OpenSLES_INCLUDE_DIRS ${OpenSLES_INCLUDE_DIR})
|
||||
set(OpenSLES_LIBRARIES ${OpenSLES_LIBRARY})
|
||||
else(OpenSLES_FOUND)
|
||||
if (OpenSLES_FIND_REQUIRED)
|
||||
message(FATAL_ERROR "Could NOT find OPENSLES")
|
||||
message(FATAL_ERROR "Could NOT find OpenSLES")
|
||||
endif()
|
||||
endif(OPENSLES_FOUND)
|
||||
endif(OpenSLES_FOUND)
|
||||
|
||||
mark_as_advanced(OPENSLES_INCLUDE_DIR OPENSLES_LIBRARY)
|
||||
mark_as_advanced(OpenSLES_INCLUDE_DIR OpenSLES_LIBRARY)
|
||||
|
||||
set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS ${_FIND_LIBRARY_USE_LIB64_PATHS})
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"app-id": "com.freerdp.FreeRDP",
|
||||
"runtime": "org.freedesktop.Platform",
|
||||
"runtime-version": "22.08",
|
||||
"runtime-version": "23.08",
|
||||
"sdk": "org.freedesktop.Sdk",
|
||||
"build-options" : {
|
||||
"cflags": "-O3",
|
||||
@ -31,12 +31,12 @@
|
||||
"add-build-extensions": {
|
||||
"org.freedesktop.Platform.ffmpeg-full": {
|
||||
"directory": "lib/ffmpeg",
|
||||
"version": "22.08",
|
||||
"version": "23.08",
|
||||
"add-ld-path": "."
|
||||
},
|
||||
"org.freedesktop.Platform.openh264": {
|
||||
"directory": "lib/openh264",
|
||||
"version": "2.3.0",
|
||||
"version": "2.3.1",
|
||||
"add-ld-path": "."
|
||||
}
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user