From e4eb84fa702551dc8408f5d94c45d0da8cab708b Mon Sep 17 00:00:00 2001 From: Michael Lee Date: Fri, 18 Mar 2016 10:33:19 -0700 Subject: [PATCH] Upgrade folly dependency Summary: Folly deprecated the brace initialization for dynamic::array, so point to a more recent tarball and fix it. Reviewed By: bestander Differential Revision: D3066402 fb-gh-sync-id: aaf70423886cb0cbc14aba7878a1d4e32bce82b1 shipit-source-id: aaf70423886cb0cbc14aba7878a1d4e32bce82b1 --- ReactAndroid/build.gradle | 8 ++++---- ReactAndroid/src/main/jni/react/jni/BUCK | 1 - ReactAndroid/src/main/jni/react/jni/OnLoad.cpp | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ReactAndroid/build.gradle b/ReactAndroid/build.gradle index 6e421b207b3137..8663f0a289671f 100644 --- a/ReactAndroid/build.gradle +++ b/ReactAndroid/build.gradle @@ -55,17 +55,17 @@ task prepareDoubleConversion(dependsOn: downloadDoubleConversion, type: Copy) { } task downloadFolly(dependsOn: createNativeDepsDirectories, type: Download) { - src 'https://github.com/facebook/folly/archive/v0.50.0.tar.gz' + src 'https://github.com/facebook/folly/archive/deprecate-dynamic-initializer.tar.gz' onlyIfNewer true overwrite false - dest new File(downloadsDir, 'folly-0.50.0.tar.gz'); + dest new File(downloadsDir, 'folly-deprecate-dynamic-initializer.tar.gz'); } task prepareFolly(dependsOn: downloadFolly, type: Copy) { from tarTree(downloadFolly.dest) from 'src/main/jni/third-party/folly/Android.mk' - include 'folly-0.50.0/folly/**/*', 'Android.mk' - eachFile {fname -> fname.path = (fname.path - "folly-0.50.0/")} + include 'folly-deprecate-dynamic-initializer/folly/**/*', 'Android.mk' + eachFile {fname -> fname.path = (fname.path - "folly-deprecate-dynamic-initializer/")} includeEmptyDirs = false into "$thirdPartyNdkDir/folly" } diff --git a/ReactAndroid/src/main/jni/react/jni/BUCK b/ReactAndroid/src/main/jni/react/jni/BUCK index be23d64cfe0913..cdd579b47670f5 100644 --- a/ReactAndroid/src/main/jni/react/jni/BUCK +++ b/ReactAndroid/src/main/jni/react/jni/BUCK @@ -70,7 +70,6 @@ jni_library( compiler_flags = [ '-Wall', '-Werror', - '-Wno-deprecated-declarations', '-fexceptions', '-std=c++11', '-fvisibility=hidden', diff --git a/ReactAndroid/src/main/jni/react/jni/OnLoad.cpp b/ReactAndroid/src/main/jni/react/jni/OnLoad.cpp index 9e46c57c6253a1..5bdc2c1ffe6e77 100644 --- a/ReactAndroid/src/main/jni/react/jni/OnLoad.cpp +++ b/ReactAndroid/src/main/jni/react/jni/OnLoad.cpp @@ -235,7 +235,7 @@ struct WritableNativeArray static constexpr const char* kJavaDescriptor = "Lcom/facebook/react/bridge/WritableNativeArray;"; WritableNativeArray() - : HybridBase(folly::dynamic({})) {} + : HybridBase(folly::dynamic::array()) {} static local_ref initHybrid(alias_ref) { return makeCxxInstance();