How to solve "Failed to locate the Google Cloud Messaging" in ADF Mobile deployment

If you are trying to deploy to an Android device with the new Oracle ADF Mobile 11.1.2.4 release there is a good chance that you'll run into a situation where your deployment will fail with the message -

Failed to locate the Google Cloud Messaging for Android Library file named "gcm.jar"


Don't worry this is quite easy to resolve. All you need to do is download and install the "Google Cloud Messaging for Android Library" from the "Extras" section of your Android SDK Manager application.

Your android environment now requires that part because the new Oracle ADF Mobile support notification through the Google Cloud Messaging.

Once you download that addition you should be able to deploy without any problems.


Comments:

I'm very sorry but nowadays it does not work since Google cloud messaging for android library is reported as deprecated by Android SDK

Posted by guest on August 09, 2013 at 04:31 PM PDT #

The problem is that Google Cloud Messaging is deprecated.

Posted by LeonidVlad on September 05, 2013 at 12:49 PM PDT #

Even though it is deprecated you should still be able to install it and it will still work properly.

Posted by Shay on September 05, 2013 at 01:56 PM PDT #

Download the jar files from the following link

https://dl-ssl.google.com/android/repository/gcm_r03.zip

Add gcm.jar file to all the projects as well as application in the following location,

Project Properties -> Libraries and Classpath -> Add JAR/Directory

Posted by guest on September 11, 2013 at 06:33 AM PDT #

I downloaded the gcm.jar file from the above link and added to the project properties --> libraries and classpath & Application properties --> libraries and classpath. But still I'm getting same message "ailed to locate the Google Cloud Messaging for Android Library file named "gcm.jar"

Posted by guest on November 13, 2013 at 08:50 AM PST #

guest - you don't need to add the jar to the JDeveloper project, it needs to be part of the Android SDK on your machine.
I would also recommend that you update your environment to the latest ADF Mobile extension and check that the paths in the preferences for the Android platform are set up properly.

Posted by Shay on November 13, 2013 at 08:57 AM PST #

On Windows 7, run the SDK Manager as administrator else it will fail to install the deprecated Google Cloud Messaging for Android Library.

Posted by guest on November 19, 2013 at 12:58 PM PST #

I recently had this issue and also could not install the GCM library from the Android SDK manager (Android 4.4 API 19). As per a previous comment, I resolved as follows:

1) Downloaded gcm_r03.zip from link: https://dl-ssl.google.com/android/repository/gcm_r03.zip
2) Created a folder titled “google” in Android SDK ”extras” folder, i.e., “…./sdk/extras/google"
3) Extracted gcm_r03 files to new “google” folder
4) Renamed extracted gcm_R03 folder to gcm, i.e., “…/sdk/extras/google/gcm

This new folder will contain the following three folders: gcm-client, gcm-server, and samples. Everything worked after that.

Posted by Brian Duffield on December 04, 2013 at 11:54 AM PST #

Thank you Sir.

Posted by guest on December 12, 2013 at 05:48 AM PST #

Post a Comment:
  • HTML Syntax: NOT allowed
About

This blog is is dedicated to tips and tricks for developing, integrating, securing, and managing mobile applications using Oracle Mobile Platform. It is created and maintained by the Mobile Suite/Oracle ADF Mobile product development team.

Archive of past entries

Even More Mobile Development Blogs

Oracle A-Team Site - Mobile Related Entries

Code samples from the Community

Fusion Middleware Blogs

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
12
13
14
15
16
17
18
19
20
22
23
24
25
26
27
28
29
30
   
       
Today