Unsupported configuration: ... armeabi-v7a-emu.so in Mono for Android v4.0 - xamarin.android

I have just downloaded the latest Mono for Android (v4.0) and am trying to load a test app into a level 14 API emulator. In both Visual Studio 10 and Monodevelop, I am getting the same problem when packaging the app. Here's what I get in VS.
monodroid : error 1: System.InvalidOperationException: Unsupported configuration: Could not load resource 'libmono-android.shared.armeabi-v7a-emu.so'
I have installed the "ARM EABI v7a System Image" using the Android SDK manager. I can see the system.img file in C:\Users\\AppData\Local\Xamarin\MonoForAndroid\AndroidSDK\android-sdk-windows\system-images\android-14\armeabi-v7a.
I created an emulator using level 14 API, and this starts up and runs without problem. I modified the project properties to target Android 4.0 and the armeabi-v7a architecture. The app is simply the unmodified test app created automatically when you select the android application template. I am running Vista.
Can anyone shed some light on this?
Thanks, Stuart F.

The evaluation version does not allow you to build the armeabi-v7a version, because there was never a armeabi-v7a emulator until now, and the evaluation version only allows you to deploy to emulators.
Use the armeabi version, which should work fine on the armeabi-v7a emulator.

Related

Getting an error when running xamarin project?

