diff options
Diffstat (limited to 'cmake')
| -rw-r--r-- | cmake/modules/FindCdio.cmake | 17 | ||||
| -rw-r--r-- | cmake/modules/FindFFMPEG.cmake | 1 | ||||
| -rw-r--r-- | cmake/modules/FindMySqlClient.cmake | 2 | ||||
| -rw-r--r-- | cmake/modules/FindRapidJSON.cmake | 42 | ||||
| -rw-r--r-- | cmake/modules/FindVAAPI.cmake | 18 | ||||
| -rw-r--r-- | cmake/modules/FindWaylandpp.cmake | 64 | ||||
| -rw-r--r-- | cmake/modules/FindXkbcommon.cmake | 35 | ||||
| -rw-r--r-- | cmake/platform/linux/wayland.cmake | 17 | ||||
| -rw-r--r-- | cmake/scripts/android/Install.cmake | 1 | ||||
| -rw-r--r-- | cmake/scripts/common/AddonHelpers.cmake | 1 | ||||
| -rw-r--r-- | cmake/scripts/common/Macros.cmake | 2 | ||||
| -rw-r--r-- | cmake/scripts/ios/ArchSetup.cmake | 2 | ||||
| -rw-r--r-- | cmake/scripts/linux/ArchSetup.cmake | 19 | ||||
| -rw-r--r-- | cmake/scripts/linux/ExtraTargets.cmake | 14 | ||||
| -rw-r--r-- | cmake/treedata/common/cores.txt | 1 | ||||
| -rw-r--r-- | cmake/treedata/common/retroplayer.txt | 3 | ||||
| -rw-r--r-- | cmake/treedata/linux/subdirs.txt | 2 | ||||
| -rw-r--r-- | cmake/treedata/optional/common/imx.txt | 1 | ||||
| -rw-r--r-- | cmake/treedata/optional/common/wayland.txt | 2 |
19 files changed, 228 insertions, 16 deletions
diff --git a/cmake/modules/FindCdio.cmake b/cmake/modules/FindCdio.cmake index 3f0a867..64f4bb8 100644 --- a/cmake/modules/FindCdio.cmake +++ b/cmake/modules/FindCdio.cmake | |||
| @@ -23,16 +23,25 @@ find_path(CDIO_INCLUDE_DIR NAMES cdio/cdio.h | |||
| 23 | find_library(CDIO_LIBRARY NAMES cdio libcdio | 23 | find_library(CDIO_LIBRARY NAMES cdio libcdio |
| 24 | PATHS ${CDIO_libcdio_LIBDIR} ${CDIO_libiso9660_LIBDIR}) | 24 | PATHS ${CDIO_libcdio_LIBDIR} ${CDIO_libiso9660_LIBDIR}) |
| 25 | 25 | ||
| 26 | if(NOT WIN32) | ||
| 27 | find_path(ISO9660_INCLUDE_DIR NAMES cdio/iso9660.h | ||
| 28 | PATHS ${PC_CDIO_libcdio_INCLUDEDIR} | ||
| 29 | ${PC_CDIO_libiso9660_INCLUDEDIR}) | ||
| 30 | find_library(ISO9660_LIBRARY NAMES iso9660 | ||
| 31 | PATHS ${CDIO_libcdio_LIBDIR} ${CDIO_libiso9660_LIBDIR}) | ||
| 32 | list(APPEND ISO9660_VARS ISO9660_INCLUDE_DIR ISO9660_LIBRARY) | ||
| 33 | endif() | ||
| 34 | |||
| 26 | set(CDIO_VERSION ${PC_CDIO_libcdio_VERSION}) | 35 | set(CDIO_VERSION ${PC_CDIO_libcdio_VERSION}) |
| 27 | 36 | ||
| 28 | include(FindPackageHandleStandardArgs) | 37 | include(FindPackageHandleStandardArgs) |
| 29 | find_package_handle_standard_args(Cdio | 38 | find_package_handle_standard_args(Cdio |
| 30 | REQUIRED_VARS CDIO_LIBRARY CDIO_INCLUDE_DIR | 39 | REQUIRED_VARS CDIO_LIBRARY CDIO_INCLUDE_DIR ${ISO9660_VARS} |
| 31 | VERSION_VAR CDIO_VERSION) | 40 | VERSION_VAR CDIO_VERSION) |
| 32 | 41 | ||
| 33 | if(CDIO_FOUND) | 42 | if(CDIO_FOUND) |
| 34 | set(CDIO_LIBRARIES ${CDIO_LIBRARY}) | 43 | set(CDIO_LIBRARIES ${CDIO_LIBRARY} ${ISO9660_LIBRARY}) |
| 35 | set(CDIO_INCLUDE_DIRS ${CDIO_INCLUDE_DIR}) | 44 | set(CDIO_INCLUDE_DIRS ${CDIO_INCLUDE_DIR} ${ISO9660_INCLUDE_DIR}) |
| 36 | 45 | ||
| 37 | if(NOT TARGET CDIO::CDIO) | 46 | if(NOT TARGET CDIO::CDIO) |
| 38 | add_library(CDIO::CDIO UNKNOWN IMPORTED) | 47 | add_library(CDIO::CDIO UNKNOWN IMPORTED) |
| @@ -42,4 +51,4 @@ if(CDIO_FOUND) | |||
| 42 | endif() | 51 | endif() |
| 43 | endif() | 52 | endif() |
| 44 | 53 | ||
| 45 | mark_as_advanced(CDIO_INCLUDE_DIR CDIO_LIBRARY) | 54 | mark_as_advanced(CDIO_INCLUDE_DIR CDIO_LIBRARY ISO9660_INCLUDE_DIR ISO9660_LIBRARY) |
diff --git a/cmake/modules/FindFFMPEG.cmake b/cmake/modules/FindFFMPEG.cmake index dbeb444..02c8d28 100644 --- a/cmake/modules/FindFFMPEG.cmake +++ b/cmake/modules/FindFFMPEG.cmake | |||
| @@ -250,6 +250,7 @@ if(NOT FFMPEG_FOUND) | |||
| 250 | -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} | 250 | -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} |
| 251 | -DFFMPEG_VER=${FFMPEG_VER} | 251 | -DFFMPEG_VER=${FFMPEG_VER} |
| 252 | -DCORE_SYSTEM_NAME=${CORE_SYSTEM_NAME} | 252 | -DCORE_SYSTEM_NAME=${CORE_SYSTEM_NAME} |
| 253 | -DCORE_PLATFORM_NAME=${CORE_PLATFORM_NAME_LC} | ||
| 253 | -DCPU=${CPU} | 254 | -DCPU=${CPU} |
| 254 | -DENABLE_NEON=${ENABLE_NEON} | 255 | -DENABLE_NEON=${ENABLE_NEON} |
| 255 | -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} | 256 | -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} |
diff --git a/cmake/modules/FindMySqlClient.cmake b/cmake/modules/FindMySqlClient.cmake index ceccea3..7b48577 100644 --- a/cmake/modules/FindMySqlClient.cmake +++ b/cmake/modules/FindMySqlClient.cmake | |||
| @@ -21,7 +21,7 @@ else() | |||
| 21 | set(EXTRA_FIND_ARGS) | 21 | set(EXTRA_FIND_ARGS) |
| 22 | endif() | 22 | endif() |
| 23 | 23 | ||
| 24 | find_path(MYSQLCLIENT_INCLUDE_DIR mysql/mysql_time.h) | 24 | find_path(MYSQLCLIENT_INCLUDE_DIR NAMES mysql/mysql.h mysql/server/mysql.h) |
| 25 | find_library(MYSQLCLIENT_LIBRARY_RELEASE NAMES mysqlclient libmysql | 25 | find_library(MYSQLCLIENT_LIBRARY_RELEASE NAMES mysqlclient libmysql |
| 26 | PATH_SUFFIXES mysql | 26 | PATH_SUFFIXES mysql |
| 27 | ${EXTRA_FIND_ARGS}) | 27 | ${EXTRA_FIND_ARGS}) |
diff --git a/cmake/modules/FindRapidJSON.cmake b/cmake/modules/FindRapidJSON.cmake index d41985b..3c3dc3f 100644 --- a/cmake/modules/FindRapidJSON.cmake +++ b/cmake/modules/FindRapidJSON.cmake | |||
| @@ -8,6 +8,47 @@ | |||
| 8 | # RapidJSON_FOUND - system has RapidJSON parser | 8 | # RapidJSON_FOUND - system has RapidJSON parser |
| 9 | # RapidJSON_INCLUDE_DIRS - the RapidJSON parser include directory | 9 | # RapidJSON_INCLUDE_DIRS - the RapidJSON parser include directory |
| 10 | # | 10 | # |
| 11 | if(ENABLE_INTERNAL_RapidJSON) | ||
| 12 | include(ExternalProject) | ||
| 13 | file(STRINGS ${CMAKE_SOURCE_DIR}/tools/depends/target/rapidjson/Makefile VER REGEX MATCH "^[ ]*VERSION[ ]*=.+$") | ||
| 14 | string(REGEX REPLACE "^[ ]*VERSION[ ]*=[ ]*" "" RJSON_VER "${VER}") | ||
| 15 | |||
| 16 | # allow user to override the download URL with a local tarball | ||
| 17 | # needed for offline build envs | ||
| 18 | if(RapidJSON_URL) | ||
| 19 | get_filename_component(RapidJSON_URL "${RapidJSON_URL}" ABSOLUTE) | ||
| 20 | else() | ||
| 21 | set(RapidJSON_URL http://mirrors.kodi.tv/build-deps/sources/rapidjson-${RJSON_VER}.tar.gz) | ||
| 22 | endif() | ||
| 23 | if(VERBOSE) | ||
| 24 | message(STATUS "RapidJSON_URL: ${RapidJSON_URL}") | ||
| 25 | endif() | ||
| 26 | |||
| 27 | if(APPLE) | ||
| 28 | set(EXTRA_ARGS "-DCMAKE_OSX_ARCHITECTURES=${CMAKE_OSX_ARCHITECTURES}") | ||
| 29 | endif() | ||
| 30 | |||
| 31 | set(RapidJSON_LIBRARY ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/lib/librapidjson.a) | ||
| 32 | set(RapidJSON_INCLUDE_DIR ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/include) | ||
| 33 | externalproject_add(rapidjson | ||
| 34 | URL ${RapidJSON_URL} | ||
| 35 | DOWNLOAD_DIR ${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}/download | ||
| 36 | PREFIX ${CORE_BUILD_DIR}/rapidjson | ||
| 37 | CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR} | ||
| 38 | -DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE} | ||
| 39 | "${EXTRA_ARGS}" | ||
| 40 | PATCH_COMMAND patch -p1 < ${CORE_SOURCE_DIR}/tools/depends/target/rapidjson/0001-remove_custom_cxx_flags.patch | ||
| 41 | BUILD_BYPRODUCTS ${RapidJSON_LIBRARY}) | ||
| 42 | set_target_properties(rapidjson PROPERTIES FOLDER "External Projects") | ||
| 43 | |||
| 44 | include(FindPackageHandleStandardArgs) | ||
| 45 | find_package_handle_standard_args(rapidjson | ||
| 46 | REQUIRED_VARS RapidJSON_LIBRARY RapidJSON_INCLUDE_DIR | ||
| 47 | VERSION_VAR RJSON_VER) | ||
| 48 | |||
| 49 | set(RapidJSON_LIBRARIES ${RapidJSON_LIBRARY}) | ||
| 50 | set(RapidJSON_INCLUDE_DIRS ${RapidJSON_INCLUDE_DIR}) | ||
| 51 | else() | ||
| 11 | 52 | ||
| 12 | if(PKG_CONFIG_FOUND) | 53 | if(PKG_CONFIG_FOUND) |
| 13 | pkg_check_modules(PC_RapidJSON RapidJSON>=1.0.2 QUIET) | 54 | pkg_check_modules(PC_RapidJSON RapidJSON>=1.0.2 QUIET) |
| @@ -38,3 +79,4 @@ endif() | |||
| 38 | 79 | ||
| 39 | mark_as_advanced(RapidJSON_INCLUDE_DIR) | 80 | mark_as_advanced(RapidJSON_INCLUDE_DIR) |
| 40 | 81 | ||
| 82 | endif() | ||
diff --git a/cmake/modules/FindVAAPI.cmake b/cmake/modules/FindVAAPI.cmake index 5b57d23..157cec4 100644 --- a/cmake/modules/FindVAAPI.cmake +++ b/cmake/modules/FindVAAPI.cmake | |||
| @@ -11,7 +11,7 @@ | |||
| 11 | # VAAPI_DEFINITIONS - the VAAPI definitions | 11 | # VAAPI_DEFINITIONS - the VAAPI definitions |
| 12 | 12 | ||
| 13 | if(PKG_CONFIG_FOUND) | 13 | if(PKG_CONFIG_FOUND) |
| 14 | pkg_check_modules(PC_VAAPI libva libva-drm libva-x11 QUIET) | 14 | pkg_check_modules(PC_VAAPI libva libva-drm libva-wayland libva-x11 QUIET) |
| 15 | endif() | 15 | endif() |
| 16 | 16 | ||
| 17 | set(REQUIRED_VARS "VAAPI_libva_LIBRARY" "VAAPI_libva-drm_LIBRARY" "VAAPI_libva_INCLUDE_DIR" "VAAPI_libva-drm_INCLUDE_DIR") | 17 | set(REQUIRED_VARS "VAAPI_libva_LIBRARY" "VAAPI_libva-drm_LIBRARY" "VAAPI_libva_INCLUDE_DIR" "VAAPI_libva-drm_INCLUDE_DIR") |
| @@ -24,7 +24,13 @@ find_path(VAAPI_libva-drm_INCLUDE_DIR va/va_drm.h | |||
| 24 | PATHS ${PC_VAAPI_libva-drm_INCLUDEDIR}) | 24 | PATHS ${PC_VAAPI_libva-drm_INCLUDEDIR}) |
| 25 | find_library(VAAPI_libva-drm_LIBRARY NAMES va-drm | 25 | find_library(VAAPI_libva-drm_LIBRARY NAMES va-drm |
| 26 | PATHS ${PC_VAAPI_libva-drm_LIBDIR}) | 26 | PATHS ${PC_VAAPI_libva-drm_LIBDIR}) |
| 27 | 27 | if(CORE_PLATFORM_NAME_LC STREQUAL "wayland") | |
| 28 | find_path(VAAPI_libva-wayland_INCLUDE_DIR va/va_wayland.h | ||
| 29 | PATHS ${PC_VAAPI_libva-wayland_INCLUDEDIR}) | ||
| 30 | find_library(VAAPI_libva-wayland_LIBRARY NAMES va-wayland | ||
| 31 | PATHS ${PC_VAAPI_libva-wayland_LIBDIR}) | ||
| 32 | list(APPEND REQUIRED_VARS "VAAPI_libva-wayland_INCLUDE_DIR" "VAAPI_libva-wayland_LIBRARY") | ||
| 33 | endif() | ||
| 28 | if(CORE_PLATFORM_NAME_LC STREQUAL "x11") | 34 | if(CORE_PLATFORM_NAME_LC STREQUAL "x11") |
| 29 | find_path(VAAPI_libva-x11_INCLUDE_DIR va/va_x11.h | 35 | find_path(VAAPI_libva-x11_INCLUDE_DIR va/va_x11.h |
| 30 | PATHS ${PC_VAAPI_libva-x11_INCLUDEDIR}) | 36 | PATHS ${PC_VAAPI_libva-x11_INCLUDEDIR}) |
| @@ -51,10 +57,10 @@ find_package_handle_standard_args(VAAPI | |||
| 51 | VERSION_VAR VAAPI_VERSION_STRING) | 57 | VERSION_VAR VAAPI_VERSION_STRING) |
| 52 | 58 | ||
| 53 | if(VAAPI_FOUND) | 59 | if(VAAPI_FOUND) |
| 54 | set(VAAPI_INCLUDE_DIRS ${VAAPI_INCLUDE_DIR} ${VAAPI_DRM_INCLUDE_DIR} ${VAAPI_X11_INCLUDE_DIR}) | 60 | set(VAAPI_INCLUDE_DIRS ${VAAPI_INCLUDE_DIR} ${VAAPI_DRM_INCLUDE_DIR} ${VAAPI_WAYLAND_INCLUDE_DIR} ${VAAPI_X11_INCLUDE_DIR}) |
| 55 | set(VAAPI_LIBRARIES ${VAAPI_libva_LIBRARY} ${VAAPI_libva-drm_LIBRARY} ${VAAPI_libva-x11_LIBRARY}) | 61 | set(VAAPI_LIBRARIES ${VAAPI_libva_LIBRARY} ${VAAPI_libva-drm_LIBRARY} ${VAAPI_libva-wayland_LIBRARY} ${VAAPI_libva-x11_LIBRARY}) |
| 56 | set(VAAPI_DEFINITIONS -DHAVE_LIBVA=1) | 62 | set(VAAPI_DEFINITIONS -DHAVE_LIBVA=1) |
| 57 | endif() | 63 | endif() |
| 58 | 64 | ||
| 59 | mark_as_advanced(VAAPI_libva_INCLUDE_DIR VAAPI_libva-drm_INCLUDE_DIR VAAPI_libva-x11_INCLUDE_DIR | 65 | mark_as_advanced(VAAPI_libva_INCLUDE_DIR VAAPI_libva-drm_INCLUDE_DIR VAAPI_libva-wayland_INCLUDE_DIR VAAPI_libva-x11_INCLUDE_DIR |
| 60 | VAAPI_libva_LIBRARY VAAPI_libva-drm_LIBRARY VAAPI_libva-x11_LIBRARY) | 66 | VAAPI_libva_LIBRARY VAAPI_libva-drm_LIBRARY VAAPI_libva-wayland_LIBRARY VAAPI_libva-x11_LIBRARY) |
diff --git a/cmake/modules/FindWaylandpp.cmake b/cmake/modules/FindWaylandpp.cmake new file mode 100644 index 0000000..8a1cd74 --- /dev/null +++ b/cmake/modules/FindWaylandpp.cmake | |||
| @@ -0,0 +1,64 @@ | |||
| 1 | # FindWaylandpp | ||
| 2 | # ----------- | ||
| 3 | # Finds the waylandpp library | ||
| 4 | # | ||
| 5 | # This will will define the following variables:: | ||
| 6 | # | ||
| 7 | # WAYLANDPP_FOUND - the system has Wayland | ||
| 8 | # WAYLANDPP_INCLUDE_DIRS - the Wayland include directory | ||
| 9 | # WAYLANDPP_LIBRARIES - the Wayland libraries | ||
| 10 | # WAYLANDPP_DEFINITIONS - the Wayland definitions | ||
| 11 | |||
| 12 | |||
| 13 | if(PKG_CONFIG_FOUND) | ||
| 14 | pkg_check_modules(PC_WAYLANDPP wayland-client++>=0.1 wayland-egl++ wayland-cursor++ wayland-scanner++ QUIET) | ||
| 15 | pkg_check_modules(PC_WAYLAND_PROTOCOLS wayland-protocols>=1.7 QUIET) | ||
| 16 | # TODO: Remove check when CMake minimum version is bumped globally | ||
| 17 | if(CMAKE_VERSION VERSION_EQUAL 3.4.0 OR CMAKE_VERSION VERSION_GREATER 3.4.0) | ||
| 18 | if(PC_WAYLANDPP_FOUND) | ||
| 19 | pkg_get_variable(PC_WAYLANDPP_SCANNER wayland-scanner++ wayland_scannerpp) | ||
| 20 | endif() | ||
| 21 | if(PC_WAYLAND_PROTOCOLS_FOUND) | ||
| 22 | pkg_get_variable(PC_WAYLAND_PROTOCOLS_DIR wayland-protocols pkgdatadir) | ||
| 23 | endif() | ||
| 24 | endif() | ||
| 25 | endif() | ||
| 26 | |||
| 27 | find_path(WAYLANDPP_INCLUDE_DIR NAMES wayland-client.hpp | ||
| 28 | PATHS ${PC_WAYLANDPP_INCLUDE_DIRS}) | ||
| 29 | |||
| 30 | find_library(WAYLANDPP_CLIENT_LIBRARY NAMES wayland-client++ | ||
| 31 | PATHS ${PC_WAYLANDPP_LIBRARIES} ${PC_WAYLANDPP_LIBRARY_DIRS}) | ||
| 32 | |||
| 33 | find_library(WAYLANDPP_CURSOR_LIBRARY NAMES wayland-cursor++ | ||
| 34 | PATHS ${PC_WAYLANDPP_LIBRARIES} ${PC_WAYLANDPP_LIBRARY_DIRS}) | ||
| 35 | |||
| 36 | find_library(WAYLANDPP_EGL_LIBRARY NAMES wayland-egl++ | ||
| 37 | PATHS ${PC_WAYLANDPP_LIBRARIES} ${PC_WAYLANDPP_LIBRARY_DIRS}) | ||
| 38 | |||
| 39 | find_program(WAYLANDPP_SCANNER NAMES wayland-scanner++ | ||
| 40 | PATHS ${PC_WAYLANDPP_SCANNER}) | ||
| 41 | |||
| 42 | find_path(WAYLAND_PROTOCOLS_DIR NAMES unstable/xdg-shell/xdg-shell-unstable-v6.xml | ||
| 43 | PATHS ${PC_WAYLAND_PROTOCOLS_DIR} | ||
| 44 | DOC "Directory containing additional Wayland protocols") | ||
| 45 | |||
| 46 | include (FindPackageHandleStandardArgs) | ||
| 47 | find_package_handle_standard_args (Waylandpp | ||
| 48 | REQUIRED_VARS | ||
| 49 | WAYLANDPP_INCLUDE_DIR | ||
| 50 | WAYLANDPP_CLIENT_LIBRARY | ||
| 51 | WAYLANDPP_CURSOR_LIBRARY | ||
| 52 | WAYLANDPP_EGL_LIBRARY | ||
| 53 | WAYLANDPP_SCANNER | ||
| 54 | WAYLAND_PROTOCOLS_DIR | ||
| 55 | VERSION_VAR | ||
| 56 | PC_WAYLANDPP_wayland-client++_VERSION) | ||
| 57 | |||
| 58 | if (WAYLANDPP_FOUND) | ||
| 59 | set(WAYLANDPP_LIBRARIES ${WAYLANDPP_CLIENT_LIBRARY} ${WAYLANDPP_CURSOR_LIBRARY} ${WAYLANDPP_EGL_LIBRARY}) | ||
| 60 | set(WAYLANDPP_INCLUDE_DIRS ${PC_WAYLANDPP_INCLUDE_DIRS}) | ||
| 61 | set(WAYLANDPP_DEFINITIONS -DHAVE_WAYLAND=1) | ||
| 62 | endif() | ||
| 63 | |||
| 64 | mark_as_advanced (WAYLANDPP_CLIENT_LIBRARY WAYLANDPP_CURSOR_LIBRARY WAYLANDPP_EGL_LIBRARY WAYLANDPP_INCLUDE_DIR) | ||
diff --git a/cmake/modules/FindXkbcommon.cmake b/cmake/modules/FindXkbcommon.cmake new file mode 100644 index 0000000..88c6121 --- /dev/null +++ b/cmake/modules/FindXkbcommon.cmake | |||
| @@ -0,0 +1,35 @@ | |||
| 1 | # FindXkbcommon | ||
| 2 | # ----------- | ||
| 3 | # Finds the libxkbcommon library | ||
| 4 | # | ||
| 5 | # This will will define the following variables:: | ||
| 6 | # | ||
| 7 | # XKBCOMMON_FOUND - the system has libxkbcommon | ||
| 8 | # XKBCOMMON_INCLUDE_DIRS - the libxkbcommon include directory | ||
| 9 | # XKBCOMMON_LIBRARIES - the libxkbcommon libraries | ||
| 10 | # XKBCOMMON_DEFINITIONS - the libxkbcommon definitions | ||
| 11 | |||
| 12 | |||
| 13 | if(PKG_CONFIG_FOUND) | ||
| 14 | pkg_check_modules (PC_XKBCOMMON xkbcommon QUIET) | ||
| 15 | endif() | ||
| 16 | |||
| 17 | find_path(XKBCOMMON_INCLUDE_DIR NAMES xkbcommon/xkbcommon.h | ||
| 18 | PATHS ${PC_XKBCOMMON_INCLUDE_DIRS}) | ||
| 19 | |||
| 20 | find_library(XKBCOMMON_LIBRARY NAMES xkbcommon | ||
| 21 | PATHS ${PC_XKBCOMMON_LIBRARIES} ${PC_XKBCOMMON_LIBRARY_DIRS}) | ||
| 22 | |||
| 23 | include (FindPackageHandleStandardArgs) | ||
| 24 | find_package_handle_standard_args (XKBCOMMON | ||
| 25 | REQUIRED_VARS | ||
| 26 | XKBCOMMON_INCLUDE_DIR | ||
| 27 | XKBCOMMON_LIBRARY) | ||
| 28 | |||
| 29 | if (XKBCOMMON_FOUND) | ||
| 30 | set(XKBCOMMON_LIBRARIES ${XKBCOMMON_LIBRARY}) | ||
| 31 | set(XKBCOMMON_INCLUDE_DIRS ${PC_XKBCOMMON_INCLUDE_DIRS}) | ||
| 32 | set(XKBCOMMON_DEFINITIONS -DHAVE_XKBCOMMON=1) | ||
| 33 | endif() | ||
| 34 | |||
| 35 | mark_as_advanced (XKBCOMMON_LIBRARY XKBCOMMON_INCLUDE_DIR) \ No newline at end of file | ||
diff --git a/cmake/platform/linux/wayland.cmake b/cmake/platform/linux/wayland.cmake new file mode 100644 index 0000000..3934834 --- /dev/null +++ b/cmake/platform/linux/wayland.cmake | |||
| @@ -0,0 +1,17 @@ | |||
| 1 | set(PLATFORM_REQUIRED_DEPS EGL Waylandpp LibDRM Xkbcommon) | ||
| 2 | set(PLATFORM_OPTIONAL_DEPS VAAPI) | ||
| 3 | |||
| 4 | set(WAYLAND_RENDER_SYSTEM "" CACHE STRING "Render system to use with Wayland: \"gl\" or \"gles\"") | ||
| 5 | |||
| 6 | if(WAYLAND_RENDER_SYSTEM STREQUAL "gl") | ||
| 7 | list(APPEND PLATFORM_REQUIRED_DEPS OpenGl) | ||
| 8 | elseif(WAYLAND_RENDER_SYSTEM STREQUAL "gles") | ||
| 9 | list(APPEND PLATFORM_REQUIRED_DEPS OpenGLES) | ||
| 10 | else() | ||
| 11 | message(SEND_ERROR "You need to decide whether you want to use GL- or GLES-based rendering in combination with the Wayland windowing system. Please set WAYLAND_RENDER_SYSTEM to either \"gl\" or \"gles\". For normal desktop systems, you will usually want to use \"gl\".") | ||
| 12 | endif() | ||
| 13 | |||
| 14 | set(PLATFORM_GLOBAL_TARGET_DEPS generate-wayland-extra-protocols) | ||
| 15 | set(WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR "${CMAKE_CURRENT_BINARY_DIR}") | ||
| 16 | # for wayland-extra-protocols.hpp | ||
| 17 | include_directories("${WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR}") \ No newline at end of file | ||
diff --git a/cmake/scripts/android/Install.cmake b/cmake/scripts/android/Install.cmake index b815c30..46181f7 100644 --- a/cmake/scripts/android/Install.cmake +++ b/cmake/scripts/android/Install.cmake | |||
| @@ -41,6 +41,7 @@ set(package_files strings.xml | |||
| 41 | src/XBMCInputDeviceListener.java | 41 | src/XBMCInputDeviceListener.java |
| 42 | src/XBMCJsonRPC.java | 42 | src/XBMCJsonRPC.java |
| 43 | src/XBMCMediaContentProvider.java | 43 | src/XBMCMediaContentProvider.java |
| 44 | src/XBMCMediaSession.java | ||
| 44 | src/XBMCRecommendationBuilder.java | 45 | src/XBMCRecommendationBuilder.java |
| 45 | src/XBMCSearchableActivity.java | 46 | src/XBMCSearchableActivity.java |
| 46 | src/XBMCSettingsContentObserver.java | 47 | src/XBMCSettingsContentObserver.java |
diff --git a/cmake/scripts/common/AddonHelpers.cmake b/cmake/scripts/common/AddonHelpers.cmake index abb79ff..2fafe79 100644 --- a/cmake/scripts/common/AddonHelpers.cmake +++ b/cmake/scripts/common/AddonHelpers.cmake | |||
| @@ -255,7 +255,6 @@ macro (build_addon target prefix libs) | |||
| 255 | 255 | ||
| 256 | if(CMAKE_BUILD_TYPE MATCHES Debug) | 256 | if(CMAKE_BUILD_TYPE MATCHES Debug) |
| 257 | # for debug builds also install the PDB file | 257 | # for debug builds also install the PDB file |
| 258 | get_filename_component(LIBRARY_DIR ${LIBRARY_LOCATION} DIRECTORY) | ||
| 259 | install(FILES $<TARGET_PDB_FILE:${target}> DESTINATION ${target} | 258 | install(FILES $<TARGET_PDB_FILE:${target}> DESTINATION ${target} |
| 260 | COMPONENT ${target}-${${prefix}_VERSION}) | 259 | COMPONENT ${target}-${${prefix}_VERSION}) |
| 261 | endif() | 260 | endif() |
diff --git a/cmake/scripts/common/Macros.cmake b/cmake/scripts/common/Macros.cmake index 09c9c36..9f00bb7 100644 --- a/cmake/scripts/common/Macros.cmake +++ b/cmake/scripts/common/Macros.cmake | |||
| @@ -72,7 +72,7 @@ function(core_add_library name) | |||
| 72 | add_library(${name} STATIC ${SOURCES} ${HEADERS} ${OTHERS}) | 72 | add_library(${name} STATIC ${SOURCES} ${HEADERS} ${OTHERS}) |
| 73 | set_target_properties(${name} PROPERTIES PREFIX "") | 73 | set_target_properties(${name} PROPERTIES PREFIX "") |
| 74 | set(core_DEPENDS ${name} ${core_DEPENDS} CACHE STRING "" FORCE) | 74 | set(core_DEPENDS ${name} ${core_DEPENDS} CACHE STRING "" FORCE) |
| 75 | add_dependencies(${name} libcpluff ffmpeg dvdnav crossguid) | 75 | add_dependencies(${name} libcpluff ffmpeg dvdnav crossguid ${PLATFORM_GLOBAL_TARGET_DEPS}) |
| 76 | set(CORE_LIBRARY ${name} PARENT_SCOPE) | 76 | set(CORE_LIBRARY ${name} PARENT_SCOPE) |
| 77 | 77 | ||
| 78 | # Add precompiled headers to Kodi main libraries | 78 | # Add precompiled headers to Kodi main libraries |
diff --git a/cmake/scripts/ios/ArchSetup.cmake b/cmake/scripts/ios/ArchSetup.cmake index 8393faa..be12c49 100644 --- a/cmake/scripts/ios/ArchSetup.cmake +++ b/cmake/scripts/ios/ArchSetup.cmake | |||
| @@ -2,7 +2,7 @@ if(NOT CMAKE_TOOLCHAIN_FILE) | |||
| 2 | message(FATAL_ERROR "CMAKE_TOOLCHAIN_FILE required for ios. See ${CMAKE_SOURCE_DIR}/cmake/README.md") | 2 | message(FATAL_ERROR "CMAKE_TOOLCHAIN_FILE required for ios. See ${CMAKE_SOURCE_DIR}/cmake/README.md") |
| 3 | endif() | 3 | endif() |
| 4 | 4 | ||
| 5 | set(CORE_MAIN_SOURCE ${CMAKE_SOURCE_DIR}/xbmc/platform/darwin/ios/XBMCApplication.m) | 5 | set(CORE_MAIN_SOURCE ${CMAKE_SOURCE_DIR}/xbmc/platform/darwin/ios/XBMCApplication.mm) |
| 6 | 6 | ||
| 7 | set(ARCH_DEFINES -D_LINUX -DTARGET_POSIX -DTARGET_DARWIN -DTARGET_DARWIN_IOS) | 7 | set(ARCH_DEFINES -D_LINUX -DTARGET_POSIX -DTARGET_DARWIN -DTARGET_DARWIN_IOS) |
| 8 | set(SYSTEM_DEFINES -D_REENTRANT -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE | 8 | set(SYSTEM_DEFINES -D_REENTRANT -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE |
diff --git a/cmake/scripts/linux/ArchSetup.cmake b/cmake/scripts/linux/ArchSetup.cmake index bf32fe0..74018d0 100644 --- a/cmake/scripts/linux/ArchSetup.cmake +++ b/cmake/scripts/linux/ArchSetup.cmake | |||
| @@ -42,9 +42,28 @@ if(CMAKE_BUILD_TYPE STREQUAL Release AND CMAKE_COMPILER_IS_GNUCXX) | |||
| 42 | set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s") | 42 | set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s") |
| 43 | endif() | 43 | endif() |
| 44 | 44 | ||
| 45 | if(KODI_DEPENDSBUILD) | ||
| 46 | # Binaries should be directly runnable from host, so include rpath to depends | ||
| 47 | set(CMAKE_INSTALL_RPATH "${DEPENDS_PATH}/lib") | ||
| 48 | set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE) | ||
| 49 | endif() | ||
| 50 | |||
| 45 | find_package(CXX11 REQUIRED) | 51 | find_package(CXX11 REQUIRED) |
| 46 | include(LDGOLD) | 52 | include(LDGOLD) |
| 47 | 53 | ||
| 54 | include(CheckIncludeFiles) | ||
| 55 | check_include_files("linux/memfd.h" HAVE_LINUX_MEMFD) | ||
| 56 | if(HAVE_LINUX_MEMFD) | ||
| 57 | list(APPEND ARCH_DEFINES "-DHAVE_LINUX_MEMFD=1") | ||
| 58 | endif() | ||
| 59 | include(CheckSymbolExists) | ||
| 60 | set(CMAKE_REQUIRED_DEFINITIONS "-D_GNU_SOURCE") | ||
| 61 | check_symbol_exists("mkostemp" "stdlib.h" HAVE_MKOSTEMP) | ||
| 62 | set(CMAKE_REQUIRED_DEFINITIONS "") | ||
| 63 | if(HAVE_MKOSTEMP) | ||
| 64 | list(APPEND ARCH_DEFINES "-DHAVE_MKOSTEMP=1" "-D_GNU_SOURCE") | ||
| 65 | endif() | ||
| 66 | |||
| 48 | # Code Coverage | 67 | # Code Coverage |
| 49 | if(CMAKE_BUILD_TYPE STREQUAL Coverage) | 68 | if(CMAKE_BUILD_TYPE STREQUAL Coverage) |
| 50 | set(COVERAGE_TEST_BINARY ${APP_NAME_LC}-test) | 69 | set(COVERAGE_TEST_BINARY ${APP_NAME_LC}-test) |
diff --git a/cmake/scripts/linux/ExtraTargets.cmake b/cmake/scripts/linux/ExtraTargets.cmake index e89aab6..4753f73 100644 --- a/cmake/scripts/linux/ExtraTargets.cmake +++ b/cmake/scripts/linux/ExtraTargets.cmake | |||
| @@ -13,3 +13,17 @@ if(ENABLE_EVENTCLIENTS AND BLUETOOTH_FOUND) | |||
| 13 | add_subdirectory(${CMAKE_SOURCE_DIR}/tools/EventClients/Clients/WiiRemote build/WiiRemote) | 13 | add_subdirectory(${CMAKE_SOURCE_DIR}/tools/EventClients/Clients/WiiRemote build/WiiRemote) |
| 14 | endif() | 14 | endif() |
| 15 | endif() | 15 | endif() |
| 16 | |||
| 17 | if(CORE_PLATFORM_NAME_LC STREQUAL "wayland") | ||
| 18 | # This cannot go into wayland.cmake since it requires the Wayland dependencies | ||
| 19 | # to already be resolved | ||
| 20 | set(PROTOCOL_XMLS "${WAYLAND_PROTOCOLS_DIR}/unstable/xdg-shell/xdg-shell-unstable-v6.xml" | ||
| 21 | "${WAYLAND_PROTOCOLS_DIR}/unstable/idle-inhibit/idle-inhibit-unstable-v1.xml") | ||
| 22 | add_custom_command(OUTPUT "${WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR}/wayland-extra-protocols.hpp" "${WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR}/wayland-extra-protocols.cpp" | ||
| 23 | COMMAND "${WAYLANDPP_SCANNER}" ${PROTOCOL_XMLS} "${WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR}/wayland-extra-protocols.hpp" "${WAYLAND_EXTRA_PROTOCOL_GENERATED_DIR}/wayland-extra-protocols.cpp" | ||
| 24 | DEPENDS "${WAYLANDPP_SCANNER}" ${PROTOCOL_XMLS} | ||
| 25 | COMMENT "Generating wayland-protocols C++ wrappers") | ||
| 26 | |||
| 27 | # Dummy target for dependencies | ||
| 28 | add_custom_target(generate-wayland-extra-protocols DEPENDS wayland-extra-protocols.hpp) | ||
| 29 | endif() \ No newline at end of file | ||
diff --git a/cmake/treedata/common/cores.txt b/cmake/treedata/common/cores.txt index 8d79dd1..d23939d 100644 --- a/cmake/treedata/common/cores.txt +++ b/cmake/treedata/common/cores.txt | |||
| @@ -6,4 +6,3 @@ xbmc/cores/DllLoader/exports/util cores/dll-loader/exports/util | |||
| 6 | xbmc/cores/ExternalPlayer cores/externalplayer | 6 | xbmc/cores/ExternalPlayer cores/externalplayer |
| 7 | xbmc/cores/paplayer cores/paplayer | 7 | xbmc/cores/paplayer cores/paplayer |
| 8 | xbmc/cores/playercorefactory cores/playercorefactory | 8 | xbmc/cores/playercorefactory cores/playercorefactory |
| 9 | xbmc/cores/RetroPlayer cores/RetroPlayer | ||
diff --git a/cmake/treedata/common/retroplayer.txt b/cmake/treedata/common/retroplayer.txt new file mode 100644 index 0000000..ab18c3c --- /dev/null +++ b/cmake/treedata/common/retroplayer.txt | |||
| @@ -0,0 +1,3 @@ | |||
| 1 | xbmc/cores/RetroPlayer cores/RetroPlayer | ||
| 2 | xbmc/cores/RetroPlayer/guicontrols cores/RetroPlayer/guicontrols | ||
| 3 | xbmc/cores/RetroPlayer/rendering cores/RetroPlayer/rendering | ||
diff --git a/cmake/treedata/linux/subdirs.txt b/cmake/treedata/linux/subdirs.txt index 1ed11f5..e301579 100644 --- a/cmake/treedata/linux/subdirs.txt +++ b/cmake/treedata/linux/subdirs.txt | |||
| @@ -8,6 +8,6 @@ xbmc/powermanagement/linux powermanagement/linux | |||
| 8 | xbmc/storage/linux storage/linux | 8 | xbmc/storage/linux storage/linux |
| 9 | xbmc/filesystem/posix filesystem/posix | 9 | xbmc/filesystem/posix filesystem/posix |
| 10 | xbmc/utils/posix utils_posix | 10 | xbmc/utils/posix utils_posix |
| 11 | xbmc/windowing/egl windowing/egl | ||
| 12 | xbmc/platform/posix posix | 11 | xbmc/platform/posix posix |
| 13 | xbmc/cores/VideoPlayer/Process/rbpi cores/VideoPlayer/Process/rbpi | 12 | xbmc/cores/VideoPlayer/Process/rbpi cores/VideoPlayer/Process/rbpi |
| 13 | xbmc/windowing/linux windowing/linux | ||
diff --git a/cmake/treedata/optional/common/imx.txt b/cmake/treedata/optional/common/imx.txt new file mode 100644 index 0000000..8c7e60b --- /dev/null +++ b/cmake/treedata/optional/common/imx.txt | |||
| @@ -0,0 +1 @@ | |||
| xbmc/windowing/egl windowing/egl # IMX | |||
diff --git a/cmake/treedata/optional/common/wayland.txt b/cmake/treedata/optional/common/wayland.txt new file mode 100644 index 0000000..3725fc6 --- /dev/null +++ b/cmake/treedata/optional/common/wayland.txt | |||
| @@ -0,0 +1,2 @@ | |||
| 1 | xbmc/windowing/wayland windowing/wayland # WAYLANDPP | ||
| 2 | xbmc/cores/VideoPlayer/Process/wayland cores/VideoPlayer/Process/wayland # WAYLANDPP \ No newline at end of file | ||
