简体   繁体   中英

How can I change the --android-platform in Qt Creator to not be android--1 in debug mode?

I'm trying to run a new Qt Quick application on my android device through Qt Creator. However, Qt Creator keeps using Android API version 1 whereas I would like it to target an Android API version 10 ( aka Android 2.3.3).

When I run Debug->Start Debugging and then select either an armeabi or armeabi-v7a on my physical device and emulators, Qt mysteriously continues to target android--1 :

"C:\\Qt\\5.4\\android_armv5\\bin\\androiddeployqt.exe" --input C:/dev/qc/build-qc_mobile-Android_for_armeabi_GCC_4_9_Qt_5_4_0-Debug/android-libqc_mobile.so-deployment-settings.json --output C:/dev/qc/build-qc_mobile-Android_for_armeabi_GCC_4_9_Qt_5_4_0-Debug/android-build --deployment bundled --android-platform android--1 --jdk C:/jdk1.8.0_05 --ant C:/eclipse/plugins/org.apache.ant_1.9.2.v201404171502/bin/ant.bat

How can I configure my project to target a different android version when debugging?

My Qt creator instance is:
Qt Creator 3.3.0 (opensource)
Based on Qt 5.4.0 (MSVC 2010, 32 bit)

Built on Dec 8 2014 at 15:24:21

From revision d36c4d87db

FYI, deploying a release-mode APK to my device does work. I'm just hoping to get debug-mode working.

You should go to Projects > Build Android APK > Details for configuring deployment settings. There is an option named Android Build SDK . Just select the appropriate Android API version.

Also to create an APK package, select the Bundle Qt libraries in APK option :

在此输入图像描述

You can also select Create Templates to create the manifest file to set application settings like icon, name, ...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM