How to import gms to our project - using Android.mk
来源:互联网 发布:股票历史分时数据获取 编辑:程序博客网 时间:2024/06/14 01:40
1. Download google play services using sdk Manager.
2. Copy the library project to the location where maintain your android app projects.
3. In Eclipse, import it. File->Import, select Android > Exsting Android Code into Workspace, add browser to the copy of the library project to import it.
4. Right click this project, select Export > JAR file, select gen and src directory, diselect other directories, like the attachments, click finish.
5, Copy this generated jar file(for example, google-play-services_lib.jar) and libs/google-play-services.jar to camera project's jarlib directory.
6. Edit Android.mk of camera project, add these lines:
LOCAL_STATIC_JAVA_LIBRARIES += googleplayservices
LOCAL_STATIC_JAVA_LIBRARIES += googleplayservices_lib
LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES += googleplayservices_lib:jarlib/google-play-services_lib.jar
LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES += googleplayservices:jarlib/google-play-services.jar
7. Copy res/values/version.xm under gms project to camera project res/values/ directories.
8. Edit AndroidManifest.xml of camera project, add the following tag as a child of the <application> element:
<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
9. If you encounter proguard issue, copy these directories under android-sdk/tools/proguard/ to external/proguard, replace old one(make sure version under android sdk is newer than those unser android source):
bin/ lib/
2. Copy the library project to the location where maintain your android app projects.
3. In Eclipse, import it. File->Import, select Android > Exsting Android Code into Workspace, add browser to the copy of the library project to import it.
4. Right click this project, select Export > JAR file, select gen and src directory, diselect other directories, like the attachments, click finish.
5, Copy this generated jar file(for example, google-play-services_lib.jar) and libs/google-play-services.jar to camera project's jarlib directory.
6. Edit Android.mk of camera project, add these lines:
LOCAL_STATIC_JAVA_LIBRARIES += googleplayservices
LOCAL_STATIC_JAVA_LIBRARIES += googleplayservices_lib
LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES += googleplayservices_lib:jarlib/google-play-services_lib.jar
LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES += googleplayservices:jarlib/google-play-services.jar
7. Copy res/values/version.xm under gms project to camera project res/values/ directories.
8. Edit AndroidManifest.xml of camera project, add the following tag as a child of the <application> element:
<meta-data android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version" />
9. If you encounter proguard issue, copy these directories under android-sdk/tools/proguard/ to external/proguard, replace old one(make sure version under android sdk is newer than those unser android source):
bin/ lib/
0 0
- How to import gms to our project - using Android.mk
- How to import Ocx into MFC project
- How to import Gradle project into eclipse
- How to import Gradle project into eclipse .
- 导入android项目的问题:How to import existing Android project into Eclipse
- How to import a static library into your test project?
- How to import Patio Library in my Project
- How to log application API calls using import module addresses
- How to setup a basic Struts project using Eclipse IDE
- How to setup a basic Struts project using Eclipse IDE
- How to setup a basic Struts project using Eclipse IDE
- How to add project into Android BSP
- Using Struts to Develop Our Web Application
- How to Using exploits.
- How to using TOR
- HOW TO: Using CVS
- How to Using Theano
- import external JRE to project
- Oracle EBS Alert预警系统管理(1)-基础设置
- WebRTC介绍
- 经济适用的移动设备端图表开发
- PADS下可以借助画铜皮/DXF文件技术来做各种奇形怪状的封装
- EM算法
- How to import gms to our project - using Android.mk
- 《APP开发》APP规范实例
- 关于OpenCV不能读取视频和写入视频的问题
- An amazing guide to Neural Networks
- VBA_把Excel某一区域的内容读入到数组中/把数组的内容写入到Excel中
- Servlet中PrintWriter和OutputStream两个流不能同时使用
- ViewController生命周期
- Alcatraz的安装和使用,以及Xcode6.2不显示Package manage的问题
- Android 中的Touch事件分发机制