Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Qbs with qt for android project



  • I use qbs to compile a simple qt for android project, some error like below:

    15:02:18: 为项目Test2执行步骤 ...
    compiling main.cpp
    D:/MyWork/AndroidNDK/android-ndk-r16b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/arm-linux-androideabi-g++.exe "--sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot" -Os -Wall -Wextra -no-canonical-prefixes "-march=armv7-a" -pipe -fno-exceptions -fno-rtti "-fvisibility=default" -ffunction-sections -funwind-tables "-Wa,--noexecstack" "-Werror=format-security" -fomit-frame-pointer -fpic -fstack-protector "-finline-limit=64" "-mfpu=vfpv3-d16" "-mfloat-abi=softfp" -fno-strict-aliasing -mthumb -fPIC -DNDEBUG -DQT_DEPRECATED_WARNINGS -DQT_CORE_LIB -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_QML_LIB -DQT_QUICK_LIB -DQT_QML_DEBUG -DANDROID "-D__ANDROID_API__=14" -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/mkspecs/android-g++ -ID:/MyWork/Qt/QtForAndroid/build-Test2-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_Release/Test2.2b84f621/qt.headers -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtNetwork -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQuick -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sysroot/usr/include/arm-linux-androideabi -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/system/include "-std=c++11" -o D:/MyWork/Qt/QtForAndroid/build-Test2-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_Release/Test2.2b84f621/3a52ce780950d4d9/main.cpp.o -c D:/MyWork/Qt/QtForAndroid/Test2/main.cpp
    In file included from C:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui/qtguiglobal.h:43:0,
                     from C:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui/qguiapplication.h:43,
                     from C:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui/QGuiApplication:1,
                     from D:/MyWork/Qt/QtForAndroid/Test2/main.cpp:1:
    C:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/qglobal.h:45:25: fatal error: type_traits: No such file or directory
     #  include <type_traits>
                             ^
    compilation terminated.
    Process failed with exit code 1.
    The following products could not be built for configuration qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_Release:
    Test2
    Error while building/deploying project Test2 (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.11.0 for Android armv7))
    When executing step "Qbs Build"
    15:02:18: Elapsed time: 00:00.
    

    0_1539156138695_20181010151851.png

    0_1539156150406_20181010152024.png

    can anybody help me?



  • looks like D:\MyWork\AndroidNDK\android-ndk-r16b\sources\cxx-stl\gnu-libstdc++4\4.9\include is not in the path on the system.

    This is a Windows system right?

    path=%path%;D:\MyWork\AndroidNDK\android-ndk-r16b\sources\cxx-stl\gnu-libstdc++4\4.9\include

    You are getting the error on type_traits because it's the first in the list of include files.



  • @ndt_mike

    Yes, my computer system is Win10.

    0_1539227419961_f759f4a6-d7ed-429b-8cbc-fafe7e0db4fc-image.png

    Add path=%path%;D:\MyWork\AndroidNDK\android-ndk-r16b\sources\cxx-stl\gnu-libstdc++4\4.9\include in here ? or in computer system variables.

    I see Qt has the NDK path.

    I use qmake to build qt for android project is ok.

    11:20:54: 为项目Test5执行步骤 ...
    11:20:54: 配置没有改变, 跳过 qmake 步骤。
    11:20:54: 正在启动 "D:\MyWork\AndroidNDK\android-ndk-r16b\prebuilt\windows-x86_64\bin\make.exe" 
    
    D:\MyWork\AndroidNDK\android-ndk-r16b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/arm-linux-androideabi-g++ -c -D__ANDROID_API__=16 --sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot/usr/include/arm-linux-androideabi -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/include -fstack-protector-strong -DANDROID -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -g -g -marm -O0 -std=gnu++11 -Wall -W -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_QML_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I..\Test5 -I. -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtQuick -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtGui -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtQml -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtNetwork -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtCore -I. -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\mkspecs\android-g++ -o main.obj ..\Test5\main.cpp
    C:\Qt\Qt5.11.0\5.11.0\android_armv7\bin\rcc.exe -name qml ..\Test5\qml.qrc -o qrc_qml.cpp
    D:\MyWork\AndroidNDK\android-ndk-r16b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/arm-linux-androideabi-g++ -c -D__ANDROID_API__=16 --sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot/usr/include/arm-linux-androideabi -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include -isystem D:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/include -fstack-protector-strong -DANDROID -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -g -g -marm -O0 -std=gnu++11 -Wall -W -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_QML_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I..\Test5 -I. -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtQuick -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtGui -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtQml -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtNetwork -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\include\QtCore -I. -IC:\Qt\Qt5.11.0\5.11.0\android_armv7\mkspecs\android-g++ -o qrc_qml.obj qrc_qml.cpp
    D:\MyWork\AndroidNDK\android-ndk-r16b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/arm-linux-androideabi-g++ --sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/platforms/android-16/arch-arm/ -Wl,-soname,libTest5.so -Wl,-rpath=C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib -Wl,--no-undefined -Wl,-z,noexecstack -shared -o libTest5.so main.obj qrc_qml.obj   -LD:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a -Ld:/mywork/androidndk/android-ndk-r16b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/bin/../lib/gcc/arm-linux-androideabi/4.9.x -LC:/Qt/Qt5.11.0/5.11.0/android_armv7/lib -lQt5Quick -Lc:\utils\android-ndk-r10e/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a -Lc:/utils/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/windows/bin/../lib/gcc/arm-linux-androideabi/4.9 -LC:\Qt\Qt5.11.0\5.11.0\android_armv7/lib -lQt5Gui -lQt5Qml -lQt5Network -lQt5Core -lGLESv2 -lgnustl_shared -lgcc -llog -lz -lm -ldl -lc
    11:20:58: 进程"D:\MyWork\AndroidNDK\android-ndk-r16b\prebuilt\windows-x86_64\bin\make.exe"正常退出。
    11:20:58: Removing directory D:\MyWork\Qt\QtForAndroid\build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug\android-build/libs
    11:20:58: 正在启动 "D:\MyWork\AndroidNDK\android-ndk-r16b\prebuilt\windows-x86_64\bin\make.exe" "INSTALL_ROOT=D:\MyWork\Qt\QtForAndroid\build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug\android-build" install
    
    C:\Qt\Qt5.11.0\5.11.0\android_armv7\bin\qmake.exe -install qinstall -exe libTest5.so D:\MyWork\Qt\QtForAndroid\build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug\android-build\libs\armeabi-v7a\libTest5.so
    11:21:00: 进程"D:\MyWork\AndroidNDK\android-ndk-r16b\prebuilt\windows-x86_64\bin\make.exe"正常退出。
    11:21:00: Starting: "C:\Qt\Qt5.11.0\5.11.0\android_armv7\bin\androiddeployqt.exe" --input D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/android-libTest5.so-deployment-settings.json --output D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/android-build --android-platform android-28 --jdk "D:/Program Files/Android/Android Studio/jre" --gradle
    Generating Android Package
      Input file: D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/android-libTest5.so-deployment-settings.json
      Output directory: D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/android-build/
      Application binary: D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/libTest5.so
      Android build platform: android-28
      Install to device: No
    The JavaCompile.setDependencyCacheDir() method has been deprecated and is scheduled to be removed in Gradle 4.0.
    The TaskInputs.source(Object) method has been deprecated and is scheduled to be removed in Gradle 4.0. Please use TaskInputs.file(Object).skipWhenEmpty() instead.
    :preBuild UP-TO-DATE
    :preDebugBuild UP-TO-DATE
    :checkDebugManifest
    :prepareDebugDependencies
    :compileDebugAidl UP-TO-DATE
    :compileDebugRenderscript UP-TO-DATE
    :generateDebugBuildConfig UP-TO-DATE
    :generateDebugResValues UP-TO-DATE
    :generateDebugResources UP-TO-DATE
    :mergeDebugResources UP-TO-DATE
    :processDebugManifest UP-TO-DATE
    :processDebugResources UP-TO-DATE
    :generateDebugSources UP-TO-DATE
    :incrementalDebugJavaCompilationSafeguard UP-TO-DATE
    :compileDebugJavaWithJavac UP-TO-DATE
    :compileDebugNdk NO-SOURCE
    :compileDebugSources UP-TO-DATE
    :mergeDebugShaders UP-TO-DATE
    :compileDebugShaders UP-TO-DATE
    :generateDebugAssets UP-TO-DATE
    :mergeDebugAssets UP-TO-DATE
    :transformClassesWithDexForDebug UP-TO-DATE
    :mergeDebugJniLibFolders UP-TO-DATE
    :transformNative_libsWithMergeJniLibsForDebug UP-TO-DATE
    :processDebugJavaRes NO-SOURCE
    :transformResourcesWithMergeJavaResForDebug UP-TO-DATE
    :validateSigningDebug
    :packageDebug UP-TO-DATE
    :assembleDebug UP-TO-DATE
    
    BUILD SUCCESSFUL
    
    Total time: 5.83 secs
    Android package built successfully in 15.240 ms.
      -- File: D:/MyWork/Qt/QtForAndroid/build-Test5-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Debug/android-build//build/outputs/apk/android-build-debug.apk
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.impl
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Fusion.impl
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Imagine.impl
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Material.impl
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Universal.impl
    11:21:15: 进程"C:\Qt\Qt5.11.0\5.11.0\android_armv7\bin\androiddeployqt.exe"正常退出。
    11:21:15: Elapsed time: 00:21.
    

    I wonder if it is a bug of qbs.

    +++++++++++++++++++++++++++++++++

    I add this to project qbs file, and it can be compiled.

    0_1539252612246_4aee1b5a-0756-48f3-8965-efa02509cdff-image.png

    18:08:02: 为项目Test3执行步骤 ...
    D:\MyWork\AndroidNDK\android-ndk-r16b\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip.exe --strip-unneeded -o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/stripped-libs/libgnustl_shared.so D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/libgnustl_shared.so
    C:\Qt\Qt5.11.0\5.11.0\android_armv7\bin\rcc.exe D:/MyWork/Qt/QtForAndroid/Test3/qml.qrc -name qml -o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/qrc_qml.cpp
    D:\MyWork\AndroidNDK\android-ndk-r16b\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-g++.exe "--sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot" -Os -Wall -Wextra -no-canonical-prefixes "-march=armv7-a" -pipe -fexceptions -frtti "-fvisibility=default" -ffunction-sections -funwind-tables "-Wa,--noexecstack" "-Werror=format-security" -fomit-frame-pointer -fpic -fstack-protector "-finline-limit=64" "-mfpu=vfpv3-d16" "-mfloat-abi=softfp" -fno-strict-aliasing -mthumb -fPIC -DNDEBUG -DQT_DEPRECATED_WARNINGS -DQT_CORE_LIB -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_QML_LIB -DQT_QUICK_LIB -DQT_QML_DEBUG -DANDROID "-D__ANDROID_API__=14" -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/mkspecs/android-g++ -ID:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/qt.headers -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtNetwork -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQuick -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sysroot/usr/include/arm-linux-androideabi -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/include -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include/backward "-std=c++11" -o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/3a52ce780950d4d9/qrc_qml.cpp.o -c D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/qrc_qml.cpp
    D:\MyWork\AndroidNDK\android-ndk-r16b\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-g++.exe "--sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/sysroot" -Os -Wall -Wextra -no-canonical-prefixes "-march=armv7-a" -pipe -fexceptions -frtti "-fvisibility=default" -ffunction-sections -funwind-tables "-Wa,--noexecstack" "-Werror=format-security" -fomit-frame-pointer -fpic -fstack-protector "-finline-limit=64" "-mfpu=vfpv3-d16" "-mfloat-abi=softfp" -fno-strict-aliasing -mthumb -fPIC -DNDEBUG -DQT_DEPRECATED_WARNINGS -DQT_CORE_LIB -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_QML_LIB -DQT_QUICK_LIB -DQT_QML_DEBUG -DANDROID "-D__ANDROID_API__=14" -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/mkspecs/android-g++ -ID:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/qt.headers -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtCore/5.11.0/QtCore -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtGui -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtNetwork -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0 -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQml/5.11.0/QtQml -IC:/Qt/Qt5.11.0/5.11.0/android_armv7/include/QtQuick -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sysroot/usr/include/arm-linux-androideabi -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/include -isystem D:/MyWork/AndroidNDK/android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/include/backward "-std=c++11" -o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/3a52ce780950d4d9/main.cpp.o -c D:/MyWork/Qt/QtForAndroid/Test3/main.cpp
    D:\MyWork\AndroidNDK\android-ndk-r16b\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-g++.exe "-Wl,-soname=libTest3.so,--as-needed,-rpath,C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib,-rpath,$ORIGIN,-z,noexecstack,-z,relro,-z,now" -shared "--sysroot=D:\MyWork\AndroidNDK\android-ndk-r16b/platforms/android-14/arch-arm" -LC:/Qt/Qt5.11.0/5.11.0/android_armv7/lib -Lc:/utils/android-ndk-r10e/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a -Lc:/utils/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/windows/lib/gcc/arm-linux-androideabi/4.9 -LD:/MyWork/AndroidNDK/android-ndk-r16b/sysroot/usr/lib -no-canonical-prefixes "-march=armv7-a" -o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/libTest3.so D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/3a52ce780950d4d9/main.cpp.o D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/3a52ce780950d4d9/qrc_qml.cpp.o -lgcc C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Core.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Gui.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Core.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Network.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Core.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Qml.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Network.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Core.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Quick.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Qml.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Gui.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Network.so C:/Qt/Qt5.11.0/5.11.0/android_armv7/lib/libQt5Core.so -lc -lm D:\MyWork\AndroidNDK\android-ndk-r16b/sources/cxx-stl/gnu-libstdc++/4.9/libs/armeabi-v7a/libgnustl_shared.so
    D:\MyWork\AndroidNDK\android-ndk-r16b\toolchains\arm-linux-androideabi-4.9\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip.exe --strip-unneeded D:/MyWork/Qt/QtForAndroid/build-Test3-Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650-Release/qtc_Android_for_armeabi_v7a_GCC_4_9_Qt_5_11_0_for_Android_armv7_7c9650_Release/Test3.5e595222/stripped-libs/libTest3.so
    18:08:03: Elapsed time: 00:02.
    

    But i press run button, new error happened:

    Cannot find the android build step.
    Error while building/deploying project Test3 (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.11.0 for Android armv7))
    When executing step "Deploy to Android device"
    


  • I am guessing a bit but it appears you are now building the project, it just can't deploy the executable to a target either and emulator or physical target on the USB.

    Do you have either of those running?



  • @ndt_mike Yes, I have android device connected to computer with usb. When I press QtCreator run button, it doesn't show the select device dialog .


  • Lifetime Qt Champion

    @RobinsonSir Did you enable USB debugging on your device?



  • @jsulm Yes and device is in developer mode. I use qmake can build qt for android app in this device.





  • @rmam emm...Qbs is worst try


Log in to reply