Quantcast
Channel: Questions in topic: "android-sdk"
Viewing all 190 articles
Browse latest View live

Unity won't accept Android SDK Location

$
0
0
I'm trying to [set up my Unity for VR Development][1] and trying to right now setup the Android SDK following [Unity's online guide][2]. I have installed the SDK (platform-28), as well as the platform tools, build tools and USB Driver via the command line tool and it downloaded the folders. ---------- ![This is the content of the android-28 folder.][3] ---------- Now I am trying to set that location in the *"Preferences -> External Tools"* Window inside of Unity, but whenever I browse to the "android-28"-folder, Unity tells me that it can't find a SDK at that location. I am on **Windows** and **Unity 2018.3.9f1**. [1]: https://developers.google.com/vr/develop/unity/get-started-android [2]: https://docs.unity3d.com/Manual/android-sdksetup.html [3]: https://i.imgur.com/ETsKFl0.png

android build problems with latest build tools and java version

$
0
0
With the latest version of unity 2018.3.9f1, Is it now safe to update java to java 9 and update latest build tools when building for android? in the past i ran into problems building for android and this seems to be a known problem! from what i found doing an online search people was saying to use java version 8 and downgrade build tools to 25.2.5 which i have been previously doing and that seems to solve it but i dont like the idea of using old build tools version and old java as i am constantly getting notification to update java on my windows pc and can not update it due to not being able to build to android in unity if i do update. Is this ever going to be solved? appreciate help on this thank you

Unity Fails to Build to Android Device - INSTALL_PARSE_FAILED_NOT_APK: Failed to parse. How to solve this?

