Skip to content

Commit 5cd6367

Browse files
kelsetfacebook-github-bot
authored andcommitted
Bump boost for Android to 1.76 to align with iOS + fix (#33565)
Summary: The reason why I'm working on this is to reduce the delta between this and the react-native-macos fork, in particular with the android patch folder "Build": https://github.com/microsoft/react-native-macos/tree/main/android-patches/patches/Build (it's a long story) While checking the changes in there, I noticed that one of them was a bump of boost. Looking back into main (here), I then noticed that there have been two bumps to boot in the repo so far: * a combo update 5 years ago to 1.63: * 193afff * 5c24a91 * and an update for the iOS side to 1.76 by Kudo last year: #31840 So this quickly turned into this: the PR wants to re-align the version of boost used in both iOS and Android. I explored the option of bumping both to 1.78 (latest at the time of writing: https://www.boost.org/users/history/version_1_78_0.html) but then I noticed that there's a Flipper dependency, `Flipper-Boost-iOSX`, on the iOS pods side that has been released only once and it seems to imply that it's 1.76 only compatible https://github.com/priteshrnandgaonkar/Flipper-Boost-iOSX/releases/tag/1.76.0.1.11. So going to 1.78 at least for now seems like a no-go, and I've settled for just aligning everything to 1.76 and just like iOS, move away from `boost-for-react-native` in favour of the original one. While doing so, I also noticed that the `React/third-party.xcconfig` still had a reference to 1.68 instead of 1.76 which seems like a leftover from Kudo's PR... it's probably because it was not doing anything in the first place, so lmk if you want me to delete it. ## Changelog <!-- Help reviewers and the release process by writing your own changelog entry. For an example, see: https://github.com/facebook/react-native/wiki/Changelog --> [Android] [Changed] - Bump boost for Android to 1.76 to align with iOS Pull Request resolved: #33565 Test Plan: CI is green (aside an unrelated ios rntester job that is also broken on main) ✅ Locally both RNTester and new app work: <img width="432" alt="Screenshot 2022-04-05 at 16 42 31" src="https://user-images.githubusercontent.com/16104054/161815444-0de63919-b90d-4a48-963a-872f0cc4ce79.png"> <img width="346" alt="Screenshot 2022-04-05 at 18 06 01" src="https://user-images.githubusercontent.com/16104054/161815438-b7b1c997-9dcd-47bd-acbe-732155941bb0.png"> Reviewed By: sshic Differential Revision: D35433032 Pulled By: cortinico fbshipit-source-id: 0d93f61f8c26eda1dd04127a8b20e799ab6828cb
1 parent b2bc5aa commit 5cd6367

File tree

6 files changed

+8
-8
lines changed

6 files changed

+8
-8
lines changed

React/third-party.xcconfig

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@
88
// LICENSE file in the root directory of this source tree.
99
//
1010

11-
HEADER_SEARCH_PATHS = $(SRCROOT)/../third-party/boost_1_63_0 $(SRCROOT)/../third-party/folly-2021.06.28.00 $(SRCROOT)/../third-party/glog-0.3.5/src
11+
HEADER_SEARCH_PATHS = $(SRCROOT)/../third-party/boost_1_76_0 $(SRCROOT)/../third-party/folly-2021.06.28.00 $(SRCROOT)/../third-party/glog-0.3.5/src
1212
OTHER_CFLAGS = -DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1

ReactAndroid/Android-prebuilt.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ include $(CLEAR_VARS)
3434
LOCAL_MODULE := folly_runtime
3535
LOCAL_SRC_FILES := $(REACT_NDK_EXPORT_DIR)/$(TARGET_ARCH_ABI)/libfolly_runtime.so
3636
LOCAL_EXPORT_C_INCLUDES := \
37-
$(THIRD_PARTY_NDK_DIR)/boost/boost_1_63_0 \
37+
$(THIRD_PARTY_NDK_DIR)/boost/boost_1_76_0 \
3838
$(THIRD_PARTY_NDK_DIR)/double-conversion \
3939
$(THIRD_PARTY_NDK_DIR)/folly
4040
# Note: Sync with folly/Android.mk.

ReactAndroid/build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def thirdPartyNdkDir = new File("$buildDir/third-party-ndk")
3232
def reactNativeRootDir = projectDir.parent
3333

3434
// You need to have following folders in this directory:
35-
// - boost_1_63_0
35+
// - boost_1_76_0
3636
// - double-conversion-1.1.6
3737
// - folly-deprecate-dynamic-initializer
3838
// - glog-0.3.5
@@ -56,7 +56,7 @@ task createNativeDepsDirectories {
5656
}
5757

5858
task downloadBoost(dependsOn: createNativeDepsDirectories, type: Download) {
59-
src("https://github.com/react-native-community/boost-for-react-native/releases/download/v${BOOST_VERSION.replace("_", ".")}-0/boost_${BOOST_VERSION}.tar.gz")
59+
src("https://boostorg.jfrog.io/artifactory/main/release/${BOOST_VERSION.replace("_", ".")}/source/boost_${BOOST_VERSION}.tar.gz")
6060
onlyIfNewer(true)
6161
overwrite(false)
6262
dest(new File(downloadsDir, "boost_${BOOST_VERSION}.tar.gz"))

ReactAndroid/gradle.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ FRESCO_VERSION=2.5.0
1616
OKHTTP_VERSION=4.9.2
1717
SO_LOADER_VERSION=0.10.3
1818

19-
BOOST_VERSION=1_63_0
19+
BOOST_VERSION=1_76_0
2020
DOUBLE_CONVERSION_VERSION=1.1.6
2121
FOLLY_VERSION=2021.06.28.00
2222
FMT_VERSION=6.2.1

ReactAndroid/src/main/jni/third-party/boost/Android.mk

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ include $(CLEAR_VARS)
66
# They are required for Folly futures to compile successfully.
77
LOCAL_SRC_FILES := $(wildcard $(LOCAL_PATH)/asm/$(TARGET_ARCH_ABI)/*.S)
88

9-
LOCAL_C_INCLUDES := $(LOCAL_PATH)/boost_1_63_0
10-
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/boost_1_63_0
9+
LOCAL_C_INCLUDES := $(LOCAL_PATH)/boost_1_76_0
10+
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/boost_1_76_0
1111

1212
LOCAL_MODULE := boost
1313

ReactAndroid/src/main/jni/third-party/boost/CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,5 @@ add_library(boost STATIC ${boostasm_SRC})
1818

1919
set_target_properties(boost PROPERTIES LINKER_LANGUAGE CXX)
2020

21-
target_include_directories(boost PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/boost_1_63_0)
21+
target_include_directories(boost PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/boost_1_76_0)
2222

0 commit comments

Comments
 (0)