Error when build & run Qt app on Android for x86 and armeabi-v7a kit
I've been trying to develop Android app with Qt Creator 5.7. But when I tried to deploy on device (both emulator and real device), I got this message in Compile Output and failed:
Generating Android Package Input file: D:/Cac project/C&C++/Qt/build-AppSample-Android_for_armeabi_v7a_GCC_4_9_Qt_5_7_0-Debug/android-libAppSample.so-deployment-settings.json Output directory: D:/Cac project/C&C++/Qt/build-AppSample-Android_for_armeabi_v7a_GCC_4_9_Qt_5_7_0-Debug/android-build/ Application binary: D:/Cac project/C&C++/Qt/build-AppSample-Android_for_armeabi_v7a_GCC_4_9_Qt_5_7_0-Debug/libAppSample.so Android build platform: android-22 Install to device: No 'C++' is not recognized as an internal or external command, operable program or batch file. 'C++\Qt\build-AppSample-Android_for_armeabi_v7a_GCC_4_9_Qt_5_7_0-Debug\android-build\' is not recognized as an internal or external command, operable program or batch file. Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils Warning: QML import could not be resolved in any of the import paths: QtQuick.Extras.Private.CppUtils Building the android package failed! -- For more information, run this command with --verbose. 17:17:05: The process "C:\Qt\5.7\android_armv7\bin\androiddeployqt.exe" exited with code 14. Error while building/deploying project AppSample (kit: Android for armeabi-v7a (GCC 4.9, Qt 5.7.0))
I've already downloaded the lastest version of JDK (JDK 1.8.0_102), NDK (ndk_r12b), Android SDK and Apache Ant (Apache Ant 1.9.7). I've also tried to check and uncheck the checkbox "Use Gradle instead of Ant" but still got the same result.
Can anybody explain me what I did wrong or give any solution for it. Thanks a lot.
this is not a valid directory name on Windows (at least you cannot use it on the command line)!
Rename it in something like CandC++
And avoid to use blanks in paths.
Oh I'm almost forgot, I tried creating a new app in another path and it worked well. Thank you very much !