Getting error "java.exe exited with code 2"

Richy_GeorgeRichy_George INMember ✭✭✭

2>Using "CompileToDalvik" task from assembly "C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Build.Tasks.dll".
2>Task "CompileToDalvik" (TaskId:419)
2> Task Parameter:DxJarPath=C:\LinkToAndroidSDK\build-tools\25.0.2\lib\dx.jar (TaskId:419)
2> Task Parameter:JavaToolPath=C:\LinkToJava8\bin (TaskId:419)
2> Task Parameter:JavaMaximumHeapSize=1024m (TaskId:419)
2> Task Parameter:ClassesOutputDirectory=obj\Debug\android\bin\classes (TaskId:419)
2> Task Parameter:MultiDexEnabled=False (TaskId:419)
2> Task Parameter:MultiDexMainDexListFile=obj\Debug\multidex.keep (TaskId:419)
2> Task Parameter:
2> JavaLibrariesToCompile=
2> C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v7.1\mono.android.jar
2> obj\Debug__library_projects__\FormsViewGroup\library_project_imports\formsviewgroup.jar
2> obj\Debug__library_projects__\OkHttp\library_project_imports\okhttp-2.3.0-jar-with-dependencies.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Animated.Vector.Drawable\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Compat\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Core.UI\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Core.Utils\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.CustomTabs\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Design\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Fragment\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Media.Compat\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.v4\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.AppCompat\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.CardView\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.MediaRouter\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.RecyclerView\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Android.Support.Vector.Drawable\library_project_imports\classes.jar
2> obj\Debug__library_projects__\Xamarin.Azure.NotificationHubs.Android\library_project_imports\bin\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads.Lite\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Base\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Basement\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Clearcut\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gass\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gcm\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Iid\9.6.1\embedded\classes.jar
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Tasks\9.6.1\embedded\classes.jar (TaskId:419)
2> Task Parameter:OptionalObfuscatedJarFile=obj\Debug\proguard__proguard_output__.jar (TaskId:419)
2> CompileToDalvik (TaskId:419)
2> JavaOptions: (TaskId:419)
2> JavaMaximumHeapSize: 1024m (TaskId:419)
2> ClassesOutputDirectory: obj\Debug\android\bin\classes (TaskId:419)
2> JavaToolPath: C:\LinkToJava8\bin (TaskId:419)
2> DxJarPath: C:\LinkToAndroidSDK\build-tools\25.0.2\lib\dx.jar (TaskId:419)
2> ToolExe: java.exe (TaskId:419)
2> ToolPath: (TaskId:419)
2> UseDx: False (TaskId:419)
2> MultiDexEnabled: False (TaskId:419)
2> MultiDexMainDexListFile: obj\Debug\multidex.keep (TaskId:419)
2> JavaLibrariesToCompile: (TaskId:419)
2> C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v7.1\mono.android.jar (TaskId:419)
2> obj\Debug__library_projects__\FormsViewGroup\library_project_imports\formsviewgroup.jar (TaskId:419)
2> obj\Debug__library_projects__\OkHttp\library_project_imports\okhttp-2.3.0-jar-with-dependencies.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Animated.Vector.Drawable\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Compat\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Core.UI\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Core.Utils\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.CustomTabs\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Design\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Fragment\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Media.Compat\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.v4\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.AppCompat\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.CardView\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.MediaRouter\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.v7.RecyclerView\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Android.Support.Vector.Drawable\library_project_imports\classes.jar (TaskId:419)
2> obj\Debug__library_projects__\Xamarin.Azure.NotificationHubs.Android\library_project_imports\bin\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads.Lite\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Base\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Basement\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Clearcut\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gass\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gcm\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Iid\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Tasks\9.6.1\embedded\classes.jar (TaskId:419)
2> C:\LinkToJava8\bin\java.exe -Xmx1024m -jar C:\LinkToAndroidSDK\build-tools\25.0.2\lib\dx.jar --no-strict --dex --output=obj\Debug\android\bin obj\Debug\android\bin\classes "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v7.1\mono.android.jar" obj\Debug__library_projects__\FormsViewGroup\library_project_imports\formsviewgroup.jar obj\Debug__library_projects__\OkHttp\library_project_imports\okhttp-2.3.0-jar-with-dependencies.jar obj\Debug__library_projects__\Xamarin.Android.Support.Animated.Vector.Drawable\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Compat\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Core.UI\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Core.Utils\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.CustomTabs\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Design\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Fragment\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Media.Compat\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.v4\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.v7.AppCompat\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.v7.CardView\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.v7.MediaRouter\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.v7.RecyclerView\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Android.Support.Vector.Drawable\library_project_imports\classes.jar obj\Debug__library_projects__\Xamarin.Azure.NotificationHubs.Android\library_project_imports\bin\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Ads.Lite\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Base\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Basement\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Clearcut\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gass\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Gcm\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Iid\9.6.1\embedded\classes.jar C:\Users\richy\AppData\Local\Xamarin\Xamarin.GooglePlayServices.Tasks\9.6.1\embedded\classes.jar (TaskId:419)
2> (TaskId:419)
2> trouble writing output: Too many field references: 72871; max is 65536. (TaskId:419)
2> You may try using --multi-dex option. (TaskId:419)
2> References by package: (TaskId:419)
2> 2305 android.support.v4 (TaskId:419)
2> 13 android.support.v4.accessibilityservice (TaskId:419)
2> 17 android.support.v4.animation (TaskId:419)
2> 885 android.support.v4.app (TaskId:419)
2> 114 android.support.v4.content (TaskId:419)
2> 1 android.support.v4.content.pm (TaskId:419)
2> 1 android.support.v4.content.res (TaskId:419)
2> 11 android.support.v4.graphics (TaskId:419)
2> 41 android.support.v4.graphics.drawable (TaskId:419)
2> 4 android.support.v4.hardware.display (TaskId:419)
2> 12 android.support.v4.hardware.fingerprint (TaskId:419)
2> 10 android.support.v4.internal.view (TaskId:419)
2> 388 android.support.v4.media (TaskId:419)
2> 379 android.support.v4.media.session (TaskId:419)
2> 10 android.support.v4.net (TaskId:419)
2> 19 android.support.v4.os (TaskId:419)
2> 63 android.support.v4.print (TaskId:419)
2> 10 android.support.v4.provider (TaskId:419)
2> 55 android.support.v4.text (TaskId:419)
2> 6 android.support.v4.text.util (TaskId:419)
2> 118 android.support.v4.util (TaskId:419)
2> 434 android.support.v4.view (TaskId:419)
2> 138 android.support.v4.view.accessibility (TaskId:419)
2> 8 android.support.v4.view.animation (TaskId:419)
2> 495 android.support.v4.widget (TaskId:419)
2> 605 android.support.v7.app (TaskId:419)
2> 2305 android.support.v7.appcompat (TaskId:419)
2> 2305 android.support.v7.cardview (TaskId:419)
2> 8 android.support.v7.content.res (TaskId:419)
2> 18 android.support.v7.graphics.drawable (TaskId:419)
2> 437 android.support.v7.media (TaskId:419)
2> 2305 android.support.v7.mediarouter (TaskId:419)
2> 2305 android.support.v7.recyclerview (TaskId:419)
2> 1 android.support.v7.text (TaskId:419)
2> 2 android.support.v7.transition (TaskId:419)
2> 124 android.support.v7.util (TaskId:419)
2> 77 android.support.v7.view (TaskId:419)
2> 249 android.support.v7.view.menu (TaskId:419)
2> 1483 android.support.v7.widget (TaskId:419)
2> 89 android.support.v7.widget.helper (TaskId:419)
2> 1 android.support.v7.widget.util (TaskId:419)
2> 5 android.text (TaskId:419)
2> 1 android.text.util (TaskId:419)
2> 12 android.util (TaskId:419)
2> 19 android.view (TaskId:419)
2> 8 android.view.accessibility (TaskId:419)
2> 1 android.view.inputmethod (TaskId:419)
2> 5 android.webkit (TaskId:419)
2> 15 android.widget (TaskId:419)
2> 2299 app2.droid (TaskId:419)
2> 25 com.google.ads (TaskId:419)
2> 22 com.google.ads.mediation (TaskId:419)
2> 11 com.google.ads.mediation.customevent (TaskId:419)
2> 2299 com.google.android.gms (TaskId:419)
2> 20 com.google.android.gms.actions (TaskId:419)
2> 2342 com.google.android.gms.ads (TaskId:419)
2> 12 com.google.android.gms.ads.doubleclick (TaskId:419)
2> 19 com.google.android.gms.ads.formats (TaskId:419)
2> 13 com.google.android.gms.ads.identifier (TaskId:419)
2> 2299 com.google.android.gms.ads.impl (TaskId:419)
2> 256 com.google.android.gms.ads.internal (TaskId:419)
2> 22 com.google.android.gms.ads.internal.cache (TaskId:419)
2> 222 com.google.android.gms.ads.internal.client (TaskId:419)
2> 100 com.google.android.gms.ads.internal.formats (TaskId:419)
2> 158 com.google.android.gms.ads.internal.overlay (TaskId:419)
2> 51 com.google.android.gms.ads.internal.purchase (TaskId:419)
2> 197 com.google.android.gms.ads.internal.request (TaskId:419)
2> 14 com.google.android.gms.ads.internal.reward.client (TaskId:419)
2> 6 com.google.android.gms.ads.internal.reward.mediation.client (TaskId:419)
2> 6 com.google.android.gms.ads.internal.safebrowsing (TaskId:419)
2> 17 com.google.android.gms.ads.internal.util.client (TaskId:419)
2> 22 com.google.android.gms.ads.mediation (TaskId:419)
2> 1 com.google.android.gms.ads.mediation.admob (TaskId:419)
2> 12 com.google.android.gms.ads.mediation.customevent (TaskId:419)
2> 7 com.google.android.gms.ads.purchase (TaskId:419)
2> 1 com.google.android.gms.ads.reward.mediation (TaskId:419)
2> 46 com.google.android.gms.ads.search (TaskId:419)
2> 36 com.google.android.gms.auth.api.signin (TaskId:419)
2> 6 com.google.android.gms.auth.api.signin.internal (TaskId:419)
2> 2299 com.google.android.gms.base (TaskId:419)
2> 2345 com.google.android.gms.clearcut (TaskId:419)
2> 98 com.google.android.gms.common (TaskId:419)
2> 2393 com.microsoft.windowsazure.messaging (TaskId:419)
2> 342 com.squareup.okhttp (TaskId:419)
2> 86 com.squareup.okhttp.internal (TaskId:419)
2> 126 com.squareup.okhttp.internal.http (TaskId:419)
2> 1 com.squareup.okhttp.internal.io (TaskId:419)
2> 243 com.squareup.okhttp.internal.spdy (TaskId:419)
2> 11 com.squareup.okhttp.internal.tls (TaskId:419)
2> 1 com.xamarin.forms.platform.android (TaskId:419)
2> 25 java.lang (TaskId:419)
2> 7 java.lang.annotation (TaskId:419)
2> 1 java.math (TaskId:419)
2> 6 java.net (TaskId:419)
2> 1 java.nio (TaskId:419)
2> 6 java.util (TaskId:419)
2> 4 java.util.concurrent (TaskId:419)
2> 3 java.util.logging (TaskId:419)
2> 4 javax.microedition.khronos.egl (TaskId:419)

