ARC Welder: "Device does not have package com.google.android.gsf" despite "usePlayServices": ["gcm"] - google-chrome-arc

In my apk running in ARC welder I get:
java.lang.UnsupportedOperationException: Device does not have package
com.google.android.gsf at
com.google.android.gcm.GCMRegistrar.checkDevice(GCMRegistrar.java:98)
I get this despite having the following in Additional Metadata:
{ "usePlayServices": ["gcm"], "crx_key": ... } .
What do I need to do to get this working?

Assuming you are not using the deprecated C2DM (which ARC doesn't support), a possible reason is that you are not using the right way to check GCM availability. If that's the case, please refer to the example in Implementing GCM Client on Android (search for checkPlayServices).

I had this problem, but it appears the solution had nothing to do with GCM. My app was using the RabbitMQ java library though.
The solution was to use Google APIs instead of Android SDK Platfor as the default SDK . This is selected by going to Project Settings -> Project -> Select New [under Project SDK] -> Chose Your Android SDK Home Directory -> Chose the Your Favourite Google API.
Note: the APIs, in case you downloaded them, are normally on the lower half of the Build Target Drop down list in the Create New Android SDK dialog box.

Related

How to implement Steamworks API into an existing macOS / Xcode project?

I intend to submit an existing macOS game to Steam. It was made with Xcode using Objective-C and Swift.
According to the Steamworks documentation I need to link libsteam_api.dylib in the Xcode project.
However this does not seem to be enough. Several specific build and target settings need to be made, of which I can find no documentation. Also several other conditions need to be met, such as init calls that should be made.
The non-C++ language support page unfortunately has no information about Objective-C / Swift / Xcode and searching the web does not return any useful information other than how to code sign Mac games for Steam.
Is there any tutorial / help / step by step guide on how to do make the game submittable to Steam?
You can use Objective-C++ for easy integrate SteamWorks API to your Xcode project.
SteamWorks SDK has example named "steamworksexample" that show how to use it.

Can't Set Target Android version to Automatic

I have been following this document to implement a hybrid webview and am running into an issue with the Target Android version. It states in the document:
On Android Oreo ensure that the Android manifest sets the Target
Android version to Automatic. Otherwise, running this code will result
in the error message "invokeCSharpAction is not defined".
I am using the Android 8.1 - API 27 simulator and I am getting that error. I tried to set the Target Android version to "Automatic" as it suggests in the Android Manifest portion of the project properties, but "Automatic" is not an option I can pick. The only option I get that isn't a specific version is "Use Compile using SDK Version" and that doesn't solve the problem. What am I missing?
Have you seen the following thread?
https://github.com/xamarin/xamarin-forms-samples/issues/343
It states that sample from the documentation does not work and needs to be changed according to the one posted in this thread. Please let me know if it helps or not.

how to ensure backward-compatibilty in a xamarin forms application?

How do i make sure my app can run on android devices below Lollipop( version 4.03 to 4.42). I watched a xamarin university video that says xamarin forms supports android version 4.03(ice-cream sandwich) and upwards. I also read about runtime checks and feel like this might be the answer to my problem, but how can i write runtime checks for android when basically all my ui and logic is contained in the PCL project?
The first thing to do is ensure you are using the Android AppCompat library. I think new projects use this by default now. If you have an older project that doesn't follow these instructions to update. This will allow your app including any Material Design look and feel to run on older versions of Android.
If you do things differently based on Android version, put the code for this in the Android project and use dependency service to call it.
Like this:
if (Android.OS.Build.VERSION.SdkInt >= Android.OS.BuildVersionCodes.Lollipop)
{
// level specific code here
}

NoClassDefFoundError: android.support.v4.app when sending push?

Im using PushBots to manage my push notifications for my app, I have been using this amazing platform for lots of apps and its the first time I have a problem like this.
Sometimes, when I launch the app, I get this error, but always when receiving a push (within or whitout the app opened).
07-12 01:20:00.844: E/AndroidRuntime(12140): FATAL EXCEPTION: IntentService[GCMIntentService-326*****5*9-1]
07-12 01:20:00.844: E/AndroidRuntime(12140): Process: com.karlol.mo***, PID: 12140
07-12 01:20:00.844: E/AndroidRuntime(12140): java.lang.NoClassDefFoundError: android.support.v4.app.NotificationManagerCompat
> //This is just the beginning of the log, there's more with some
> Pushbots handler info and stuff.... Let me know if I need to post it,
> its a lot.
Im pretty sure this is about the android support v4, this is my current build path:
*Sometimes when I uncheck the Private Libraries clean and re-check this option again the app works (but not lucky with notifications).
The support v4 jar is in the libs folder, the route is the correct (MyApp/libs)
Im about to release an update, my app is already working/running with pushbots servers (with registered devices and all) so I would like to solve this to release my update. Thanks.
As explained in these questions: NotificationManagerCompat Can't be resolved - Android Wear and Android studio unable to import WearableExtender NotificationManagerCompat and RemoteInput. It seems that you are not using the last version of the compatibility support library. You have two options to solve that:
Download the newest libraries manually, and add them to your project.
It seems that you are using eclipse, I recommend that you now use Android Studio so you can add the dependency and let gladle handle the libraries, like this
dependencies {
compile 'com.android.support:support-v4:20.0+'
}
check mark the following jars in build path or property ,it will work
1. android-support-v4.jar(appcombat/ibs)
2.android-support-v4-appcombat.jar(appcombat/ibs)

Xcode Base SDK: What is the easiest way to install multiple SDK versions side by side

Alright what I noticed is that when I am developing against iOS 4.3, and I set my deployment target as iOS 4.1, I DO NOT get any kind of warning from the IDE about calls which are not supported in the minimum deployment target.
For example, calling [CLLocationManager authorizationStatus] shows no warning, despite the fact that the documentation for authorizationStatus says it was implemented in iOS 4.2.
I expect this would be a problem when wouldn't it?
From what I understand the solution to this is to download multiple SDK versions, temporarily build against the SDK for your minimum version, but switch to the current SDK version in order to ship.
If there is a better way to do this please advise. How can I get more options in Xcode under the "Base SDK" setting?
I expect this would be a problem when wouldn't it?
Yes, you'll generally crash if you call a method that doesn't exist.
From what I understand the solution to this is to download multiple
SDK versions, temporarily build against the SDK for your minimum
version, but switch to the current SDK version in order to ship.
That's a pretty good approach; probably the best way to find this kind of error semi-automatically.
If there is a better way to do this please advise. How can I get more
options in Xcode under the "Base SDK" setting?
You don't install all the SDK's together in a single "Developer" folder. Install each one separately -- there's an option to choose an alternate location when you install the SDK. Then it's just a matter of finding the copy of Xcode in the right folder and launching.
You don't need to have multiple options under Base SDK -- the normal practice is to just use the latest, but set the Deployment Target to the minimum version of iOS that your app supports.

Resources