Skip to content

Commit

Permalink
Upgrade Flipper to 0.37.0 (#28545)
Browse files Browse the repository at this point in the history
Summary:
Bump flipper to 0.37 for both iOS and Android

## Changelog

[Android] [Changed] - Upgrade Flipper to 0.37.0
[iOS] [Changed] - Upgrade Flipper to 0.37.0
Pull Request resolved: #28545

Test Plan: RNTester build pass

Reviewed By: rickhanlonii

Differential Revision: D20930069

Pulled By: hramos

fbshipit-source-id: a7cb719da3e51e6a42d27d5e64bc664398d0d3c5
  • Loading branch information
sunnylqm authored and facebook-github-bot committed Apr 22, 2020
1 parent 19658a1 commit 17f025b
Show file tree
Hide file tree
Showing 5 changed files with 90 additions and 51 deletions.
88 changes: 44 additions & 44 deletions RNTester/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11,50 +11,50 @@ PODS:
- React-Core (= 1000.0.0)
- React-jsi (= 1000.0.0)
- ReactCommon/turbomodule/core (= 1000.0.0)
- Flipper (0.33.1):
- Flipper-Folly (~> 2.1)
- Flipper-RSocket (~> 1.0)
- Flipper (0.37.0):
- Flipper-Folly (~> 2.2)
- Flipper-RSocket (~> 1.1)
- Flipper-DoubleConversion (1.1.7)
- Flipper-Folly (2.1.1):
- Flipper-Folly (2.2.0):
- boost-for-react-native
- CocoaLibEvent (~> 1.0)
- Flipper-DoubleConversion
- Flipper-Glog
- OpenSSL-Universal (= 1.0.2.19)
- Flipper-Glog (0.3.6)
- Flipper-PeerTalk (0.0.4)
- Flipper-RSocket (1.0.0):
- Flipper-Folly (~> 2.0)
- FlipperKit (0.33.1):
- FlipperKit/Core (= 0.33.1)
- FlipperKit/Core (0.33.1):
- Flipper (~> 0.33.1)
- Flipper-RSocket (1.1.0):
- Flipper-Folly (~> 2.2)
- FlipperKit (0.37.0):
- FlipperKit/Core (= 0.37.0)
- FlipperKit/Core (0.37.0):
- Flipper (~> 0.37.0)
- FlipperKit/CppBridge
- FlipperKit/FBCxxFollyDynamicConvert
- FlipperKit/FBDefines
- FlipperKit/FKPortForwarding
- FlipperKit/CppBridge (0.33.1):
- Flipper (~> 0.33.1)
- FlipperKit/FBCxxFollyDynamicConvert (0.33.1):
- Flipper-Folly (~> 2.1)
- FlipperKit/FBDefines (0.33.1)
- FlipperKit/FKPortForwarding (0.33.1):
- FlipperKit/CppBridge (0.37.0):
- Flipper (~> 0.37.0)
- FlipperKit/FBCxxFollyDynamicConvert (0.37.0):
- Flipper-Folly (~> 2.2)
- FlipperKit/FBDefines (0.37.0)
- FlipperKit/FKPortForwarding (0.37.0):
- CocoaAsyncSocket (~> 7.6)
- Flipper-PeerTalk (~> 0.0.4)
- FlipperKit/FlipperKitHighlightOverlay (0.33.1)
- FlipperKit/FlipperKitLayoutPlugin (0.33.1):
- FlipperKit/FlipperKitHighlightOverlay (0.37.0)
- FlipperKit/FlipperKitLayoutPlugin (0.37.0):
- FlipperKit/Core
- FlipperKit/FlipperKitHighlightOverlay
- FlipperKit/FlipperKitLayoutTextSearchable
- YogaKit (~> 1.18)
- FlipperKit/FlipperKitLayoutTextSearchable (0.33.1)
- FlipperKit/FlipperKitNetworkPlugin (0.33.1):
- FlipperKit/FlipperKitLayoutTextSearchable (0.37.0)
- FlipperKit/FlipperKitNetworkPlugin (0.37.0):
- FlipperKit/Core
- FlipperKit/FlipperKitReactPlugin (0.33.1):
- FlipperKit/FlipperKitReactPlugin (0.37.0):
- FlipperKit/Core
- FlipperKit/FlipperKitUserDefaultsPlugin (0.33.1):
- FlipperKit/FlipperKitUserDefaultsPlugin (0.37.0):
- FlipperKit/Core
- FlipperKit/SKIOSNetworkPlugin (0.33.1):
- FlipperKit/SKIOSNetworkPlugin (0.37.0):
- FlipperKit/Core
- FlipperKit/FlipperKitNetworkPlugin
- Folly (2020.01.13.00):
Expand Down Expand Up @@ -343,25 +343,25 @@ DEPENDENCIES:
- DoubleConversion (from `../third-party-podspecs/DoubleConversion.podspec`)
- FBLazyVector (from `../Libraries/FBLazyVector`)
- FBReactNativeSpec (from `../Libraries/FBReactNativeSpec`)
- Flipper (~> 0.33.1)
- Flipper (~> 0.37.0)
- Flipper-DoubleConversion (= 1.1.7)
- Flipper-Folly (~> 2.1)
- Flipper-Folly (~> 2.2)
- Flipper-Glog (= 0.3.6)
- Flipper-PeerTalk (~> 0.0.4)
- Flipper-RSocket (~> 1.0)
- FlipperKit (~> 0.33.1)
- FlipperKit/Core (~> 0.33.1)
- FlipperKit/CppBridge (~> 0.33.1)
- FlipperKit/FBCxxFollyDynamicConvert (~> 0.33.1)
- FlipperKit/FBDefines (~> 0.33.1)
- FlipperKit/FKPortForwarding (~> 0.33.1)
- FlipperKit/FlipperKitHighlightOverlay (~> 0.33.1)
- FlipperKit/FlipperKitLayoutPlugin (~> 0.33.1)
- FlipperKit/FlipperKitLayoutTextSearchable (~> 0.33.1)
- FlipperKit/FlipperKitNetworkPlugin (~> 0.33.1)
- FlipperKit/FlipperKitReactPlugin (~> 0.33.1)
- FlipperKit/FlipperKitUserDefaultsPlugin (~> 0.33.1)
- FlipperKit/SKIOSNetworkPlugin (~> 0.33.1)
- Flipper-RSocket (~> 1.1)
- FlipperKit (~> 0.37.0)
- FlipperKit/Core (~> 0.37.0)
- FlipperKit/CppBridge (~> 0.37.0)
- FlipperKit/FBCxxFollyDynamicConvert (~> 0.37.0)
- FlipperKit/FBDefines (~> 0.37.0)
- FlipperKit/FKPortForwarding (~> 0.37.0)
- FlipperKit/FlipperKitHighlightOverlay (~> 0.37.0)
- FlipperKit/FlipperKitLayoutPlugin (~> 0.37.0)
- FlipperKit/FlipperKitLayoutTextSearchable (~> 0.37.0)
- FlipperKit/FlipperKitNetworkPlugin (~> 0.37.0)
- FlipperKit/FlipperKitReactPlugin (~> 0.37.0)
- FlipperKit/FlipperKitUserDefaultsPlugin (~> 0.37.0)
- FlipperKit/SKIOSNetworkPlugin (~> 0.37.0)
- Folly (from `../third-party-podspecs/Folly.podspec`)
- glog (from `../third-party-podspecs/glog.podspec`)
- RCTRequired (from `../Libraries/RCTRequired`)
Expand Down Expand Up @@ -474,13 +474,13 @@ SPEC CHECKSUMS:
DoubleConversion: cde416483dac037923206447da6e1454df403714
FBLazyVector: 8ea0285646adaf7fa725c20ed737c49ee5ea680a
FBReactNativeSpec: e8f07c749b9cf184c819f5a8ca44b91ab61fca12
Flipper: 6c1f484f9a88d30ab3e272800d53688439e50f69
Flipper: 1670db365568191bd123a0c905b834e77ba9e3d3
Flipper-DoubleConversion: 38631e41ef4f9b12861c67d17cb5518d06badc41
Flipper-Folly: 2de3d03e0acc7064d5e4ed9f730e2f217486f162
Flipper-Folly: c12092ea368353b58e992843a990a3225d4533c3
Flipper-Glog: 1dfd6abf1e922806c52ceb8701a3599a79a200a6
Flipper-PeerTalk: 116d8f857dc6ef55c7a5a75ea3ceaafe878aadc9
Flipper-RSocket: 1260a31c05c238eabfa9bb8a64e3983049048371
FlipperKit: 6dc9b8f4ef60d9e5ded7f0264db299c91f18832e
Flipper-RSocket: 64e7431a55835eb953b0bf984ef3b90ae9fdddd7
FlipperKit: afd4259ef9eadeeb2d30250b37d95cb3b6b97a69
Folly: b73c3869541e86821df3c387eb0af5f65addfab4
glog: 40a13f7840415b9a77023fbcae0f1e6f43192af3
OpenSSL-Universal: 8b48cc0d10c1b2923617dfe5c178aa9ed2689355
Expand Down Expand Up @@ -512,4 +512,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 5f0be4be03d6934478b9dd621bfbab4383b8c85d

COCOAPODS: 1.8.4
COCOAPODS: 1.9.1
14 changes: 14 additions & 0 deletions RNTester/RNTesterPods.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -784,13 +784,18 @@
"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)",
);
"LIBRARY_SEARCH_PATHS[arch=*]" = "$(inherited)";
OTHER_CFLAGS = (
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
"-l\"stdc++\"",
"-framework",
"\"JavaScriptCore\"",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.react.uiapp;
PRODUCT_NAME = RNTester;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -845,13 +850,18 @@
"$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)",
"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)",
);
OTHER_CFLAGS = (
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
"-l\"stdc++\"",
"-framework",
"\"JavaScriptCore\"",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.react.uiapp;
PRODUCT_NAME = RNTester;
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -1044,6 +1054,7 @@
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.RNTesterUnitTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -1079,6 +1090,7 @@
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.RNTesterUnitTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -1115,6 +1127,7 @@
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.RNTesterIntegrationTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down Expand Up @@ -1148,6 +1161,7 @@
"$(inherited)",
"-DFB_SONARKIT_ENABLED=1",
);
OTHER_SWIFT_FLAGS = "$(inherited) -Xcc -DFB_SONARKIT_ENABLED";
PRODUCT_BUNDLE_IDENTIFIER = com.facebook.RNTesterIntegrationTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TARGETED_DEVICE_FAMILY = "1,2";
Expand Down
2 changes: 1 addition & 1 deletion RNTester/android/app/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ android.useAndroidX=true
android.enableJetifier=true

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.33.1
FLIPPER_VERSION=0.37.0
35 changes: 30 additions & 5 deletions scripts/react_native_pods.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,19 +58,17 @@ def use_react_native! (options={})
end

def use_flipper!(versions = {})
versions['Flipper'] ||= '~> 0.33.1'
versions['Flipper'] ||= '~> 0.37.0'
versions['DoubleConversion'] ||= '1.1.7'
versions['Flipper-Folly'] ||= '~> 2.1'
versions['Flipper-Folly'] ||= '~> 2.2'
versions['Flipper-Glog'] ||= '0.3.6'
versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
versions['Flipper-RSocket'] ||= '~> 1.0'

versions['Flipper-RSocket'] ||= '~> 1.1'
pod 'FlipperKit', versions['Flipper'], :configuration => 'Debug'
pod 'FlipperKit/FlipperKitLayoutPlugin', versions['Flipper'], :configuration => 'Debug'
pod 'FlipperKit/SKIOSNetworkPlugin', versions['Flipper'], :configuration => 'Debug'
pod 'FlipperKit/FlipperKitUserDefaultsPlugin', versions['Flipper'], :configuration => 'Debug'
pod 'FlipperKit/FlipperKitReactPlugin', versions['Flipper'], :configuration => 'Debug'

# List all transitive dependencies for FlipperKit pods
# to avoid them being linked in Release builds
pod 'Flipper', versions['Flipper'], :configuration => 'Debug'
Expand Down Expand Up @@ -98,4 +96,31 @@ def flipper_post_install(installer)
end
end
end
file_name = Dir.glob("*.xcodeproj")[0]
app_project = Xcodeproj::Project.open(file_name)
app_project.native_targets.each do |target|
target.build_configurations.each do |config|
cflags = config.build_settings['OTHER_CFLAGS'] || '$(inherited) '
unless cflags.include? '-DFB_SONARKIT_ENABLED=1'
puts 'Adding -DFB_SONARKIT_ENABLED=1 in OTHER_CFLAGS...'
cflags << '-DFB_SONARKIT_ENABLED=1'
end
config.build_settings['OTHER_CFLAGS'] = cflags
if (config.build_settings['OTHER_SWIFT_FLAGS'])
unless config.build_settings['OTHER_SWIFT_FLAGS'].include? '-DFB_SONARKIT_ENABLED'
puts 'Adding -DFB_SONARKIT_ENABLED ...'
swift_flags = config.build_settings['OTHER_SWIFT_FLAGS']
if swift_flags.split.last != '-Xcc'
config.build_settings['OTHER_SWIFT_FLAGS'] << ' -Xcc'
end
config.build_settings['OTHER_SWIFT_FLAGS'] << ' -DFB_SONARKIT_ENABLED'
end
else
puts 'OTHER_SWIFT_FLAGS does not exist thus assigning it to `$(inherited) -Xcc -DFB_SONARKIT_ENABLED`'
config.build_settings['OTHER_SWIFT_FLAGS'] = '$(inherited) -Xcc -DFB_SONARKIT_ENABLED'
end
app_project.save
end
end
installer.pods_project.save
end
2 changes: 1 addition & 1 deletion template/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ android.useAndroidX=true
android.enableJetifier=true

# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.33.1
FLIPPER_VERSION=0.37.0

2 comments on commit 17f025b

@grabbou
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have an error running pod instatll with this commit in RNTester:

grabbou@Michas-MacBook-Pro RNTester % pod install
Analyzing dependencies
Fetching podspec for `DoubleConversion` from `../third-party-podspecs/DoubleConversion.podspec`
Fetching podspec for `Folly` from `../third-party-podspecs/Folly.podspec`
Fetching podspec for `glog` from `../third-party-podspecs/glog.podspec`
Downloading dependencies
Installing CocoaAsyncSocket (7.6.4)
Installing CocoaLibEvent (1.0.0)
Installing DoubleConversion (1.1.6)
Installing FBLazyVector (0.63.0-rc.0)
Installing FBReactNativeSpec (0.63.0-rc.0)
Installing Flipper (0.37.0)
Installing Flipper-DoubleConversion (1.1.7)
Installing Flipper-Folly (2.2.0)
Installing Flipper-Glog (0.3.6)
Installing Flipper-PeerTalk (0.0.4)
Installing Flipper-RSocket (1.1.0)
Installing FlipperKit (0.37.0)
Installing Folly (2020.01.13.00)
Installing OpenSSL-Universal (1.0.2.19)
Installing RCTRequired (0.63.0-rc.0)
Installing RCTTypeSafety (0.63.0-rc.0)
Installing React (0.63.0-rc.0)
Installing React-ART (0.63.0-rc.0)
Installing React-Core (0.63.0-rc.0)
Installing React-CoreModules (0.63.0-rc.0)
Installing React-RCTActionSheet (0.63.0-rc.0)
Installing React-RCTAnimation (0.63.0-rc.0)
Installing React-RCTBlob (0.63.0-rc.0)
Installing React-RCTImage (0.63.0-rc.0)
Installing React-RCTLinking (0.63.0-rc.0)
Installing React-RCTNetwork (0.63.0-rc.0)
Installing React-RCTPushNotification (0.63.0-rc.0)
Installing React-RCTSettings (0.63.0-rc.0)
Installing React-RCTTest (0.63.0-rc.0)
Installing React-RCTText (0.63.0-rc.0)
Installing React-RCTVibration (0.63.0-rc.0)
Installing React-callinvoker (0.63.0-rc.0)
Installing React-cxxreact (0.63.0-rc.0)
Installing React-jsi (0.63.0-rc.0)
Installing React-jsiexecutor (0.63.0-rc.0)
Installing React-jsinspector (0.63.0-rc.0)
Installing ReactCommon (0.63.0-rc.0)
Installing Yoga (1.14.0)
Installing YogaKit (1.18.1)
Installing boost-for-react-native (1.63.0)
Installing glog (0.3.5)
Generating Pods project
[!] An error occurred while processing the post-install hook of the Podfile.

