From 425e5563c4bda43a2986a303197bd574cb12cd6c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Artur=20=C5=9Awigo=C5=84?= Date: Mon, 2 Nov 2020 14:52:51 +0100 Subject: [PATCH] Enable AT-SPI only if Eldbus dependency is met Change-Id: I2f961b0f0921dc656e7bb494108c539eea020695 --- build/tizen/CMakeLists.txt | 7 ++++++- build/tizen/deps-check.cmake | 10 +++++++--- build/tizen/profiles/ubuntu-profile.cmake | 2 -- packaging/dali-adaptor.spec | 2 +- 4 files changed, 14 insertions(+), 7 deletions(-) diff --git a/build/tizen/CMakeLists.txt b/build/tizen/CMakeLists.txt index 2ec67bd..da3510f 100644 --- a/build/tizen/CMakeLists.txt +++ b/build/tizen/CMakeLists.txt @@ -17,7 +17,7 @@ ENDIF() OPTION(ENABLE_PKG_CONFIGURE "Use pkgconfig" ON) OPTION(ENABLE_LINK_TEST "Enable the link test" ON) -OPTION(ENABLE_ATSPI "Enable AT-SPI accessibility" OFF) +OPTION(ENABLE_ATSPI "Enable AT-SPI accessibility" ON) # Include additional macros INCLUDE( common.cmake ) @@ -105,6 +105,10 @@ IF( UNIX ) INCLUDE( deps-check.cmake ) ENDIF() +IF( NOT DALI_ELDBUS_AVAILABLE ) + SET( ENABLE_ATSPI OFF ) +ENDIF() + # Set up compiler flags and warnings IF( UNIX ) ADD_COMPILE_OPTIONS( -Wall ${DALI_CFLAGS} )# -Wextra -Wno-unused-parameter )# -Wfloat-equal ) @@ -407,6 +411,7 @@ MESSAGE( STATUS "Font config file: ${fontConfigurationFile}") MESSAGE( STATUS "Using Tizen APP FW libraries: ${ENABLE_APPFW}") MESSAGE( STATUS "Use pkg configure: ${ENABLE_PKG_CONFIGURE}" ) MESSAGE( STATUS "Enable link test: ${ENABLE_LINK_TEST}" ) +MESSAGE( STATUS "Enable AT-SPI: ${ENABLE_ATSPI}" ) MESSAGE( STATUS "Tizen Platform Config supported ${TIZEN_PLATFORM_CONFIG_SUPPORTED_LOGMSG}") MESSAGE( STATUS "Compile flags: ${CMAKE_CXX_FLAGS}") MESSAGE( STATUS "Compile flags: ${CMAKE_C_FLAGS}") diff --git a/build/tizen/deps-check.cmake b/build/tizen/deps-check.cmake index 481ec65..7ce0606 100644 --- a/build/tizen/deps-check.cmake +++ b/build/tizen/deps-check.cmake @@ -60,6 +60,8 @@ ELSE() SET( FREETYPE_BITMAP_SUPPORT_VERSION 17.1.11 ) ENDIF() +SET( ELDBUS_REQUIRED 1.16.0 ) + # checking all possibly used modules (required and optionals) CHECK_MODULE_AND_SET( EXIF exif exif_available ) CHECK_MODULE_AND_SET( FREETYPE freetype2>=${FREETYPE_REQUIRED} freetype_available ) @@ -79,7 +81,7 @@ CHECK_MODULE_AND_SET( TTRACE ttrace ENABLE_TTRACE ) CHECK_MODULE_AND_SET( ECORE ecore [] ) CHECK_MODULE_AND_SET( ECORE_IPC ecore-ipc [] ) CHECK_MODULE_AND_SET( ECORE_IMF ecore-imf [] ) -CHECK_MODULE_AND_SET( ELDBUS eldbus [] ) +CHECK_MODULE_AND_SET( ELDBUS eldbus>=${ELDBUS_REQUIRED} eldbus_available ) CHECK_MODULE_AND_SET( TPKP_CURL tpkp-curl tpkp_curl_available ) CHECK_MODULE_AND_SET( UTILX utilX utilx_available ) CHECK_MODULE_AND_SET( OPENGLES20 glesv2 [] ) @@ -135,8 +137,10 @@ IF( watch_available AND WEARABLE_PROFILE ) ADD_DEFINITIONS( -DAPPCORE_WATCH_AVAILABLE ) ENDIF() -SET(DALI_ELDBUS_AVAILABLE 1) -ADD_DEFINITIONS( -DDALI_ELDBUS_AVAILABLE ) +IF( eldbus_available ) + SET(DALI_ELDBUS_AVAILABLE 1) + ADD_DEFINITIONS( -DDALI_ELDBUS_AVAILABLE ) +ENDIF() IF( webp_available ) SET(DALI_WEBP_AVAILABLE 1) diff --git a/build/tizen/profiles/ubuntu-profile.cmake b/build/tizen/profiles/ubuntu-profile.cmake index 317766a..94496ec 100644 --- a/build/tizen/profiles/ubuntu-profile.cmake +++ b/build/tizen/profiles/ubuntu-profile.cmake @@ -1,7 +1,5 @@ # PROFILE: UBUNTU -SET( ENABLE_ATSPI ON ) - # Set the sources SET( SOURCES ${adaptor_accessibility_common_src_files} diff --git a/packaging/dali-adaptor.spec b/packaging/dali-adaptor.spec index 1641f96..d2b9d22 100644 --- a/packaging/dali-adaptor.spec +++ b/packaging/dali-adaptor.spec @@ -263,7 +263,7 @@ CXXFLAGS+=" -D_ARCH_ARM_ -lgcc" CFLAGS+=" -DWAYLAND" CXXFLAGS+=" -DWAYLAND" -cmake_flags=" -DENABLE_WAYLAND=ON" +cmake_flags=" -DENABLE_WAYLAND=ON -DENABLE_ATSPI=OFF" # Use this conditional when Tizen version is 5.x or greater %if 0%{?tizen_version_major} >= 5 -- 2.7.4