Visual Studio 2017 Xamarin INSTALL_FAILED_NO_MATCHING_ABIS

1

I am trying to compile an Android application that is made in Xamarin through a shared project in order to transport the logic to IOS in the future.

Until today, the project compiled without problems and was installed in the emulator (Nexus 5 with Android 5 API 22) without any problem. However, for nothing, every time I try to install the apk in the emulator I get the error:

INSTALL_FAILED_NO_MATCHING_ABIS

To make it better understood, I leave an extract of the compilation output:

...
2>TASK: Push bin\Release\CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk : /data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk completed?:Completed
2>DEBUG RunShellCommand emulator-5554 pm install "/data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk"
2>TASK: InstallPackage pm install "/data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk" completed?:  pkg: /data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk
2>Failure [I...
2>DEBUG RunShellCommand emulator-5554 rm "/data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk"
2>TASK: DeleteFile rm "/data/local/tmp/CompeticionesPalomosAndroid.CompeticionesPalomosAndroid-Signed.apk" completed?:
2> Deployment failed
2>Mono.AndroidTools.InstallFailedException: Failure [INSTALL_FAILED_NO_MATCHING_ABIS]
2>   en Mono.AndroidTools.Internal.AdbOutputParsing.CheckInstallSuccess(String output, String packageName) en /Users/builder/data/lanes/5147/c2a33d8e/source/monodroid/tools/msbuild/external/androidtools/Mono.AndroidTools/Internal/AdbOutputParsing.cs:línea 333
2>   en Mono.AndroidTools.AndroidDevice.<>c__DisplayClass94_0.<InstallPackage>b__0(Task'1 t) en /Users/builder/data/lanes/5147/c2a33d8e/source/monodroid/tools/msbuild/external/androidtools/Mono.AndroidTools/AndroidDevice.cs:línea 746
2>   en System.Threading.Tasks.ContinuationTaskFromResultTask'1.InnerInvoke()
2>   en System.Threading.Tasks.Task.Execute()
2>Failure [INSTALL_FAILED_NO_MATCHING_ABIS]
2>Ejecución de la tarea "InstallPackageAssemblies" terminada.
2>Tarea "Touch"
2>Parámetro de tarea:Files=obj\Release\upload.flag
2>Parámetro de tarea:AlwaysCreate=True
2>Se creará "obj\Release\upload.flag" porque se especificó "AlwaysCreate".
2>Ejecución de la tarea "Touch" terminada.
2>Se omitió la tarea "MakeDir" debido a una condición falsa (False); (!Exists('$(_ConfigurationCacheDirectory)')) se evaluó como (!Exists('obj\.cache\')).
2>Tarea "WriteLinesToFile"
2>Parámetro de tarea:File=obj\.cache\CompeticionesPalomosAndroid.CompeticionesPalomosAndroid.flag
2>Parámetro de tarea:Lines=ReleaseAnyCPU-s emulator-5554
2>Parámetro de tarea:Overwrite=True
2>Ejecución de la tarea "WriteLinesToFile" terminada.
2>Compilación terminada del destino "_Upload" en el proyecto "CompeticionesPalomosAndroid.csproj".
2>Destino "Install" en el archivo "C:\Program Files (x86)\Microsoft Visual Studio17\Community\MSBuild\Xamarin\Android\Xamarin.Android.Common.Debugging.targets" del proyecto "C:\Users\Jorge\source\repos\CompeticionesPalomos\CompeticionesPalomosAndroid\CompeticionesPalomosAndroid.csproj" (punto de entrada):
2>Compilación terminada del destino "Install" en el proyecto "CompeticionesPalomosAndroid.csproj".
2>Compilación del proyecto "CompeticionesPalomosAndroid.csproj" terminada.
2>Compilación correcta.
2>Failure [INSTALL_FAILED_NO_MATCHING_ABIS]
2>
2>Error de implementación en Nexus_5_API_22_3
========== Compilar: 1 correctos, 0 incorrectos, 0 actualizados, 0 omitidos ==========
========== Implementar: 0 correctos, 1 incorrectos, 0 omitidos ==========

I find it strange, because according to this, the compilation is correct, but it can not be implemented. I have seen on the internet that, in theory, there must be some rest of the application inside the device, so I have directly cleaned everything to see if it worked. However, it is not working.

The following image shows the references:

On the other hand, this is the structure of the complete project:

The compilation settings are as follows:

  • Minimum Android Version: Android 5.1 (API Level 22 - Lollipop)
  • Target Android Version: Android 5.1 (API Level 22 - Lollipop)
  • Compile with the Android version: Android 5.1 (API Level 22 - Lollipop)

(If something else is needed, ask for it in comments and add it)

    
asked by Slifer Dragon 11.12.2017 в 12:28
source

1 answer

-1

This error occurs when you try to install an app that is not compatible with the architecture of your emulator.

  • The fastest solution is to download the compatible APK with the emulator If you have created the emulator with Intel architecture, Download the APK for this architecture (there is not always available).
  • The other solution, is the opposite, to create an emulator with architecture ARM and another with Intel. If you have enough space on your hard drive, it is what I recommend. So you will have an Intel emulator and another ARM. Y you can install any app in one emulator or another depending on your architecture. If it's built on Intel, you'll use the Intel emulator and if it is built in ARM, the ARMv7 emulator.

Touching the code ... script build.gradle :

splits {
        abi {
            enable true
            reset()
            include 'x86', 'armeabi-v7a'
            universalApk true
        }
    }

Then run on the console:

adb install (TuApp)-x86-debug.apk

link

You can also adjust it by editing the file gradle.properties that is in your project folder and add x86 to PROP_APP_ABI, separating it with "colon (: )"

PROP_APP_ABI=armeabi:x86
    
answered by 11.12.2017 в 15:16