[!] The plist file at path `/Users/grabbou/Repositories/react-native/RNTester/RNTester.xcodeproj/project.pbxproj` doesn't exist.


/usr/local/Cellar/cocoapods/1.9.1/libexec/gems/xcodeproj-1.15.0/lib/xcodeproj/plist.rb:17:in `read_from_path'
/usr/local/Cellar/cocoapods/1.9.1/libexec/gems/xcodeproj-1.15.0/lib/xcodeproj/project.rb:210:in `initialize_from_file'
/usr/local/Cellar/cocoapods/1.9.1/libexec/gems/xcodeproj-1.15.0/lib/xcodeproj/project.rb:112:in `open'
/Users/grabbou/Repositories/react-native/scripts/react_native_pods.rb:100:in `flipper_post_install'
/Users/grabbou/Repositories/react-native/RNTester/Podfile:62:in `block (2 levels) in from_ruby'
/usr/local/Cellar/cocoapods/1.9.1/libexec/gems/cocoapods-core-1.9.1/lib/cocoapods-core/podfile.rb:179:in `post_install!'
/usr/local/Cellar/cocoapods/1.9.1/libexec/gems/cocoapods-1.9.1/lib/cocoapods/installer.rb:857:in `run_podfile_post_install_hook'

@alloy
Copy link
Contributor

@alloy alloy commented on 17f025b May 1, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These types of settings should not be configured from a post_install hook, but rather from the pod’s podspec. I’ll take a look at this.

Please sign in to comment.