I am new in xamarin, create a sample application using xamarin android native, when try to run get an error
C:\Program Files (x86)\Android\android-sdk\emulator\emulator.EXE -partition-size 512 -no-boot-anim -avd Android_Accelerated_x86_Oreo -prop monodroid.avdname=Android_Accelerated_x86_Oreo
PANIC: Cannot find AVD system path. Please define ANDROID_SDK_ROOT
Emulator Android_Accelerated_x86_Oreo cannot be started.
Runtime checks completed
Build has been canceled.
In Visual Studio go to Tools -> Android -> Android SDK Manager
Then make sure Android 8.0 / 8.1 (whichever one you're targeting) is installed.
Next in Visual Studio go to Tools -> Options -> Xamarin -> Android Settings
Then make sure you have the appropriate paths specified in Java Development Kid Location and Android SDK Location (should see little green checkmarks).
Also check the box to "Auto Install Android SDKs".
If something is screwed up still, would recommend going to Visual Studio Updater, then confirming Xamarin workload is installed or try to repair.

Can't get Visual Studio to target the correct Android version

I have a problem getting Xamarin.Android to target the newest version of Android.
The problem arised when I tried installing the Xamarin.GooglePlayServices.Maps NuGet package, that required me to run at least Android 8.
From my Android SDK manager, I can see that Android 8 and 8.1 is the only SDK platforms installed:
However, when I start a new project in Visual Studio 2017, and go into the project properties, and extend the Compile using Android version dropdown, it's populated like this:
So here I can choose only 7.1 (that is marked as latest platform), and 8.0 and 8.1 is marked with (Requires installation). Android 7.1 SDK that VS uses is not even installed on my machine.
So the questions is: What do I have to do to select Android 8.1 as the Target Framework inside Visual Studio?
What do I have to do to select Android 8.1 as the Target Framework inside Visual Studio?
In your VS, Tools->Android->Android SDK Manager, you will see Android SDK for VS, it default path is C:\Program Files (x86)\Android\android-sdk.
In your AS, Android SDK's path is C:\Users\user name\AppData\Local\Android\Sdk
Now, you can change the VS's Android SDK's path to C:\Users\user name\AppData\Local\Android\Sdk, but we don't suggest you do that, it may cause VS compilation errors at some point, and by then you cannot find the cause of the problem.
So, you can download the Android 8 from VS again.

APK fails to be installed on any device

I'm new in the Xamarin Development world so I installed Visual Studio 2017 with all the needed cross compiler features.
After downloading and updating the SDKs for Android API 23, 24, 25 and 26 and some corresponding emulator images I got the emulators starting up.
I created a base Xamarin Android App within VS, compiled and deployed it to the simulator.
By deploying/installing the generated APK to the simulator I get the following error:
Failure [INSTALL_FAILED_INVALID_APK: Package couldn't be installed in /data/app/BlankAndroid.BlankAndroid-1: Package /data/app/BlankAndroid.BlankAndroid-1/base.apk code is missing]
It doesn't matter which SDK I choose as “Target Framework” or which Simulator I choose (Android 6, Android 7 or 7.1). The result is the same: The apk is not installed, but the “Mono Shared Runtime” are present and will be updated.
I figured out that the created apk file does not contain a file “classes.dex” or any oder dex files just some ressources. A file “classes.zip” in the directory “obj\Debug\android\bin\classes” with the generated java classes out of my C# is present. These files should be compiled with the DEX-Compiler to the classes.dex file, when I understood correctly.
Even other sample projects from the Internet have exactly the same result.
What do I do wrong?
The problem got solved by fresh installing the Android SDK and all related components. It seemed to have a SDK missmatch between an old Google Android SDK and the new installed Xamarin Android SDK.
I faced the same problem and tried many solutions from the search in web but this one to an extent solved that deploy failure issue.
In the emulator, open settings -> Apps -> Uninstall your app if it is listed
Deploy the app from visual studio again.
This solved the problem that said base.apk is missing.
Try setting your project back to the current recommended defaults. Remove all of the following properties from the .csproj file:
AndroidEnableMultiDex
AndroidDexGenerator
AndroidLinkTool
AndroidDexTool
This will let Xamarin.Android pick the current latest default values, this apply for Visual Studio for Mac and VS 2017-2019

Visual Studio 2015 hangs on deploying cordova application

I'm trying to build a blank cordova application into my iPad Air 2 with Visual Studio 2015 Enterprise edition as i've already done it with success with the release candidate version.
I've got node.js v 4.2.2 on both machines since version 5.2.0 was hanging the build indefinitely, i've also got latest version of iTunes (12.3.1) as well as iOS 9.2 on the mobile device.
I've got the remote MAC set up and everything works fine for the building part, infact i've checked and the .ipa file is there at the end of the build into the folder ...\Documents\Visual Studio 2015\Projects\BlankCordovaApp1\BlankCordovaApp1\bin\iOS\Debug and if i launch that it will correctly install into iTunes and the iPad itself.
The problem is that the build action with Configuration "iOS" and "Local Device" with the iPad connected to the windows 7 PC will hang indefinitely after copying back said .ipa file after writing this line into the Build Output:
2>------ Deploy started: Project: BlankCordovaApp1, Configuration: Debug iOS ------
No matter how much time i wait it wont start the debug session even if i authorized the pc onto the iPad and have my web Inspector turned on onto the safari options. At this point i have to interrupt the build to be able to work again.
What really gets me is that if i connect the iPad to the MAC machine and build with "Remote Device" option the build works fine and i can debug remotely from my windows pc, unfortunately working like that isn't an option since the Apple machine isn't in the same room of my developing machine.
Any insight about this issue would be really appreciate, thanks in advance.
You are using a recent version of node and thus will also need to use a recent version of Cordova.
Specifically, you need to use Cordova 5.3.3 to be able to use Node.js 4.x.x+. The hang you are experiencing is exactly why. It's an incompatibility with a down stream node module and Node 4.x.x. You can downgrade to Node 0.12.x or upgrade your Cordova project to 5.3.3.
http://cordova.apache.org/news/2015/09/22/tools-release.html
Note that Node 5.x.x is only supported in Cordova 5.4.1.
This should be addressed in the latest VS Tools for Cordova Update 6. Deploying to local device is now available.
Take a look at http://microsoft.github.io/vstacoblog/2016/02/04/announcing-update-6.html.

MonoDroid: HelloWorld not ending up in Emulator

I have installed MonoDroid and the hello world sample. I compile the app and choose the emulator from the selector. The app is compiled and pushed to the device from Visual Studio according to MonoDroid.
But it never appears in the emulator.
So, I tried to push the app up using ADB install
I get this error from adb:
Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES]
This is caused by using the new Java 7 SDK.
Currently the only fix available is to uninstall Java 7 and install Java 6.

Resources