Error while constructing for android with code output 14
Solved
Mobile and Embedded
-
Good afternoon,
I'm starting to use Qt Creator and am getting this error while compiling for android. The following is the list of Compile output.
Initializing deployment to Android device/simulator Deploying to emulator-5554 15:42:39: Running steps for project Novo_Teste... 15:42:39: Configuration unchanged, skipping qmake step. 15:42:39: Starting: "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" -j4 make: Nothing to be done for `first'. 15:42:43: The process "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" exited normally. 15:42:43: Removing directory C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build/assets 15:42:43: Removing directory C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build/libs 15:42:43: Starting: "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" "INSTALL_ROOT=C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build" install C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmake.exe -install qinstall -exe libNovo_Teste.so C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\libs\armeabi-v7a\libNovo_Teste.so 15:42:46: The process "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" exited normally. 15:42:46: Starting: "C:\QtCreator\Qt\5.12.3\android_armv7\bin\androiddeployqt.exe" --input C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-libNovo_Teste.so-deployment-settings.json --output C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-build --android-platform android-19 --jdk C:/QtCreator/java --gradle Generating Android Package Input file: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-libNovo_Teste.so-deployment-settings.json Output directory: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-build/ Application binary: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/libNovo_Teste.so Android build platform: android-19 Install to device: No FAILURE: Build failed with an exception. * What went wrong: Could not determine java version from '11.0.1'. * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org -- Skipping C:/QtCreator/Qt/5.12.3/android_armv7/plugins/iconengines/libqsvgicon.so. It has unmet dependencies: lib/libQt5Svg.so,lib/libQt5Widgets.so. -- Skipping C:/QtCreator/Qt/5.12.3/android_armv7/plugins/imageformats/libqsvg.so. It has unmet dependencies: lib/libQt5Svg.so,lib/libQt5Widgets.so. Building the android package failed! -- For more information, run this command with --verbose. 15:42:58: The process "C:\QtCreator\Qt\5.12.3\android_armv7\bin\androiddeployqt.exe" exited with code 14. Error while building/deploying project Novo_Teste (kit: Android for armeabi-v7a (Clang Qt 5.12.3 for Android ARMv7)) When executing step "Build Android APK" 15:42:58: Elapsed time: 00:19.
I thank you all
-
Hi and welcome to devnet,
What version of the JDK did you install ?
-
The recommended JDK is 6 and above but I don't see JDK info there.
Take a look at the Android Getting Started Guide in Qt's documentation.
-
now I'm getting this error message.
18:21:49: Running steps for project Novo_Teste... 18:21:49: Starting: "C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmake.exe" C:\QtCreator\Projetos\NovoTeste\Novo_Teste\Novo_Teste.pro -spec android-clang "CONFIG+=qtquickcompiler" Info: creating stash file C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\.qmake.stash 18:21:52: The process "C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmake.exe" exited normally. 18:21:52: Starting: "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" -f C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/Makefile qmake_all make: Nothing to be done for `qmake_all'. 18:21:52: The process "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" exited normally. 18:21:52: Starting: "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" -j4 C:\QtCreator\android-ndk/toolchains/llvm/prebuilt/windows/bin/clang++ -c -D__ANDROID_API__=16 -target armv7-none-linux-androideabi -gcc-toolchain C:\QtCreator\android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/windows -fno-limit-debug-info -DANDROID_HAS_WSTRING --sysroot=C:\QtCreator\android-ndk/sysroot -isystem C:\QtCreator\android-ndk/sysroot/usr/include/arm-linux-androideabi -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++/include -isystem C:\QtCreator\android-ndk/sources/android/support/include -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++abi/include -fstack-protector-strong -DANDROID -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -mthumb -Oz -std=gnu++11 -Wall -W -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I..\Novo_Teste -I. -I..\..\..\Qt\5.12.3\android_armv7\include -I..\..\..\Qt\5.12.3\android_armv7\include\QtQuick -I..\..\..\Qt\5.12.3\android_armv7\include\QtGui -I..\..\..\Qt\5.12.3\android_armv7\include\QtQml -I..\..\..\Qt\5.12.3\android_armv7\include\QtNetwork -I..\..\..\Qt\5.12.3\android_armv7\include\QtCore -I. -I..\..\..\Qt\5.12.3\android_armv7\mkspecs\android-clang -o main.obj ..\Novo_Teste\main.cpp C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmlcachegen.exe --resource=C:/QtCreator/Projetos/NovoTeste/Novo_Teste/qml.qrc -o main_qml.cpp ..\Novo_Teste\main.qml C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmlcachegen.exe --resource-file-mapping=C:/QtCreator/Projetos/NovoTeste/Novo_Teste/qml.qrc -o qmlcache_loader.cpp ..\Novo_Teste\qml.qrc C:\QtCreator\android-ndk/toolchains/llvm/prebuilt/windows/bin/clang++ -c -D__ANDROID_API__=16 -target armv7-none-linux-androideabi -gcc-toolchain C:\QtCreator\android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/windows -fno-limit-debug-info -DANDROID_HAS_WSTRING --sysroot=C:\QtCreator\android-ndk/sysroot -isystem C:\QtCreator\android-ndk/sysroot/usr/include/arm-linux-androideabi -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++/include -isystem C:\QtCreator\android-ndk/sources/android/support/include -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++abi/include -fstack-protector-strong -DANDROID -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -mthumb -Oz -std=gnu++11 -Wall -W -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I..\Novo_Teste -I. -I..\..\..\Qt\5.12.3\android_armv7\include -I..\..\..\Qt\5.12.3\android_armv7\include\QtQuick -I..\..\..\Qt\5.12.3\android_armv7\include\QtGui -I..\..\..\Qt\5.12.3\android_armv7\include\QtQml -I..\..\..\Qt\5.12.3\android_armv7\include\QtNetwork -I..\..\..\Qt\5.12.3\android_armv7\include\QtCore -I. -I..\..\..\Qt\5.12.3\android_armv7\mkspecs\android-clang -o qmlcache_loader.obj qmlcache_loader.cpp C:\QtCreator\android-ndk/toolchains/llvm/prebuilt/windows/bin/clang++ -c -D__ANDROID_API__=16 -target armv7-none-linux-androideabi -gcc-toolchain C:\QtCreator\android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/windows -fno-limit-debug-info -DANDROID_HAS_WSTRING --sysroot=C:\QtCreator\android-ndk/sysroot -isystem C:\QtCreator\android-ndk/sysroot/usr/include/arm-linux-androideabi -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++/include -isystem C:\QtCreator\android-ndk/sources/android/support/include -isystem C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++abi/include -fstack-protector-strong -DANDROID -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fno-builtin-memmove -mthumb -Oz -std=gnu++11 -Wall -W -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I..\Novo_Teste -I. -I..\..\..\Qt\5.12.3\android_armv7\include -I..\..\..\Qt\5.12.3\android_armv7\include\QtQuick -I..\..\..\Qt\5.12.3\android_armv7\include\QtGui -I..\..\..\Qt\5.12.3\android_armv7\include\QtQml -I..\..\..\Qt\5.12.3\android_armv7\include\QtNetwork -I..\..\..\Qt\5.12.3\android_armv7\include\QtCore -I. -I..\..\..\Qt\5.12.3\android_armv7\mkspecs\android-clang -o main_qml.obj main_qml.cpp C:\QtCreator\android-ndk/toolchains/llvm/prebuilt/windows/bin/clang++ -D__ANDROID_API__=16 -target armv7-none-linux-androideabi -gcc-toolchain C:\QtCreator\android-ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/windows -fno-limit-debug-info -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libatomic.a -Wl,--exclude-libs,libunwind.a --sysroot=C:\QtCreator\android-ndk/platforms/android-16/arch-arm/ -Wl,-soname,libNovo_Teste.so -Wl,-rpath=C:/QtCreator/Qt/5.12.3/android_armv7/lib -Wl,--no-undefined -Wl,-z,noexecstack -shared -o libNovo_Teste.so main.obj main_qml.obj qmlcache_loader.obj -LC:/QtCreator/Qt/5.12.3/android_armv7/lib -lQt5Quick -LC:\QtCreator\Qt\5.12.3\android_armv7/lib -Lc:\Utils\Android\android-ndk-r18b/sources/cxx-stl/llvm-libc++/libs/armeabi-v7a -lQt5Gui -lQt5Qml -lQt5Network -lQt5Core -lGLESv2 -LC:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++/libs/armeabi-v7a C:\QtCreator\android-ndk/sources/cxx-stl/llvm-libc++/libs/armeabi-v7a/libc++.so.16 -llog -lz -lm -ldl -lc 18:22:00: The process "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" exited normally. 18:22:00: Starting: "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" "INSTALL_ROOT=C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build" install C:\QtCreator\Qt\5.12.3\android_armv7\bin\qmake.exe -install qinstall -exe libNovo_Teste.so C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\libs\armeabi-v7a\libNovo_Teste.so 18:22:03: The process "C:\QtCreator\android-ndk\prebuilt\windows\bin\make.exe" exited normally. 18:22:03: Starting: "C:\QtCreator\Qt\5.12.3\android_armv7\bin\androiddeployqt.exe" --input C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-libNovo_Teste.so-deployment-settings.json --output C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-build --android-platform android-23 --jdk "C:/Program Files (x86)/Java/jdk1.8.0_191" --gradle Generating Android Package Input file: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-libNovo_Teste.so-deployment-settings.json Output directory: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/android-build/ Application binary: C:/QtCreator/Projetos/NovoTeste/build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release/libNovo_Teste.so Android build platform: android-23 Install to device: No -- Skipping C:/QtCreator/Qt/5.12.3/android_armv7/plugins/iconengines/libqsvgicon.so. It has unmet dependencies: lib/libQt5Svg.so,lib/libQt5Widgets.so. -- Skipping C:/QtCreator/Qt/5.12.3/android_armv7/plugins/imageformats/libqsvg.so. It has unmet dependencies: lib/libQt5Svg.so,lib/libQt5Widgets.so. :checkDebugClasspath :preBuild UP-TO-DATE :preDebugBuild :compileDebugAidl :compileDebugRenderscript :checkDebugManifest :generateDebugBuildConfig :prepareLintJar :mainApkListPersistenceDebug :generateDebugResValues :generateDebugResources :mergeDebugResources :createDebugCompatibleScreenManifests :processDebugManifest :splitsDiscoveryTaskDebug :processDebugResources FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':processDebugResources'. > Android resource linking failed Output: C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml:39: error: 'orientation|uiMode|screenLayout|screenSize|smallestScreenSize|layoutDirection|locale|fontScale|keyboard|keyboardHidden|navigation|mcc|mnc|density' is incompatible with attribute configChanges (attr) flags [locale=4, fontScale=1073741824, keyboard=16, keyboardHidden=32, layoutDirection=8192, mcc=1, mnc=2, navigation=64, orientation=128, screenLayout=256, screenSize=1024, smallestScreenSize=2048, touchscreen=8, uiMode=512]. error: failed processing manifest. Command: C:\Users\Ricardo\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.0-4818971-windows.jar\8517625f8f2ee4f5a6962c7719b520bd\aapt2-3.2.0-4818971-windows\aapt2.exe link -I\ C:\QtCreator\android-sdk\platforms\android-23\android.jar\ --manifest\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\ -o\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\ -R\ @C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\ --auto-add-overlay\ --java\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\ --custom-package\ org.qtproject.example.Novo_Teste\ -0\ apk\ --no-version-vectors Daemon: AAPT2 aapt2-3.2.0-4818971-windows Daemon #0 Output: C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml:39: AAPT: error: 'orientation|uiMode|screenLayout|screenSize|smallestScreenSize|layoutDirection|locale|fontScale|keyboard|keyboardHidden|navigation|mcc|mnc|density' is incompatible with attribute configChanges (attr) flags [locale=4, fontScale=1073741824, keyboard=16, keyboardHidden=32, layoutDirection=8192, mcc=1, mnc=2, navigation=64, orientation=128, screenLayout=256, screenSize=1024, smallestScreenSize=2048, touchscreen=8, uiMode=512]. error: failed processing manifest. Command: C:\Users\Ricardo\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.0-4818971-windows.jar\8517625f8f2ee4f5a6962c7719b520bd\aapt2-3.2.0-4818971-windows\aapt2.exe link -I\ C:\QtCreator\android-sdk\platforms\android-23\android.jar\ --manifest\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\ -o\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\ -R\ @C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\ --auto-add-overlay\ --java\ C:\QtCreator\Projetos\NovoTeste\build-Novo_Teste-Android_for_armeabi_v7a_Clang_Qt_5_12_3_for_Android_ARMv7-Release\android-build\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\ --custom-package\ org.qtproject.example.Novo_Teste\ -0\ apk\ --no-version-vectors Daemon: AAPT2 aapt2-3.2.0-4818971-windows Daemon #0 * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 14s 14 actionable tasks: 14 executed Building the android package failed! -- For more information, run this command with --verbose. 18:22:27: The process "C:\QtCreator\Qt\5.12.3\android_armv7\bin\androiddeployqt.exe" exited with code 14. Error while building/deploying project Novo_Teste (kit: Android for armeabi-v7a (Clang Qt 5.12.3 for Android ARMv7)) When executing step "Build Android APK" 18:22:27: Elapsed time: 00:38.
-
Do you have a manifest file for your project ?
-
The guide I linked you to provides you with links to step by step instructions for:
- Setting up everything for android: https://doc.qt.io/qt-5/android.html
- Creating an application using Qt Creator: https://doc.qt.io/qtcreator/qt-creator-accelbubble-example.html
-
@rcfreitas said in Error while constructing for android with code output 14:
Qt Creator 5.9.8
You mean Qt not QtCreator (not the same).