$
0
0
- Running Unity 2018.3.10f1 - AR Application, Running Vuforia 8.0.10 - Running Google Firebase Auth / Storage for download of Asset Bundles per User ---------- Until very recently, this app has functioned fine. I have dozens of previous successful APK/OBB duos. Now, since a handful of updates and bug fixes (Firebase to 5.6.0, etc), my export functionality has stalled. Upon an attempt to actually side-load a new APK/OBB onto a device for further testing, I get a Parse Error: ---------- CommandInvokationFailure: Unable to install APK to device. Please make sure the Android SDK is installed and is properly configured in the Editor. See the Console for more details. ---------- Further: C:\Users\[USER]\AppData\Local\Android\sdk\platform-tools\adb.exe -s "HT7530206306" install -r "C:\Users\[USER]\[FILEPATH]\AR View0.8.0.apk" stderr[ adb: failed to install C:\Users\USER\[FILEPATH]\AR View0.8.0.apk: Failure [**INSTALL_PARSE_FAILED_NOT_APK: Failed to parse /data/app/vmdl1540219450.tmp/base.apk**] ---------- stdout [Performing Streamed Install] exit code: 1 ---------- At this point I'm lost on what to do. I have: - Uninstalled/Reinstalled Android Studio - Updated Unity to Current Version - Tried this in a BLANK Unity project and gotten the same error - Made sure that my device (I think?) no longer has any versions of the app present on it. - Created a new signing certificate and tried both new and old.. What else IS there? Thanks for your help!

CommandInvokationFailure: Gradle build failed when build android apk

$
0
0
Hei, anyone can help me because i'm a newbie on unity especially on building android app with unity. I have done with my code and i want to produce it into .apk file but i get some errors, like this : And i have surfing for a day and do some of unity forums comment to fixed this error but it doesn't work at all. Please help me :( I use Unity 2017.4.25f1 64bit (LTS Version) and Jdk 8u161 with SDK Manager version on android 29.0.0 > CommandInvokationFailure: Gradle build failed. > C:/ProgramFiles/Java/jdk1.8.0_161\bin\java.exe -classpath "C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer\Tools\gradle\lib\gradle-launcher-4.6.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease" ----- > stderr[> FAILURE: Build failed with an> exception.>> * What went wrong: A problem occurred configuring root project 'gradleOut'.>> Failed to find Build Tools revision 29.0.0>> * 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 3s ] stdout[>> ] exit code: 1> UnityEditor.Android.Command.WaitForProgramToRun> (UnityEditor.Utils.Program p,> UnityEditor.Android.WaitingForProcessToExit> waitingForProcessToExit, System.String> errorMsg)> UnityEditor.Android.Command.Run> (System.Diagnostics.ProcessStartInfo> psi,> UnityEditor.Android.WaitingForProcessToExit> waitingForProcessToExit, System.String> errorMsg)> UnityEditor.Android.AndroidJavaTools.RunJava> (System.String args, System.String> workingdir, System.Action`1 progress,> System.String error)> UnityEditor.Android.GradleWrapper.Run> (System.String workingdir,> System.String task, System.Action`1> progress) Rethrow as> GradleInvokationException: Gradle> build failed> UnityEditor.Android.GradleWrapper.Run> (System.String workingdir,> System.String task, System.Action`1> progress)> UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute> (UnityEditor.Android.PostProcessor.PostProcessorContext> context)> UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks> (UnityEditor.Android.PostProcessor.PostProcessorContext> context)> UnityEngine.GUIUtility:ProcessEvent(Int32,> IntPtr)

Unity is building older version of my game

$
0
0
I am making an android game, but whenever I try to build my game, Unity builds my game using the older scripts.Any changes in scene mode, liking adding gameobjects and other things are showing up in the build, just the scripts are not working fine. So far I have tried doing this - Change my build directory - Change my build name - Delete cache files, Library and Obj folders - Reimport everything - Delete and add scene again Plus, there is no error in console when I build my game. Help please !

UnityWebRequest returning responseCode 0 and isNetworkError == true for Unity 2019

$
0
0

From my Android app I execute a http PUT request with JSON:


String fullUrl = "http://myserver.com/mycontroller/loginJson.json"; UnityWebRequest www = UnityWebRequest.Put(fullUrl,json); www.SetRequestHeader("Content-Type", "application/json"); yield return www.SendWebRequest();

This code works fine when building with Unity 2018.4.1f1. But if I build with Unity 2019.1.6f1 I get:


www.error : "Unknown" www.responseCode: 0 www.isNetworkError: true www.isHttpError: false www.downloadHandler.text : ""

When I run this code directly in unity, it works fine, and I have no problems communicating with the server. Only building to Android in Unity 2019.1 doesn't work. I also tried the new 2019.3.0a5, and there the Android version also works. This is quite a mystery.

Anyone have any idea what's going on?


=== UPDATE 2019-06-22 === I've found that it's probably not related to Unity, but to the Android SDK. If I build with API level 27 (8.1), it works fine, but with API level 29 (9.0), I get the "Unknown Error". I'll continue to look into this. =======================

Gradle build error Unity 2019.1.6f1

$
0
0
I found out that unity has deprecated the internal build system and has defaulted to gradle. I've not built with the gradle build system before, and now after upgrading to unity 2019.1 full version, I can't build an android project. Here are the screenshots when my build is almost completed: ![Screenshot1][1] ![Screenshot2][2] ![Screenshot3][3] ![Screenshot4][4] ![Screenshot5][5] ![Screenshot6][6] [1]: https://gyazo.com/8498a93d45c0f5e3ce1a05f94499fb27 [2]: https://gyazo.com/9546860c1fbab64063ebbb8b892854a5 [3]: ttps://gyazo.com/a1c74396a232cf7f7a56d44d994825a6 [4]: https://gyazo.com/242c3428489ff0a914d478e089cc430c [5]: https://gyazo.com/8701428d7aa73d1077f2358ed2942535 [6]: https://gyazo.com/615f1224e3857ff17ddd0e8c2cac8ae1 And, I installed the android module using unity hub, what can I do to fix this?

Submesh interaction in Android

$
0
0
I know of a Unity built android app that allows user to interact with the sub-meshes of an object (in OBJ, or glTF). However, when I am trying to do that natively in Android, I don't see any such option. The moment you import OBJ with MTL and other PNGs, it is all combined as one object and hence submesh information is lost. Would anyone know how Unity does it and how I can do it in Android native, if at all possible? Any help will be much appreciated.

Run by run on android building

$
0
0
I have a problem that I have been having with building 64 bit games with unity (this is required to upload games onto the play store). I have tried using IL2CPP backend, as well as using ARM64 but always come up with errors. I was wondering if someone could just write up an answer which contains all the instructions required to build an android project which will be accepted by Google. Unity editor version: 2019.3.0b7

Recommend Android Setup with Unity

$
0
0
I know this topic is too old and basic according to nowadays, but i am too eager to ask here the in depth understanding of Android Setup with Unity that how it works and how to tackle specific problem when faced with. My Question is about SDK, NDK, JDK and Gradle Build of Unity Generally (with Normal Version of Unity). I am not specific to a device with bla bla android version. So What is the minimum Android SDK (I have no concept of what is build tool for? platform tool for? etc etc) version to be kept for normal Android Builds (Gradle as default) ? I want to keep SDK size as much optimized(Minimum) as possible to do my work smoothly. Now What is the relation of SDK with JDK or NDK? or Vice versa... Also clearify Minimum API Level and TargetAPI Level in Unity Player Settings with these..Which JDK is better or recommended? As NDK have not make issues with me So I am OK with NDK(as Unity clearly says NDK version accordingly with Unity) but i still have confusion what is NDK? Sorry I have too many confusions :) :p .. If someone clear my concept about these confusions I will be thankful as i will be glad to be answered politely, concise and to the point. P.S. I have searched google a lot, unity answers, stackoverflow (tell me any other good place to search for :) ) So dont tell me to google please answer me here so clearly that i am satisfied. Thanks in Advance..

Some Functions Not Working After Android Build

$
0
0
Hello i am karan and i am beginner in unity3d game development and i have completed a game in unity and in unity editor it is working fine but in my android device working good but there is missing some function like when player win the win pannel is not opening in android device but in editor it is working properly and also in not working sound mute button in android but in editor it is working fine so please help me to solve this i am getting this problem after admob intigration

Unity Gradle Build failed 2019.3.0f6

$
0
0
Hi everyone, I am having an issue building my project for Android. I have installed new JDK and modified the Path in Unity preferences These are the errors that prevent me from finishing the build ![alt text][1] If anyone could help me with this I would be extremely grateful! EDIT: Fixed the issues with licenses, now I am getting these errors: ![alt text][2] [1]: /storage/temp/153523-screen-shot-2020-03-02-at-32550-pm.png [2]: /storage/temp/153526-screen-shot-2020-03-02-at-34543-pm.png

how can i fix these problem CommandInvokationFailure: Failed to re-package resources

$
0
0
CommandInvokationFailure: Failed to re-package resources. C:\Users\win\AppData\Local\Android\Sdk\build-tools\29.0.3\aapt.exe package --auto-add-overlay -v -f -m -J "gen" -M "AndroidManifest.xml" -S "res" -I "C:/Users/win/AppData/Local/Android/Sdk\platforms\android-29\android.jar" -F bin/resources.ap_ stderr[ ] stdout[ ] exit code: -1073741515 UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) UnityEditor.Android.PostProcessor.Tasks.TasksCommon.Exec (System.String command, System.String args, System.String workingdir, System.String errorMsg, Int32 retriesOnFailure) UnityEditor.HostView:OnGUI()

Android SDK

$
0
0
Hi. Everytime i want to press play game and remote it to my phone, this error is showing. SDK path is choosed, everything is choosed but its not working. [1]: /storage/temp/157365-137567-capture1.jpg

Unity can't detect SDK tools thougt I've installed them!

$
0
0
I'm using Unity 2019.3.13f1 ; when I installed this version in the unity hub I chose to download the android tools but when I'm in the project and open preferences under SDK tools this error is reported :> You are missing the recomended android sdk tools. Install the recomended version using Unity Hub As a consequence I can't test my project on an android device. I don't know wath to do becouse I've installe them and they are in the correct folter so the error message seems "fake". I've already tried to uinstal/reinstall unity. Please help!!!!!!

Debug apk is working but Signed apk apk is not working after inetgrating unity module into Android app

$
0
0
Hi, I am just trying to integrate unity module in my android application. I followed below approach. **link**: [https://forum.unity.com/threads/merging-unity-project-into-native-android-application.660358/](https://forum.unity.com/threads/merging-unity-project-into-native-android-application.660358/) just followed all the steps as in the link. With **debug_apk** I am able to navigate to unity module from Android application and its working fine. With **release_apk** the application is crashing while navigating to unity module with issue reason as **Fatal exception [UNITY]** Any suggestions are appreciated.

Unable to install APK to Oculus Quest

$
0
0
I keep getting this error when I trying to install to my Oculus Quest. I have checked the names in the build settings and they match. Device seems to go offline after each failed build attempt. Unity is complaining about the JDK not being the right version, but I got it to work despite this error before this error appeared. And yes, Unity Hub Can't seem to install OpenJDK... what a mess! Any help is greatly appreciated! CommandInvokationFailure: Unable to install APK to device. Please make sure the Android SDK is installed and is properly configured in the Editor. See the Console for more details. C:/Program Files/Unity/Hub/Editor/2019.3.14f1/Editor/Data/PlaybackEngines/AndroidPlayer\SDK\platform-tools\adb.exe -s "1PASH9AL899465" install -r -d "C:\Users\jande\Documents\Unity Projects\Star Map\Builds\StarMap.apk"

Build android failed because of minSdkVersion in Easy Mobile AndroidManifest.xml

$
0
0
> Manifest merger failed : uses-sdk:minSdkVersion 19 cannot be different than version __AndroidManifest_MinSdkVersion__ declared in library [:unityLibrary:EasyMobile] D:\GAMEDEV\GooglePlay\New Unity Project (2)\Temp\gradleOut\unityLibrary\EasyMobile\build\intermediates\library_manifest\release\AndroidManifest.xml> . I got this error when I build my android project, I could build my project to APK before, but after I import EasyMobile to my project, I got this error message when I want to build. What should I do to keep the easymobile and fix this error to build my project to APK?

Unity external dependency manager resolution failed

$
0
0
Hi, I have imported Firebase packages (FirebaseAuth, FirebaseStore, FirebaseFunctions & FirebaseAnalytics) but I am getting below error while running external dependency manager android resolution. Resolution failed Failed to fetch the following dependencies: com.google.firebase:firebase-app-unity:+ com.google.firebase:firebase-auth-unity:+ UnityEngine.Debug:LogError(Object) Google.Logger:Log(String, LogLevel) (at Z:/tmp/tmp.1ZjQmjdN1r/third_party/unity/unity_jar_resolver/source/VersionHandlerImpl/src/Logger.cs:136) GooglePlayServices.PlayServicesResolver:Log(String, LogLevel) (at Z:/tmp/tmp.yLOL0ktbPv/third_party/unity/unity_jar_resolver/source/AndroidResolver/src/PlayServicesResolver.cs:990) GooglePlayServices.GradleResolver:LogMissingDependenciesError(List`1) (at Z:/tmp/tmp.yLOL0ktbPv/third_party/unity/unity_jar_resolver/source/AndroidResolver/src/GradleResolver.cs:95) GooglePlayServices.c__AnonStorey8:<>m__1(List`1) (at Z:/tmp/tmp.yLOL0ktbPv/third_party/unity/unity_jar_resolver/source/AndroidResolver/src/GradleResolver.cs:912) GooglePlayServices.c__AnonStorey1:<>m__0() (at Z:/tmp/tmp.yLOL0ktbPv/third_party/unity/unity_jar_resolver/source/AndroidResolver/src/GradleResolver.cs:375) I am also getting a warning along with error Some conflicting dependencies were found. The following dependency versions were modified: com.google.android.gms:play-services-auth:11.4.0 --> com.google.android.gms:play-services-auth:+ com.google.firebase:firebase-analytics:17.4.1 --> com.google.firebase:firebase-analytics:+ com.google.firebase:firebase-app-unity:6.15.0 --> com.google.firebase:firebase-app-unity:+ com.google.firebase:firebase-auth:19.3.1 --> com.google.firebase:firebase-auth:+ com.google.firebase:firebase-auth-unity:6.15.0 --> com.google.firebase:firebase-auth-unity:+ com.google.firebase:firebase-common:19.3.0 --> com.google.firebase:firebase-common:+ com.google.firebase:firebase-firestore:21.4.3 --> com.google.firebase:firebase-firestore:+ com.google.firebase:firebase-functions:19.0.2 --> com.google.firebase:firebase-functions:+ UnityEngine.Debug:LogWarning(Object) Google.Logger:Log(String, LogLevel) (at Z:/tmp/tmp.1ZjQmjdN1r/third_party/unity/unity_jar_resolver/source/VersionHandlerImpl/src/Logger.cs:129) GooglePlayServices.PlayServicesResolver:Log(String, LogLevel) (at Z:/tmp/tmp.yLOL0ktbPv/third_party/unity/unity_jar_resolver/source/AndroidResolver/src/PlayServicesResolver.cs:990) GooglePlayServices.c__AnonStorey1:<>m__2(Result) (at

com.android.tools.r8 compilation error please help

$
0
0
I can't build my android apk from unity it says com.android.tools.r8 compilation error please help guys.
Viewing all 190 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>