Files
react-native/ReactAndroid/src/main/jni/react/jni/Android.mk
T
David Aurelio 82b8a9221a Add hybrid class to hold native delta client
Summary:
Adds hybrid JNI wrapper class that can hold a native delta client.

This class allows Java code in the `devsupport` package to hold onto a native delta client across reloads.
It also takes care of passing `okhttp` response objects to native code, where we build a `std::string` to hold JSON messages coming from Metro, and parse them with `folly::parseJson`.

In a follow-up, we will switch to a streaming-friendly binary format that will make allocating memory for the whole message unnecessary.

Reviewed By: fromcelticpark

Differential Revision: D7845138

fbshipit-source-id: 7a29b30645331addf843097dd0d05c03b3143991
2018-05-03 08:47:47 -07:00

52 lines
1.3 KiB
Makefile

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := reactnativejni
LOCAL_SRC_FILES := \
AndroidJSCFactory.cpp \
CatalystInstanceImpl.cpp \
CxxModuleWrapper.cpp \
JavaModuleWrapper.cpp \
JMessageQueueThread.cpp \
JSCPerfLogging.cpp \
JSLoader.cpp \
JSLogging.cpp \
JniJSModulesUnbundle.cpp \
MethodInvoker.cpp \
ModuleRegistryBuilder.cpp \
NativeArray.cpp \
NativeCommon.cpp \
NativeDeltaClient.cpp \
NativeMap.cpp \
OnLoad.cpp \
ProxyExecutor.cpp \
ReactMarker.cpp \
ReadableNativeArray.cpp \
ReadableNativeMap.cpp \
WritableNativeArray.cpp \
WritableNativeMap.cpp \
LOCAL_C_INCLUDES := $(LOCAL_PATH)
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/../..
LOCAL_CFLAGS += -Wall -Werror -fvisibility=hidden -fexceptions -frtti
CXX11_FLAGS := -std=c++11
LOCAL_CFLAGS += $(CXX11_FLAGS)
LOCAL_EXPORT_CPPFLAGS := $(CXX11_FLAGS)
LOCAL_LDLIBS += -landroid
LOCAL_SHARED_LIBRARIES := libfolly_json libfbjni libjsc libglog_init libyoga libprivatedata
LOCAL_STATIC_LIBRARIES := libreactnative
include $(BUILD_SHARED_LIBRARY)
$(call import-module,cxxreact)
$(call import-module,privatedata)
$(call import-module,fb)
$(call import-module,fbgloginit)
$(call import-module,folly)
$(call import-module,jsc)
$(call import-module,yogajni)