- Home /
Android build failing.
I'm using Unity 2017.4.3f1, and am having trouble building for android using Gradle. I've assigned the correct path in preferences to the SDK (it selected it automatically). I'm running OSX Mojave, version 10.14.5. As for android settings, here's a picture of the error and my settings: https://imgur.com/a/ztpq8uc. My minimum API level is set to be 4.1, and my target is the highest installed. I've tried installing different SDK levels with little result, but currently only have 9.+ (API level 29, "Q") and 7.1.1 (API Level 25, "Nougat") installed, along with everything from the SDK tools tab, including Google Play Services. But when I build, I get the following error:
CommandInvokationFailure: Gradle build failed.
/Applications/Unity/Hub/Editor/2018.4.3f1/PlaybackEngines/AndroidPlayer/Tools/OpenJDK/MacOS/bin/java -classpath "/Applications/Unity/Hub/Editor/2018.4.3f1/PlaybackEngines/AndroidPlayer/Tools/gradle/lib/gradle-launcher-4.6.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "bundleRelease"
stderr[
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':bundleReleaseResources'.
> java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
Output: /Users/breeze/apps/living-room/Temp/gradleOut/build/intermediates/merged_manifests/release/processReleaseManifest/merged/AndroidManifest.xml:101: error: resource integer/google_play_services_version (aka com.mycompanyname.appname:integer/google_play_services_version) not found.
error: failed processing manifest.
I'm fairly sure there's something wrong with my android setup, because I was building this project previously with 2018.3 when my computer crashed, and now I've started using a new computer, and gotten this. Could anyone tell me what might be wrong with my setup, or what this error might mean? I'm confused and can't seem to find anything that works. A few of the questions I've seen tell me to check the manifest, but I don't see any manifest in my /Assets folder, nor do I know why I would have to modify this now, since I've never had to do it before.
Your answer
Follow this Question
Related Questions
Android App not showing in Play search results? 1 Answer
Google Play not accepting android manifest 0 Answers
Failed repacking when building android game 4 Answers
Social.localUser.Authenticate((bool success) returns no bool 1 Answer
Google play says i have "in app purchases" but i dont... 3 Answers