Qt for android运行时出错 Error: Target id 'android--1' is not valid

 

[提问]windows7下Qt for android运行时出错 Error: Target id 'android--1' is not valid[复制链接]

上一主题下一主题
 

 
 
只看楼主 倒序阅读楼主  发表于: 2015-04-11
 
 


程序是正确的,在Window环境下运行OK
Android模拟器能跑起来。

在Android上运行时出现这种情况

22:19:48: 进程"D:\Qt\Qt5.4.1\Tools\mingw491_32\bin\mingw32-make.exe"正常退出。
22:19:48: Starting: "D:\Qt\Qt5.4.1\5.4\android_armv7\bin\androiddeployqt.exe" --input D:/qt5/qml/qtquickbook/build-touchEvent-Android_for_armeabi_v7a_GCC_4_8_Qt_5_4_1-Release/android-libtouchEvent.so-deployment-settings.json --output D:/qt5/qml/qtquickbook/build-touchEvent-Android_for_armeabi_v7a_GCC_4_8_Qt_5_4_1-Release/android-build --deployment bundled --android-platform android--1 --jdk "D:/Program Files/Java/jdk1.7.0_45" --ant D:/qt5/apache-ant-1.9.4/bin/ant.bat
Error: Target id 'android--1' is not valid. Use 'android.bat list targets' to get the target ids.
Generating Android Package
  Input file: D:/qt5/qml/qtquickbook/build-touchEvent-Android_for_armeabi_v7a_GCC_4_8_Qt_5_4_1-Release/android-libtouchEvent.so-deployment-settings.json
  Output directory: D:/qt5/qml/qtquickbook/build-touchEvent-Android_for_armeabi_v7a_GCC_4_8_Qt_5_4_1-Release/android-build/
  Application binary: D:/qt5/qml/qtquickbook/build-touchEvent-Android_for_armeabi_v7a_GCC_4_8_Qt_5_4_1-Release/libtouchEvent.so
  Android build platform: android--1
  Install to device: No
Buildfile: build.xml does not exist!
Build failed
Warning: Android platform 'android--1' does not exist in SDK.
Building the android package failed!
  -- For more information, run this command with --verbose.
22:19:58: 进程"D:\Qt\Qt5.4.1\5.4\android_armv7\bin\androiddeployqt.exe"退出,退出代码 14 。
Error while building/deploying project touchEvent (kit: Android for armeabi-v7a (GCC 4.8, Qt 5.4.1))
When executing step "Build Android APK"
22:19:58: Elapsed time: 00:13.





 
 
 
 
 

离线fcwr2010
 
只看该作者1楼 发表于: 2015-04-11
 
 
 
你应该是没有设置Android SDK,看图
  • 图片:QQ截图20150412000332.png

 

 
只看该作者2楼 发表于: 2016-02-17
 
 
 
感谢!!!
回复

 

posted on 2018-07-03 11:40  okgogo2000  阅读(1127)  评论(0编辑  收藏  举报