2> 4 mono.com.google.ads.mediation (TaskId:419)
2> 2 mono.com.google.ads.mediation.customevent (TaskId:419)
2> 4 mono.com.google.android.gms.ads.doubleclick (TaskId:419)
2> 8 mono.com.google.android.gms.ads.formats (TaskId:419)
2> 8 mono.com.google.android.gms.ads.mediation (TaskId:419)
2> 2 mono.com.google.android.gms.ads.mediation.customevent (TaskId:419)
2> 4 mono.com.google.android.gms.ads.purchase (TaskId:419)
2> 2 mono.com.google.android.gms.ads.reward (TaskId:419)
2> 2 mono.com.google.android.gms.ads.reward.mediation (TaskId:419)
2> 2 mono.com.google.android.gms.common.api (TaskId:419)
2> 2 mono.com.google.android.gms.common.images (TaskId:419)
2> 2 mono.com.google.android.gms.security (TaskId:419)
2> 6 mono.com.google.android.gms.tasks (TaskId:419)
2> 4 mono.java.lang (TaskId:419)
2> 2 mono.java.util (TaskId:419)
2> 2 mono.javax.xml.transform (TaskId:419)
2> 81 okio (TaskId:419)
2> 2 opentk (TaskId:419)
2> 2 opentk.platform.android (TaskId:419)
2> 2 opentk_1_0 (TaskId:419)
2> 2 opentk_1_0.platform.android (TaskId:419)
2>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1965,3): error MSB6006: "java.exe" exited with code 2.
2> DexOutputs: (TaskId:419)
2>Done executing task "CompileToDalvik" -- FAILED. (TaskId:419)
2>Done building target "_CompileToDalvikWithDx" in project "App2.Droid.csproj" -- FAILED.: (TargetId:353)
2>
2>Project Performance Summary:
2> 42 ms \TF-RICHY\Aboo_share_win10\Backup\New app2 droid\App2 - Android\App2\App2\App2.csproj 3 calls
2> 34 ms GetTargetPath 1 calls
2> 1 ms GetNativeManifest 1 calls
2> 7 ms GetCopyToOutputDirectoryItems 1 calls
2> 189298 ms \TF-RICHY\Aboo_share_win10\Backup\New app2 droid\App2 - Android\App2\App2.Droid\App2.Droid.csproj 1 calls
2> 189298 ms Rebuild 1 calls
2>

