简体   繁体   中英

Can't build APK using Qt Creator due to gradle error

I am trying to build a project for Android on MacOS with Qt Creator 4.14, Qt 5.15.2, NDK 3.0, SDK 21.3.6528147. Qt shows green checkmarks for Java/Android/OpenSSL

When I compile my app I see these errors during the "Generating Android Package" step (I think that's gradle called by qtdeployandroid):

Initialized native services in: /Users/admin/.gradle/native
The client will now receive all logging from the daemon (pid: 1778). The daemon log file: /Users/admin/.gradle/daemon/5.6.4/daemon-1778.out.log
Starting 9th build in daemon [uptime: 53 mins 14.777 secs, performance: 99%]
Using 2 worker leases.

FAILURE: Build failed with an exception.

* What went wrong:
Could not create service of type ScriptPluginFactory using BuildScopeServices.createScriptPluginFactory().
> Could not create service of type FileHasher using BuildSessionScopeServices.createFileSnapshotter().

* Try:
Run with --stacktrace option to get the stack trace. Run with --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 971ms
Building the android package failed!
20:04:18: The process "/Users/admin/Qt/5.15.2/android/bin/androiddeployqt" exited with code 14.
Error while building/deploying project BFChristmasParty (kit: Android Qt 5.15.2 Clang Multi-Abi)
When executing step "Build Android APK"
20:04:18: Elapsed time: 01:42.

My project resides on a SMB share in case that matters.

Check permissions of /Users/admin/.gradle/native ... and you can navigate to the directory and then run ./gradlew assembleDebug --stacktrace (it may also be gradle or assemble , depending how it is set up).

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