I am currently developing an Android application using Xamarin Forms (v2.3.3.180) and Visual Studio 2015 on a Windows 10 machine.
I have a problem deploying APKs from TFS built with Android 7.0 (SDK 24) to Google Play.
Previously my app was built with, and targeted Android 6.0 (SDK 23), but I recently updated it to compile and target version 7.0, while maintaining the minimum supported version of 4.4.2 (SDK 19).
This presents no problem while developing and building the app, but when deploying it to Google Play it will not do the update. I have also tested to deploy it manually with the same result. The message states that the app previously targeted SDK 23 and cannot be downgraded to SDK 0!!!
This image is not mine as I forgot to take a screenshot of the message, but the text is exactly the same except for the version numbers:
Error message when deploying the APK
Mine said “… This occurs in the change from version xxx (target SDK 23) to version xxx+1 (target SDK 0)
After reverting to SDK 23 in my manifest.xml everything builds and deploys fine.
I have been able to find other examples of this error message, but all of them are valid errors in which Google Play should give this message. Mine is not, as it seems to think I am using SDK 0.
Has anyone come across this before? Is this a problem with Android 7.0, Xamarin build support, my TFS build machine, Google Play APK checks or something else?
(The SDKs are installed on the build machine!)
Thanks!
Related
I have an iOS project targeting SDK version 14.5 on all configurations but when I build it via an Azure Devops pipeline it targets version 13.5. Upon releasing I receive the following message.
SDK Version Issue. This app was built with the iOS 13.2 SDK. All iOS
apps submitted to the App Store must be built with the iOS 14 SDK or
later, included in Xcode 12 or later.
This tells me it is not reading the value on the project configuration.
To resolve this I had to update our hosted build agent OS to use a version of MacOS running XCode 12. At the time of writing this it was MacOS 10.15.
For more info on what software the hosted build agent operating systems come with visit this link: https://learn.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#notes-on-choosing-hosted-macos
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
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.
The issue is that I cannot now successfully build my Dreamweaver + PhoneGap App in Xcode for release in the iTunes App Store.
Background - I have been building an app using Dreamweaver and the built-in PhoneGap. To start with everything was working, including the emulator which started via Dreamweaver and the Xcode build. I have an early version of the app running on my iPhone right now with no problem.
After installing Lion on release, I started to encounter problems in that the App would not start in the emulator straight from Dreamweaver, but produced a fail message. However it did make an App bundle which could then be opened from Xcode itself. That was fine, but unfortunately now the App will not build or run at all in the emulator or my 'phone, which seems to stem from me doing a Clean in Xcode which I haven't done for a while. Very frustrating as it has been 3 months work and I was just about to release it on iTunes.I would be really grateful for ideas - the full buildlog.log is here http://bit.ly/tbYzVU
You may notice in your build log the following error on Line 39, which appears many times in your log:
ERROR: The requested SDK ("4.3") is not installed.
The version of PhoneGap you're using in Dreamweaver is looking for the iOS 4.3 Simulator at:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk
However, when upgrading to Mac OS X 10.7 "Lion" and presumably installing Xcode 4.2 from the AppStore, you probably only have the iOS 5 SDK. From the Xcode release notes:
What's New in Version 4.2.1
Features and enhancements in previous Xcode updates:
Xcode 4.2 includes SDKs for Mac OS X 10.7 Lion and iOS 5.
To verify what SDKs (Software Developer Kits) you have on your computer, open the following directory in the Finder:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/
It's likely that all you need to do is adjust which SDK Dreamweaver is targeting when building or emulating your app.
In your situation, you'll want to change your Site/App's SDK from iOS 4 to iOS 5.
From the Dreamweaver Help section for Packaging Web Applications, refer to Creating an Application Package (Mac OS):
Select Site > Mobile Applications > Configure Application Framework
Confirm iOS Developer Tools Path is configured to /Developer
Select Site > Mobile Applications > Application Settings
Under Select Target OS Version, for "iPhone/iPod Touch/iPad, choose 5.0
Build your App using Site > Mobile Applications > Emulate and Build
I was not able to build sample test app with iOS Simulator. Also I see only iphone is enabled and ipad is not. I have multiple xcode (4.0, 4.0.1, 3.2.5 and 3.2.1) installed on machine.
When I create a new app and build, it actually build to ios 3.1.3 as default. Here is my log http://pastebin.com/y9uX1RSz It finds all sdk and it quits the simulator as soon as it open.
There is an option to change the android sdk folder, but there is no alternative to change the ios SDK version in preferences.
I even try to modify the build deployment sdk to 4.2 with no luck. Also I see there are some plist (stylesheet.plist and debugger.plist) missing. And no demos (kitchensink) available as part of mobilesdk.
I've downloaded Titanium studio 1.0.1 which downloads mobilesdk 1.7.1 on its initial run.
It is the same with mobilesdk 1.7.2 which I've downloaded separately and copied to /library/Application support/Titanium
Update:
The issue is, I was not able to run a sample prj with iphone simulator. Ironically it works if I try to build with Android. The same mobile sdk works if I try from Titanium developer 1.2.2, but I was not able to develop or run sample code with Titanium studio.