Hello Third Party Lib is an Android C++ sample that depends on a prebuilt static library (Play Game C++ SDK).
- Android Studio 1.3+ with NDK bundle.
- Download Android Studio
- Launch Android Studio.
- Open the sample directory.
- Open File/Project Structure...
- Click Download or Select NDK location.
- Click Tools/Android/Sync Project with Gradle Files.
- Update the source with the details of your project:
- Update the package name in
app/build.gradle
andapp/src/main/AndroidManifest.xml
. - Set
APP_ID
inapp/res/values/ids.xml
to the ID your project in the Game services section of the Google Play console. NOTE: If you fail to set the app ID or package name correctly, the sample will crash or behave unexpectedly.
- Click Run/Run 'app'.
This project consists of 2 sub-projects. The first the "app" and contains the application code and resources. It is dependendent on the second sub-project "thirdparty/gpg-sdk" which downloads and unzips the Google Play Games SDK.
This demonstrates one way to organize and manage thirdparty libraries.
If you've found an error in these samples, please file an issue.
Patches are encouraged, and may be submitted by forking this project and submitting a pull request through GitHub. Please see CONTRIBUTING.md for more details.
Copyright 2015 Google, Inc.
Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.