diff --git a/jni/src/gpgs_support/Android.mk b/jni/src/gpgs_support/Android.mk deleted file mode 100644 index 82c093c1..00000000 --- a/jni/src/gpgs_support/Android.mk +++ /dev/null @@ -1,17 +0,0 @@ -LOCAL_PATH := $(call my-dir) - -include $(CLEAR_VARS) - -LOCAL_MODULE := gpgs_support - -APP_PLATFORM := android-12 - -include $(XASH3D_CONFIG) - -LOCAL_CPPFLAGS += -std=c++11 - -LOCAL_SRC_FILES := gpgs_support.cpp -LOCAL_STATIC_LIBRARIES := libgpg-1 -LOCAL_LDLIBS := -llog - -include $(BUILD_SHARED_LIBRARY) diff --git a/jni/src/gpgs_support/gpgs_support.cpp b/jni/src/gpgs_support/gpgs_support.cpp deleted file mode 100644 index 5af58099..00000000 --- a/jni/src/gpgs_support/gpgs_support.cpp +++ /dev/null @@ -1,65 +0,0 @@ -/* -gpgs_support.cpp -- a Google Play Games support library -Copyright (C) 2016 a1batross -*/ - -#include -#include - -#if defined(GOOGLE_PLAY_BUILD) -#include -#include -using gpg::GameServices; -#else -typedef void *GameServices; -#endif - -GameServices *services = nullptr; - -extern "C" -{ -// After construction of GameServices, pass pointer to this function -// GameServices is recommended to be created in client.dll -void SetGameServicesPtr( GameServices *ptr ); - -// Share a pointer to external code, like server library or menu. -GameServices *GetGameServicesPtr( void ); -} - -void SetGameServicesPtr( GameServices *ptr ) -{ -#ifdef GOOGLE_PLAY_BUILD - static bool once; - - if( once ) - { - __android_log_print( ANDROID_LOG_ERROR, "GPGSSupport", "To prevent overwriting of GameServices pointer, setting pointer twice is prohibited" ); - return; - } - - services = ptr; - once = true; -#else - __android_log_print( ANDROID_LOG_WARN, "GPGSSupport", "Not a Google Play build of engine!" ); -#endif -} - -GameServices *GetGameServicesPtr( void ) -{ -#ifdef GOOGLE_PLAY_BUILD - return services; -#else - return nullptr; -#endif -} - -extern "C" __attribute__((visibility("default"))) jint JNI_OnLoad( JavaVM *vm, void *reserved ) -{ -#ifdef GOOGLE_PLAY_BUILD - gpg::AndroidInitialization::JNI_OnLoad( vm ); - - __android_log_print( ANDROID_LOG_VERBOSE, "GPGSSupport", "%s", __PRETTY_FUNCTION__ ); -#endif - - return JNI_VERSION_1_6; -}