2>
2>Build FAILED.
2>
2>Time Elapsed 00:03:09.29
========== Rebuild All: 1 succeeded, 1 failed, 0 skipped ==========

Best Answers

Answers

  • Richy_GeorgeRichy_George INMember ✭✭✭

    Thanks @moljac and @VenkataSwamyBalaraju for the reply.

    But after turning the MultiDex On I'm getting this error.
    Error Can't read [C:\Windows\obj\Debug__library_projects__\FormsViewGroup\library_project_imports\formsviewgroup.jar] (No such file or directory) App2.Droid \App2 - Android\App2\App2.Droid\CREATEMULTIDEXMAINDEXCLASSLIST

  • Richy_GeorgeRichy_George INMember ✭✭✭
    edited June 2017

    @moljac

    Thanks Man, After all updates of build tools and nugets the build become success. But now I'm getting "system.NullReferenceException: Object reference not set to an instance of an object." exception at "presenter.Login(authenticator);" earlier I'm getting the native UI for google authentication. (Maybe because of PlatformLogin value of OAuthLoginPresenter is getting null when initializing).

  • Richy_GeorgeRichy_George INMember ✭✭✭

    @moljac
    Thanks Man, My bad , forgot to initialize Presenters.

  • Richy_GeorgeRichy_George INMember ✭✭✭

    @moljac

    Do you know this issue; apps running on android versions below 5.0 are now crashing , the error is as follows.

    java.lang.RuntimeException: Unable to instantiate application md5f572a367545c726927cb2f01519d90dd.MainApplication: java.lang.ClassNotFoundException: Didn't find class "md5f572a367545c726927cb2f01519d90dd.MainApplication" on path: DexPathList[[zip file "/data/app/app2.Droid-1.apk"],nativeLibraryDirectories=[/data/app-lib/app2.Droid-1, /vendor/lib, /data/cust/lib, /system/lib, /data/datalib]]

  • EarlRemdioEarlRemdio USMember

    @BalaRaju said:
    Hi @Richy_George,

    As @moljac said we need to turn on MultiDex

    VisualStudio:

    RightClick on Xamarin.Android--->Goto Properties-->AndroidOptions-->Now Enable MultiDex

    XamarinStudio:

    DoubleClick on Xamarin.Android-->AndroidOptions-->Now EnableMutiDex

  • AnkitVermaAnkitVerma USMember ✭✭

    Hi, @moljac @BalaRaju @Richy_George,

    I have Enable MultiDex enabled from my Xamarin Android project but when I am trying to create the build using VSTS then I am getting the error. When I am building using Visual studio than its working fine.

    RightClick on Xamarin.Android--->Goto Properties-->AndroidOptions-->Enable MultiDex

    Following the error that I received, All the NuGet packages are updated, using JAVA8 and target version is 8.0.

    "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028):C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(2028,3): Error MSB6006: "java.exe" exited with code 2.
    Process 'msbuild.exe' exited with code '1'."

  • pratik90pratik90 INMember ✭✭

    HI @AnkitVerma

    I also got the same error, are you able to fix that yet?

  • AnkitVermaAnkitVerma USMember ✭✭

    @pratik90 I was able to solve this error after updating xamarin. I update my VS 2017 along with other components and it worked.

  • pratik90pratik90 INMember ✭✭

    @AnkitVerma great, in my case I need to edit the android project and enable multiple dex on not only multidex, it requires multiple dex as well.

  • judsonabrahamjudsonabraham USMember ✭✭✭

    I'm getting error
    Severity Code Description Project File Line Suppression State
    Error The output jar [C:\Users\User3\AppData\Local\Temp] must have a filter, or all subsequent output jars will be empty. Aglive.Mobile.Android C:\git\Aglive-Mobile-V3\AndroidApp\Aglive.Mobile\src\Android\Aglive.Mobile.Android\CREATEMULTIDEXMAINDEXCLASSLIST
    when I'm enabling the MultiDex. how to fix it?

  • @moljac said:
    Turn MultiDex on!

    this solved my issue, thanks.

  • XigmondXigmond USMember ✭✭

    Severity Code Description Project File Line Suppression State
    Error MSB6006: "java.exe" exited with code 2. 0

    in my case building the project has no problem but it gives the error in deployment.
    and says that the deployment failed !

    anyone knows why?

  • @moljac said:
    Turn MultiDex on!

    This solved my issue too.
    Thank you

  • XigmondXigmond USMember ✭✭

    My problem was because of wrong values in the Application Signing and had nothing to do with MultiDex!

  • Try reset the keystore or change to false the key true.
    Only to check. But remembering that it needs to be set to true.

  • banditothbanditoth Member

    Check your keystore file at Android projects settings -> Android Signing -> Keystore
    Ensure the path exists on the developer enviroment.
    If you use version control, ensure the path does not points to other computers local appdata folder.

  • DavyHomesDavyHomes Member ✭✭

    @FilipePlucenio said:
    Try reset the keystore or change to false the key true.
    Only to check. But remembering that it needs to be set to true.

    THis did the trick for me. Thank you.

  • JassimRahmaJassimRahma USMember ✭✭✭✭

    I have same problem and unable to figure out where is the issue.

    I posted here with the log and screenshots to avoid multiple same post:

    https://forums.xamarin.com/discussion/comment/374407#Comment_374407

Sign In or Register to comment.