cant build for android

Dubbsta

Active member
Joined
Jul 13, 2017
Messages
194
just updated to api 29 and 30, installed cmake, ndk and a bunch of other things and build fails

release keeps saying waiting for device

and this on debug
TRANS cerberus compiler V2021-03-21
Parsing...
Semanting...
Translating...
Building...
:app:clean
:app:checkDebugClasspath
:app:preBuild UP-TO-DATE
:app:preDebugBuild
:app:compileDebugAidl NO-SOURCE
:app:compileDebugRenderscript
:app:checkDebugManifest
:app:generateDebugBuildConfig
:app:prepareLintJar UP-TO-DATE
:app:mainApkListPersistenceDebug
:app:generateDebugResValues
:app:generateDebugResources
:app:mergeDebugResources
:app:createDebugCompatibleScreenManifests
:app:processDebugManifest
:app:splitsDiscoveryTaskDebug
:app:processDebugResources
:app:generateDebugSources
:app:javaPreCompileDebug
Note: C:\Users\eric_\Desktop\adventures of AZ styles\azstyles.buildv2021-05-16\android\app\src\main\java\com\cerberus\cerberusgame\CerberusGame.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
:app:compileDebugJavaWithJavac
:app:compileDebugNdk NO-SOURCE
:app:compileDebugSources
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:app:mergeDebugAssets
:app:transformClassesWithDexBuilderForDebug
:app:transformDexArchiveWithExternalLibsDexMergerForDebug
:app:transformDexArchiveWithDexMergerForDebug
:app:mergeDebugJniLibFolders
:app:transformNativeLibsWithMergeJniLibsForDebug
:app:checkDebugLibraries
:app:processDebugJavaRes NO-SOURCE
:app:transformResourcesWithMergeJavaResForDebug
:app:validateSigningDebug
:app:packageDebug
:app:assembleDebug
:app:installDebug
09:33:14 V/ddms: execute: running am get-config
09:33:14 V/ddms: Got reply 'FAIL', diag='closed'

09:33:14 E/ddms: ADB rejected shell command (am get-config): closed
09:33:14 V/ddms: execute: returning
:app:installDebug FAILED
29 actionable tasks: 28 executed, 1 up-to-date
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:installDebug'.
> com.android.builder.testing.api.DeviceException: com.android.ddmlib.AdbCommandRejectedException: closed

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --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 10s
TRANS FAILED: Android build failed.
Done.
 

dawlane

Well-known member
CX Code Contributor
Joined
Jun 21, 2017
Messages
813
Make sure that the developer mode is enabled on the Android device. Install any USB drivers if required on the host system. Keep an eye on the android device as sometimes you can miss the except dialog for the connection to allow the PC to upload the apk etc to the device.
 

Dubbsta

Active member
Joined
Jul 13, 2017
Messages
194
No device plugged in at all, just want to build an APK and install Manually

Do I need a device plugged in?
Built an APK before no problems figured some things needed updating
 
Last edited:

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,988
Well, judging from the messages, the build process should be fine. It is just the automatic installation that is failing. But I will try myself.
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,988
But I will try myself.
Just tried. When I build without a device connected, I get the same message like you.
But the apk is created:
1623333797297.png
 

Dubbsta

Active member
Joined
Jul 13, 2017
Messages
194
Ok thanks Mike I will check when I get home
Can you explain or point me to some info on the device part of this. Is it phone and what happens exactly?
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,988
At this point CX gives the ADB tool of Android Studio the command to install it onto a connected device like a phone or a simulator that is already active.
And that part can't be done.
 

Dubbsta

Active member
Joined
Jul 13, 2017
Messages
194
cool seems i just forgot where to find it! But when i build a release ver. it says waiting for device forever, did i possibly install something i shouldnt have or is there a way to bypass that thanks
 

MikeHart

Administrator
Joined
Jun 19, 2017
Messages
2,988
That's just hie it up. Press the button. The app should be there.
 
Top Bottom