Reputation: 339
I am trying to deploy one of the QT Examples (i.e. calqlatr or samegame) to my Android Phone (4.0.4). I am using Windows 7 32Bit and QtCreator 3.0.0Beta. I successfully added the device and the kits to deploy it to QtCreator.
The build of the example succeeds as well but during the deployment I get the following error:
Invalid json file: C:/Qt/Qt5.2.0/5.2.0-beta1/mingw48_32/examples/quick/demos/build-samegame-Android_für_armeabi_GCC_4_8_Qt_5_2_0-Debug/android-libsamegame.so-deployment-settings.json
08:18:32: Der Prozess "C:\Qt\Qt5.2.0\5.2.0-beta1\android_armv5\bin\androiddeployqt.exe" wurde mit dem Rückgabewert 2 beendet.
Fehler beim Erstellen/Deployment des Projekts samegame(Kit: Android für armeabi (GCC 4.8, Qt 5.2.0))
Bei der Ausführung von Schritt 'Deploy to Android device'
I checked the named json file and it looks ok for me:
{
"description": "This file is generated by qmake to be read by androiddeployqt and should not be modified by hand.",
"qt": "C:\\Qt\\Qt5.2.0\\5.2.0-beta1\\android_armv5",
"sdk": "C:/adt-bundle-windows-x86/sdk",
"ndk": "C:\\Users\\mcc-lan\\android-ndk-r9b",
"toolchain-prefix": "arm-linux-androideabi",
"tool-prefix": "arm-linux-androideabi",
"toolchain-version": "4.8",
"ndk-host": "windows",
"target-architecture": "armeabi",
"application-binary": "C:/Qt/Qt5.2.0/5.2.0-beta1/mingw48_32/examples/quick/demos/build-samegame-Android_für_armeabi_GCC_4_8_Qt_5_2_0-Debug/libsamegame.so"
}
As there is no further error description I don't have a clue where to go next. I also have a slight uncertainty in the Android NDK, I downloaded and used: android-ndk-r9b-windows-x86.zip is that correct or do I need android-ndk-r9b-windows-x86-legacy-toolchains.zip ?
Thank your for any suggestions.
Upvotes: 2
Views: 2391
Reputation: 339
Ok, I'll answer the question myself. Sorry for that.
After some even more research I realized that the Problem was due to lengthy paths.
The default build path from QTCreator made Windows to fail during some command-line calls. I changed the build-paths to short directory names and everything succeeded.
Best regards.
Upvotes: 2