From ae497133423907ad708343af1cb83ffd7c2f9ada Mon Sep 17 00:00:00 2001 From: Hoa Dinh Date: Wed, 31 May 2017 20:51:10 -0700 Subject: [PATCH] Export more symbols on React Native Reviewed By: skotchvail Differential Revision: D5157649 fbshipit-source-id: 8d04dff3a8564d3a095591aa982c9b72ace9a8b7 --- ReactCommon/jschelpers/JSCHelpers.h | 6 +++++- ReactCommon/jschelpers/Value.h | 6 +++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ReactCommon/jschelpers/JSCHelpers.h b/ReactCommon/jschelpers/JSCHelpers.h index 850b95a69..02a78d910 100644 --- a/ReactCommon/jschelpers/JSCHelpers.h +++ b/ReactCommon/jschelpers/JSCHelpers.h @@ -9,6 +9,10 @@ #include #include +#ifndef RN_EXPORT +#define RN_EXPORT __attribute__((visibility("default"))) +#endif + namespace facebook { namespace react { @@ -47,7 +51,7 @@ JSObjectRef makeFunction( const char* name, JSFunction function); -void installGlobalFunction( +RN_EXPORT void installGlobalFunction( JSGlobalContextRef ctx, const char* name, JSFunction function); diff --git a/ReactCommon/jschelpers/Value.h b/ReactCommon/jschelpers/Value.h index 92dce0834..0cc58418e 100644 --- a/ReactCommon/jschelpers/Value.h +++ b/ReactCommon/jschelpers/Value.h @@ -307,15 +307,15 @@ public: return getType() == kJSTypeObject; } - Object asObject() const; + RN_EXPORT Object asObject() const; bool isString() const { return getType() == kJSTypeString; } - String toString() const; + RN_EXPORT String toString() const; - static Value makeError(JSContextRef ctx, const char *error); + RN_EXPORT static Value makeError(JSContextRef ctx, const char *error); static Value makeNumber(JSContextRef ctx, double value) { return Value(ctx, JSC_JSValueMakeNumber(ctx, value));