Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-97133

Cannot configure qtbase for Android

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 6.3.0 Alpha
    • 6.3.0 Alpha
    • Build System: CMake
    • None
    • Android
    • 61441074ef8ad63f6dc46253a6b0ea9d26506ef8 (qt/qtbase/dev)

    Description

      When I run the following commands I get the errors below.

      Commands:

      basedir=`pwd`
      mkdir qtbase
      pushd qtbase
      /usr/bin/cmake  -DWARNINGS_ARE_ERRORS=OFF -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_COMPILER=/usr/bin/gcc-11 -DCMAKE_CXX_COMPILER=/usr/bin/g++-11 -G Ninja -DFEATURE_developer_build=ON -DCMAKE_CXX_FLAGS=-Wfatal-errors -DQT_BUILD_TESTS=ON -DQT_BUILD_EXAMPLES=OFF /home/andreasbuhr/development/qtdev/qtbase
      /usr/bin/cmake --build .
      popd
      
      mkdir qtbase-android
      pushd qtbase-android
      /usr/bin/cmake  -DWARNINGS_ARE_ERRORS=OFF -DCMAKE_BUILD_TYPE=Debug -GNinja -DCMAKE_TOOLCHAIN_FILE=/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147/build/cmake/android.toolchain.cmake -DANDROID_SDK_ROOT=/home/andreasbuhr/Android/Sdk -DQT_HOST_PATH=$basedir/qtbase -DFEATURE_developer_build=ON -DCMAKE_CXX_FLAGS=-Wfatal-errors -DQT_BUILD_TESTS=ON -DQT_BUILD_EXAMPLES=OFF /home/andreasbuhr/development/qtdev/qtbase
      /usr/bin/cmake --build .
      popd
      

      Error:

      -- Android build detected
      -- Using Android SDK API android-30 from /home/andreasbuhr/Android/Sdk/platforms
      -- Check for feature set changes
      -- Building architecture extraction project with the following CMake arguments:
          -DANDROID_ABI=armeabi-v7a
          -DANDROID_ARM_MODE=thumb
          -DANDROID_ARM_NEON=TRUE
          -DANDROID_PIE=TRUE
          -DANDROID_PLATFORM=android-23
          -DANDROID_STL=c++_shared
          -DANDROID_TOOLCHAIN=clang
          -DCMAKE_C_FLAGS=-g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security 
          -DCMAKE_C_FLAGS_DEBUG=-O0 -fno-limit-debug-info 
          -DCMAKE_C_FLAGS_RELEASE=-Oz -DNDEBUG -Oz
          -DCMAKE_C_FLAGS_RELWITHDEBINFO=-g -DNDEBUG -Oz
          -DCMAKE_CXX_FLAGS=-g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security  -Wfatal-errors
          -DCMAKE_CXX_FLAGS_DEBUG=-O0 -fno-limit-debug-info 
          -DCMAKE_CXX_FLAGS_RELEASE=-Oz -DNDEBUG -Oz
          -DCMAKE_CXX_FLAGS_RELWITHDEBINFO=-g -DNDEBUG -Oz
          -DCMAKE_OBJCOPY=/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-objcopy
          -DCMAKE_TOOLCHAIN_FILE=/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147/build/cmake/android.toolchain.cmake
          -DCMAKE_C_STANDARD=11
          -DCMAKE_CXX_STANDARD=17
          -DCMAKE_MODULE_PATH:STRING=/home/andreasbuhr/development/qtdev/qtbase/cmake/platforms
      -- Extracting architecture info from /home/andreasbuhr/development/qtdev/androidbuild/qtbase-android/config.tests/arch/architecture_test.
      -- CMAKE_VERSION: "3.21.3"
      -- CMAKE_HOST_SYSTEM: "Linux-5.11.0-37-generic"
      -- CMAKE_HOST_SYSTEM_NAME: "Linux"
      -- CMAKE_HOST_SYSTEM_VERSION: "5.11.0-37-generic"
      -- CMAKE_HOST_SYSTEM_PROCESSOR: "x86_64"
      -- CMAKE_SYSTEM: "Android"
      -- CMAKE_SYSTEM_NAME: "Android"
      -- CMAKE_SYSTEM_VERSION: "1"
      -- CMAKE_SYSTEM_PROCESSOR: "armv7-a"
      -- CMAKE_CROSSCOMPILING: "TRUE"
      -- CMAKE_C_COMPILER: "/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147/toolchains/llvm/prebuilt/linux-x86_64/bin/clang" (9.0)
      -- CMAKE_CXX_COMPILER: "/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++" (9.0)
      -- ANDROID_TOOLCHAIN: "clang"
      -- ANDROID_NDK: "/home/andreasbuhr/Android/Sdk/ndk/21.3.6528147"
      -- ANDROID_ABI: "armeabi-v7a"
      -- ANDROID_PLATFORM: "android-23"
      -- ANDROID_STL: "c++_shared"
      -- ANDROID_PIE: "TRUE"
      -- ANDROID_CPP_FEATURES: ""
      -- ANDROID_ALLOW_UNDEFINED_SYMBOLS: ""
      -- ANDROID_ARM_MODE: "thumb"
      -- ANDROID_ARM_NEON: "TRUE"
      -- ANDROID_DISABLE_FORMAT_STRING_CHECKS: ""
      -- ANDROID_NATIVE_API_LEVEL: "23"
      -- ANDROID_LLVM_TRIPLE: "armv7-none-linux-androideabi23"
      -- Could NOT find ZSTD: Found unsuitable version "", but required is at least "1.3" (found ZSTD_LIBRARY-NOTFOUND)
      -- Could NOT find WrapDBus1 (missing: DBus1_LIBRARY DBus1_INCLUDE_DIR WrapDBus1_FOUND) (Required is at least version "1.2")
      -- Could NOT find Backtrace (missing: Backtrace_LIBRARY Backtrace_INCLUDE_DIR) 
      -- Could NOT find double-conversion (missing: double-conversion_DIR)
      -- Could NOT find WrapDoubleConversion (missing: WrapDoubleConversion_FOUND) 
      -- Could NOT find GLIB2 (missing: GLIB2_LIBRARIES GTHREAD2_LIBRARIES GLIB2_INCLUDE_DIRS) 
      -- Found the following ICU libraries:
      --   i18n (required)
      --   uc (required)
      --   data (required)
      -- Failed to find all ICU components (missing: ICU_INCLUDE_DIR ICU_LIBRARY) 
      -- Could NOT find Libb2 (missing: LIBB2_LIBRARY LIBB2_INCLUDE_DIR) 
      -- Could NOT find LTTngUST (missing: LTTNGUST_LIBRARIES LTTNGUST_INCLUDE_DIRS) 
      -- Could NOT find WrapSystemPCRE2 (missing: PCRE2_LIBRARIES PCRE2_INCLUDE_DIRS __pcre2_found) (Required is at least version "10.20")
      -- Could NOT find Slog2 (missing: Slog2_INCLUDE_DIR Slog2_LIBRARY) 
      -- Could NOT find WrapBrotli (missing: BrotliDec_FOUND BrotliEnc_FOUND BrotliCommon_FOUND) 
      -- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSLHeaders (missing: OPENSSL_INCLUDE_DIR) 
      -- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSLHeaders (missing: OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSL (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find GSSAPI (missing: GSSAPI_LIBRARIES GSSAPI_INCLUDE_DIRS) 
      -- Could NOT find Libdrm (missing: Libdrm_LIBRARY Libdrm_INCLUDE_DIR) 
      -- Could NOT find WrapSystemFreetype (missing: __freetype_found) (Required is at least version "2.2.0")
      -- Could NOT find Fontconfig (missing: Fontconfig_LIBRARY Fontconfig_INCLUDE_DIR) 
      -- Could NOT find gbm (missing: gbm_LIBRARY gbm_INCLUDE_DIR) 
      -- Could NOT find WrapSystemHarfbuzz (missing: HARFBUZZ_LIBRARIES HARFBUZZ_INCLUDE_DIRS) (Required is at least version "2.6.0")
      -- Could NOT find Libinput (missing: Libinput_LIBRARY Libinput_INCLUDE_DIR) 
      -- Could NOT find JPEG (missing: JPEG_LIBRARY JPEG_INCLUDE_DIR) 
      -- Could NOT find md4c (missing: md4c_DIR)
      -- Could NOT find WrapSystemPNG (missing: __png_found) 
      -- Could NOT find OpenGL (missing: OPENGL_opengl_LIBRARY OPENGL_glx_LIBRARY OPENGL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenGL (missing: WrapOpenGL_FOUND) 
      -- Searching for tool 'Qt6::moc' in package Qt6CoreTools.
      -- Qt6::moc was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/moc using package Qt6CoreTools.
      -- Tool 'Qt6::rcc' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/rcc.
      -- Tool 'Qt6::tracegen' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/tracegen.
      -- Tool 'Qt6::cmake_automoc_parser' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/cmake_automoc_parser.
      -- Using Qt bundled PCRE2.
      -- Using source syncqt found at: /home/andreasbuhr/development/qtdev/qtbase/libexec/syncqt.pl
      -- Running syncqt for module: 'QtCore' 
      -- Could NOT find Backtrace (missing: Backtrace_LIBRARY Backtrace_INCLUDE_DIR) 
      -- Could NOT find double-conversion (missing: double-conversion_DIR)
      -- Could NOT find WrapDoubleConversion (missing: WrapDoubleConversion_FOUND) 
      -- Could NOT find GLIB2 (missing: GLIB2_LIBRARIES GTHREAD2_LIBRARIES GLIB2_INCLUDE_DIRS) 
      -- Found the following ICU libraries:
      --   i18n (required)
      --   uc (required)
      --   data (required)
      -- Failed to find all ICU components (missing: ICU_INCLUDE_DIR ICU_LIBRARY) 
      -- Could NOT find Libb2 (missing: LIBB2_LIBRARY LIBB2_INCLUDE_DIR) 
      -- Could NOT find LTTngUST (missing: LTTNGUST_LIBRARIES LTTNGUST_INCLUDE_DIRS) 
      -- Could NOT find WrapSystemPCRE2 (missing: PCRE2_LIBRARIES PCRE2_INCLUDE_DIRS __pcre2_found) (Required is at least version "10.20")
      -- Could NOT find Slog2 (missing: Slog2_INCLUDE_DIR Slog2_LIBRARY) 
      -- Running syncqt for module: 'QtConcurrent' 
      -- Running syncqt for module: 'QtSql' 
      -- Running syncqt for module: 'QtNetwork' 
      -- Could NOT find WrapBrotli (missing: BrotliDec_FOUND BrotliEnc_FOUND BrotliCommon_FOUND) 
      -- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSLHeaders (missing: OPENSSL_INCLUDE_DIR) 
      -- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSLHeaders (missing: OPENSSL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenSSL (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR) 
      -- Could NOT find GSSAPI (missing: GSSAPI_LIBRARIES GSSAPI_INCLUDE_DIRS) 
      -- Running syncqt for module: 'QtXml' 
      -- Searching for tool 'Qt6::uic' in package Qt6WidgetsTools.
      -- Qt6::uic was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/uic using package Qt6WidgetsTools.
      -- Tool 'Qt6::qlalr' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/qlalr.
      -- Tool 'Qt6::qvkgen' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/libexec/qvkgen.
      -- Tool 'Qt6::qtpaths' was found at /home/andreasbuhr/development/qtdev/androidbuild/qtbase/bin/qtpaths.
      -- Could NOT find X11_XCB (missing: X11_XCB_LIBRARY X11_XCB_INCLUDE_DIR) 
      -- Using Qt bundled Harfbuzz.
      -- Using Qt bundled PNG.
      -- Using Qt bundled Freetype.
      -- Running syncqt for module: 'QtGui' 
      -- Could NOT find Libdrm (missing: Libdrm_LIBRARY Libdrm_INCLUDE_DIR) 
      -- Could NOT find WrapSystemFreetype (missing: __freetype_found) (Required is at least version "2.2.0")
      -- Could NOT find Fontconfig (missing: Fontconfig_LIBRARY Fontconfig_INCLUDE_DIR) 
      -- Could NOT find gbm (missing: gbm_LIBRARY gbm_INCLUDE_DIR) 
      -- Could NOT find WrapSystemHarfbuzz (missing: HARFBUZZ_LIBRARIES HARFBUZZ_INCLUDE_DIRS) (Required is at least version "2.6.0")
      -- Could NOT find Libinput (missing: Libinput_LIBRARY Libinput_INCLUDE_DIR) 
      -- Could NOT find JPEG (missing: JPEG_LIBRARY JPEG_INCLUDE_DIR) 
      -- Could NOT find md4c (missing: md4c_DIR)
      -- Could NOT find WrapSystemPNG (missing: __png_found) 
      -- Could NOT find OpenGL (missing: OPENGL_opengl_LIBRARY OPENGL_glx_LIBRARY OPENGL_INCLUDE_DIR) 
      -- Could NOT find WrapOpenGL (missing: WrapOpenGL_FOUND) 
      -- Running syncqt for module: 'QtOpenGL' 
      -- Running syncqt for module: 'QtWidgets' 
      -- Running syncqt for module: 'QtOpenGLWidgets' 
      -- Running syncqt for module: 'QtDeviceDiscoverySupport' 
      -- Running syncqt for module: 'QtFbSupport' 
      -- Could NOT find Libinput (missing: Libinput_LIBRARY Libinput_INCLUDE_DIR) 
      -- Could NOT find XKB (missing: XKB_LIBRARY XKB_INCLUDE_DIR) 
      -- Running syncqt for module: 'QtInputSupport' 
      -- Running syncqt for module: 'QtTest' 
      -- Running syncqt for module: 'QtPrintSupport' 
      -- Could NOT find Cups (missing: CUPS_LIBRARIES CUPS_INCLUDE_DIR) 
      -- Could NOT find DB2 (missing: DB2_INCLUDE_DIR DB2_LIBRARY) 
      -- Could NOT find MySQL (missing: MySQL_LIBRARY MySQL_INCLUDE_DIR) 
      -- Could NOT find PostgreSQL (missing: PostgreSQL_LIBRARY PostgreSQL_INCLUDE_DIR) 
      -- Could NOT find Oracle (missing: Oracle_LIBRARY Oracle_INCLUDE_DIR) 
      -- Could NOT find ODBC (missing: ODBC_LIBRARY ODBC_INCLUDE_DIR) 
      -- Could NOT find SQLite3 (missing: SQLite3_INCLUDE_DIR SQLite3_LIBRARY) 
      -- Could NOT find Interbase (missing: Interbase_LIBRARY Interbase_INCLUDE_DIR) 
      -- Could NOT find JPEG (missing: JPEG_LIBRARY JPEG_INCLUDE_DIR) 
      CMake Error at src/corelib/Qt6CoreMacros.cmake:572 (message):
        The list of Android ABIs is empty, when building tst_qsignalspy.
      
        You have the following options to select ABIs for a target:
      
         - Set the QT_ANDROID_ABIS variable before calling qt6_add_executable
         - Add the ANDROID_ABIS parameter to the qt6_add_executable call
         - Set QT_ANDROID_BUILD_ALL_ABIS flag to try building with
           the list of autodetected Qt for Android:
         
      Call Stack (most recent call first):
        cmake/QtExecutableHelpers.cmake:22 (_qt_internal_create_executable)
        cmake/QtTestHelpers.cmake:214 (qt_internal_add_executable)
        tests/auto/testlib/qsignalspy/CMakeLists.txt:7 (qt_internal_add_test)
      
      
      -- Configuring incomplete, errors occurred!
      See also "/home/andreasbuhr/development/qtdev/androidbuild/qtbase-android/CMakeFiles/CMakeOutput.log".
      See also "/home/andreasbuhr/development/qtdev/androidbuild/qtbase-android/CMakeFiles/CMakeError.log".
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            semlanik Alexey Edelev
            andreasbuhr Andreas Buhr
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes