From 453643fe6dfa9e5761183633ab22d68dbc3f2044 Mon Sep 17 00:00:00 2001 From: Kudo Chien Date: Thu, 22 Jun 2023 14:11:10 +0800 Subject: [PATCH] [ios][core][tools] fix expo go versioning issues on ios (#23012) # Why fix expo-go ios versioning for sdk 49 close ENG-8955 # How - a lot of mess transform rules update mainly for react-native 0.72 and reanimated v3 - [core] rename `ExpoRuntime -> EXRuntime` in objc for versioning - [updates] force casting for the `UpdatesConfig` (i'll leave comment for this) - [react-native-lab] add correct dependencies to make versioned code build passed # Test Plan `et add-sdk -p ios -s 49.0.0` + ios versioned expo-go + sdk49 ncl --- ios/ExpoKit.podspec | 2 +- ios/Exponent/Supporting/Info.plist | 4 +- .../Api/Components/GoogleMaps/AIRGoogleMap.m | 8 +- .../Core/EXVersionedNetworkInterceptor.m | 1 - ios/Podfile.lock | 202 +++++++++--------- .../expo-modules-core/ios/ExpoModulesCore.h | 4 +- .../ios/JSI/EXJSIInstaller.h | 4 +- .../ios/JSI/EXJSIInstaller.mm | 6 +- packages/expo-modules-core/ios/Swift.h | 2 + .../ios/Swift/ExpoRuntime.swift | 2 +- .../ios/EXUpdates/UpdatesModule.swift | 2 + template-files/ios/ExpoKit.podspec | 2 +- tools/src/vendoring/legacy.ts | 15 ++ tools/src/versioning/ios/index.ts | 43 +++- .../ios/transforms/expoModulesTransforms.ts | 10 +- .../ios/transforms/podspecTransforms.ts | 14 +- .../ios/transforms/postTransforms.ts | 27 +++ .../transforms/vendoredModulesTransforms.ts | 75 +++++-- .../src/versioning/ios/versionExpoModules.ts | 2 +- tools/src/versioning/ios/versionHermes.ts | 9 +- yarn.lock | 17 ++ 21 files changed, 287 insertions(+), 164 deletions(-) diff --git a/ios/ExpoKit.podspec b/ios/ExpoKit.podspec index 8b4bbf0336a609..06df693229aecb 100644 --- a/ios/ExpoKit.podspec +++ b/ios/ExpoKit.podspec @@ -15,7 +15,7 @@ Pod::Spec.new do |s| s.default_subspec = "Core" s.source = { :git => "http://github.com/expo/expo.git" } s.xcconfig = { - 'CLANG_CXX_LANGUAGE_STANDARD' => 'gnu++14', + 'CLANG_CXX_LANGUAGE_STANDARD' => 'c++17', 'SYSTEM_HEADER_SEARCH_PATHS' => "\"$(PODS_ROOT)/boost\" \"$(PODS_ROOT)/RCT-Folly\" \"$(PODS_ROOT)/Headers/Private/React-Core\"", 'OTHER_CPLUSPLUSFLAGS' => [ "$(OTHER_CFLAGS)", diff --git a/ios/Exponent/Supporting/Info.plist b/ios/Exponent/Supporting/Info.plist index 2916bb05fe8dc7..cda5b5f15ed296 100644 --- a/ios/Exponent/Supporting/Info.plist +++ b/ios/Exponent/Supporting/Info.plist @@ -2,6 +2,8 @@ + CADisableMinimumFrameDurationOnPhone + CFBundleDevelopmentRegion en CFBundleDisplayName @@ -150,7 +152,5 @@ Automatic UIViewControllerBasedStatusBarAppearance - CADisableMinimumFrameDurationOnPhone - diff --git a/ios/Exponent/Versioned/Core/Api/Components/GoogleMaps/AIRGoogleMap.m b/ios/Exponent/Versioned/Core/Api/Components/GoogleMaps/AIRGoogleMap.m index 555f03c83b0c4b..8a4215c195e11c 100644 --- a/ios/Exponent/Versioned/Core/Api/Components/GoogleMaps/AIRGoogleMap.m +++ b/ios/Exponent/Versioned/Core/Api/Components/GoogleMaps/AIRGoogleMap.m @@ -25,10 +25,10 @@ #import #ifdef HAVE_GOOGLE_MAPS_UTILS -#import "GMUKMLParser.h" -#import "GMUPlacemark.h" -#import "GMUPoint.h" -#import "GMUGeometryRenderer.h" +#import +#import +#import +#import #define REQUIRES_GOOGLE_MAPS_UTILS(feature) do {} while (0) #else #define GMUKMLParser void diff --git a/ios/Exponent/Versioned/Core/EXVersionedNetworkInterceptor.m b/ios/Exponent/Versioned/Core/EXVersionedNetworkInterceptor.m index 5a709e6b33fe45..60d83f1ba33e1c 100644 --- a/ios/Exponent/Versioned/Core/EXVersionedNetworkInterceptor.m +++ b/ios/Exponent/Versioned/Core/EXVersionedNetworkInterceptor.m @@ -7,7 +7,6 @@ #import #import -#import "Expo_Go-Swift.h" #import "ExpoModulesCore-Swift.h" #pragma mark - RCTInspectorPackagerConnection category interface diff --git a/ios/Podfile.lock b/ios/Podfile.lock index cb47bc4ff0e785..a165a4816a06af 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -1397,17 +1397,17 @@ PODS: - CocoaLumberjack/Core (= 3.5.3) - CocoaLumberjack/Core (3.5.3) - DoubleConversion (1.1.6) - - EASClient (0.5.1): + - EASClient (0.6.0): - ExpoModulesCore - - EASClient/Tests (0.5.1): + - EASClient/Tests (0.6.0): - ExpoModulesCore - ExpoModulesTestCore - EXApplication (5.3.0): - ExpoModulesCore - - EXAV (13.3.0): + - EXAV (13.4.0): - ExpoModulesCore - ReactCommon/turbomodule/core - - EXBackgroundFetch (11.2.0): + - EXBackgroundFetch (11.3.0): - ExpoModulesCore - EXBarCodeScanner (12.5.0): - EXImageLoader @@ -1418,68 +1418,68 @@ PODS: - Branch (= 0.35.0) - ExpoModulesCore - React-Core - - EXCalendar (11.2.0): + - EXCalendar (11.3.0): - ExpoModulesCore - EXCamera (13.4.0): - ExpoModulesCore - EXConstants (14.4.0): - ExpoModulesCore - - EXContacts (12.1.0): + - EXContacts (12.2.0): - ExpoModulesCore - EXFileSystem (15.4.0): - ExpoModulesCore - EXFileSystem/Tests (15.4.0): - ExpoModulesCore - ExpoModulesTestCore - - EXFont (11.3.0): + - EXFont (11.4.0): - ExpoModulesCore - EXImageLoader (4.3.0): - ExpoModulesCore - React-Core - - EXJSONUtils (0.6.0) - - EXJSONUtils/Tests (0.6.0) - - EXLocation (15.3.0): + - EXJSONUtils (0.7.0) + - EXJSONUtils/Tests (0.7.0) + - EXLocation (16.0.0): - ExpoModulesCore - - EXManifests (0.6.0): + - EXManifests (0.7.0): - ExpoModulesCore - - EXManifests/Tests (0.6.0): + - EXManifests/Tests (0.7.0): - ExpoModulesCore - ExpoModulesTestCore - - EXMediaLibrary (15.3.0): + - EXMediaLibrary (15.4.0): - ExpoModulesCore - RCT-Folly (= 2021.07.22.00) - React-Core - - EXNotifications (0.19.0): + - EXNotifications (0.20.0): - ExpoModulesCore - - EXPermissions (14.1.2): + - EXPermissions (14.2.0): - ExpoModulesCore - - Expo (49.0.0-alpha.4): + - Expo (49.0.0-alpha.5): - ExpoModulesCore - ExpoAppleAuthentication (6.1.0): - ExpoModulesCore - ExpoBattery (7.3.0): - ExpoModulesCore - - ExpoBlur (12.3.2): + - ExpoBlur (12.4.0): - ExpoModulesCore - - ExpoBrightness (11.3.0): + - ExpoBrightness (11.4.0): - ExpoModulesCore - - ExpoCellular (5.2.0): + - ExpoCellular (5.3.0): - ExpoModulesCore - - ExpoClipboard (4.2.0): + - ExpoClipboard (4.3.0): - ExpoModulesCore - - ExpoClipboard/Tests (4.2.0): + - ExpoClipboard/Tests (4.3.0): - ExpoModulesCore - ExpoModulesTestCore - ExpoCrypto (12.4.0): - ExpoModulesCore - - ExpoDevice (5.3.0): + - ExpoDevice (5.4.0): - ExpoModulesCore - - ExpoDocumentPicker (11.4.0): + - ExpoDocumentPicker (11.5.0): - ExpoModulesCore - ExpoGL (13.0.0): - ExpoModulesCore - ReactCommon/turbomodule/core - - ExpoHaptics (12.3.0): + - ExpoHaptics (12.4.0): - ExpoModulesCore - ExpoImage (1.3.0): - ExpoModulesCore @@ -1487,83 +1487,83 @@ PODS: - SDWebImageAVIFCoder (~> 0.10.0) - SDWebImageSVGCoder (~> 1.7.0) - SDWebImageWebPCoder (~> 0.11.0) - - ExpoImageManipulator (11.2.0): + - ExpoImageManipulator (11.3.0): - EXImageLoader - ExpoModulesCore - ExpoImagePicker (14.3.0): - ExpoModulesCore - - ExpoKeepAwake (12.2.0): + - ExpoKeepAwake (12.3.0): - ExpoModulesCore - - ExpoLinearGradient (12.2.0): + - ExpoLinearGradient (12.3.0): - ExpoModulesCore - ExpoLocalAuthentication (13.4.1): - ExpoModulesCore - - ExpoLocalization (14.2.0): + - ExpoLocalization (14.3.0): - ExpoModulesCore - - ExpoMailComposer (12.2.0): + - ExpoMailComposer (12.3.0): - ExpoModulesCore - - ExpoModulesCore (1.4.0): + - ExpoModulesCore (1.5.0): - RCT-Folly (= 2021.07.22.00) - React-Core - React-NativeModulesApple - React-RCTAppDelegate - ReactCommon/turbomodule/core - - ExpoModulesCore/Tests (1.4.0): + - ExpoModulesCore/Tests (1.5.0): - ExpoModulesTestCore - RCT-Folly (= 2021.07.22.00) - React-Core - React-NativeModulesApple - React-RCTAppDelegate - ReactCommon/turbomodule/core - - ExpoModulesTestCore (0.11.2): + - ExpoModulesTestCore (0.12.0): - ExpoModulesCore - Nimble (~> 9.2.0) - Quick (~> 5.0.0) - React-hermes - - ExpoNetwork (5.3.0): + - ExpoNetwork (5.4.0): - ExpoModulesCore - - ExpoPrint (12.3.0): + - ExpoPrint (12.4.0): - ExpoModulesCore - - ExpoRandom (13.1.2): + - ExpoRandom (13.2.0): - ExpoModulesCore - - ExpoScreenOrientation (6.0.0-beta.1): + - ExpoScreenOrientation (6.0.0): - ExpoModulesCore - RCT-Folly (= 2021.07.22.00) - React-Core - ExpoSecureStore (12.3.0): - ExpoModulesCore - - ExpoSharing (11.4.0): + - ExpoSharing (11.5.0): - ExpoModulesCore - - ExpoSMS (11.3.0): + - ExpoSMS (11.4.0): - ExpoModulesCore - - ExpoSpeech (11.2.0): + - ExpoSpeech (11.3.0): - ExpoModulesCore - - ExpoSQLite (11.2.0): + - ExpoSQLite (11.3.0): - ExpoModulesCore - - ExpoStoreReview (6.3.0): + - ExpoStoreReview (6.4.0): - ExpoModulesCore - - ExpoSystemUI (2.3.0): + - ExpoSystemUI (2.4.0): - ExpoModulesCore - ExpoTrackingTransparency (3.1.0): - ExpoModulesCore - - ExpoVideoThumbnails (7.3.0): + - ExpoVideoThumbnails (7.4.0): - ExpoModulesCore - - ExpoWebBrowser (12.2.0): + - ExpoWebBrowser (12.3.0): - ExpoModulesCore - - EXScreenCapture (5.2.0): + - EXScreenCapture (5.3.0): - ExpoModulesCore - - EXSensors (12.2.0): + - EXSensors (12.3.0): - ExpoModulesCore - - EXSplashScreen (0.19.0): + - EXSplashScreen (0.20.0): - ExpoModulesCore - RCT-Folly (= 2021.07.22.00) - React-Core - - EXStructuredHeaders (3.1.2) - - EXStructuredHeaders/Tests (3.1.2) - - EXTaskManager (11.2.0): + - EXStructuredHeaders (3.3.0) + - EXStructuredHeaders/Tests (3.3.0) + - EXTaskManager (11.3.0): - ExpoModulesCore - UMAppLoader - - EXUpdates (0.17.0): + - EXUpdates (0.18.0): - ASN1Decoder (~> 1.8) - EASClient - EXManifests @@ -1573,7 +1573,7 @@ PODS: - RCT-Folly (= 2021.07.22.00) - ReachabilitySwift - React-Core - - EXUpdates/Tests (0.17.0): + - EXUpdates/Tests (0.18.0): - ASN1Decoder (~> 1.8) - EASClient - EXManifests @@ -1584,7 +1584,7 @@ PODS: - RCT-Folly (= 2021.07.22.00) - ReachabilitySwift - React-Core - - EXUpdatesInterface (0.9.2) + - EXUpdatesInterface (0.10.0) - FBAEMKit (16.1.0): - FBSDKCoreKit_Basics (= 16.1.0) - FBAudienceNetwork (6.12.0) @@ -2302,7 +2302,7 @@ PODS: - StripeUICore (= 23.8.0) - StripeUICore (23.8.0): - StripeCore (= 23.8.0) - - UMAppLoader (4.1.2) + - UMAppLoader (4.2.0) - Yoga (1.14.0) - ZXingObjC/Core (3.6.5) - ZXingObjC/OneD (3.6.5): @@ -3641,68 +3641,68 @@ SPEC CHECKSUMS: Branch: 23b6b9351d5574377e7a764841cfb13a70c2799b CocoaLumberjack: 2f44e60eb91c176d471fdba43b9e3eae6a721947 DoubleConversion: 5189b271737e1565bdce30deb4a08d647e3f5f54 - EASClient: 950674e1098ebc09c4c2cf064a61e42e84d9d4c6 + EASClient: 49f8ea858204eb4844d9fb386e5fb7920aee2e30 EXApplication: 02655a251434d564bb0e73291f5a490c74b5b76f - EXAV: c661e742e2ee1986f5a6a030b48d9d3a3507d2f0 - EXBackgroundFetch: 10be318c278cabef5f89777002637e5f8ea3d447 + EXAV: 4e66adbd7803d487044ee1f19bf87d4de9112e76 + EXBackgroundFetch: a4a45a5924d9ac6dd480d5d745aabe91bb17bb36 EXBarCodeScanner: 379de9d8134f0c5109d64b8e758cda7016993ec9 EXBranch: 5530d282683c19ba72db83cc39e87f05c4893c1d - EXCalendar: 9de1bd96a9468021c11d561ae7612d67eadf7421 + EXCalendar: 6756a5cf09a5ad90d3abf40e2bbdfb5993ae0911 EXCamera: f9490df89710631d1c8377a66231cce0579b0df1 EXConstants: a0c9521f6d189a4e97d2e35b232a71c6ca032133 - EXContacts: 16af1b3017380e1d09a63c61ac7d664c2b1b5c88 + EXContacts: 9e8626eefc90c428af3d61a9e2869ac413d2569b EXFileSystem: ca90b9a027c0ab4bde6f65ebc7a21c5c02c9dee4 - EXFont: e5d1226176ae0e43300fadbc07502044815ffa4d + EXFont: 738c44c390953ebcbab075a4848bfbef025fd9ee EXImageLoader: 34b214f9387e98f3c73989f15d8d5b399c9ab3f7 - EXJSONUtils: babb80f7eab885b0135ae00b633d2d52b4a44fff - EXLocation: c398254c61c447517af411f20868c648569a5c35 - EXManifests: 37a0bb3514806cf432f6538fcc9825107fc23436 - EXMediaLibrary: 990f2d5685c441448208694b925f3c6f7a1e9141 - EXNotifications: 900919e062523f6b399a20fc55b03c8921ec28d7 - EXPermissions: ee60d7978aba135b8b391185b039d78f151c376a - Expo: 64f946f27e2d1fddba37bded5a5d0e8766037af6 + EXJSONUtils: 09273cf1b6a6bedc5bdae06121011123815c7f32 + EXLocation: 231f4a3683fabfed254c9498b226f7f40a40f9d8 + EXManifests: 083496dbda4035c42608ae76970f463b4611b767 + EXMediaLibrary: dd08edb824ee92519a989211720956cfd381f212 + EXNotifications: 88e6d5fe30d3c6be68f0756f39a16c917ffecf4c + EXPermissions: 336b5b8409f4e1368a8b0636f04282e7f04ced3b + Expo: 4731232362d16bbc473d2698813793b8467421a9 ExpoAppleAuthentication: 7bdf1a2962ebfe9b00eb4183a17b78d736e57185 ExpoBattery: e9d7a71960cbc40733d956a29f8ba240173feb08 - ExpoBlur: 545dd91ddcf7f51207d6011a6c4d27db9c9ab95a - ExpoBrightness: 13a6108d77641ad310b7873438a0260f9eedfe5c - ExpoCellular: c83881caef249154449532eb2245e98fdbac1d14 - ExpoClipboard: 872ae8ea230649404705b7cc09a155531e74b7bb + ExpoBlur: 9399e2dcd0b477d586040a1bd6e17ee26621f5bf + ExpoBrightness: 60c23f8aaf7b7c691907549fdc125e22f30364fe + ExpoCellular: 6817ef77e75c6d18f28388a909b96c0b3f3eb25a + ExpoClipboard: ddd3ecf4af93c003667dab75a0f2ed3ae4f73d85 ExpoCrypto: de1a3e0b9e4b6bbd83319cf0e082cae4e874ef95 - ExpoDevice: 516146e17529c3eae3f5c2c09e826efc9ffc6938 - ExpoDocumentPicker: 2dfcc5935532a3193818017da5e2f3dfda0dbf3b + ExpoDevice: 1c1b0c9cad96c292c1de73948649cfd654b2b3c0 + ExpoDocumentPicker: dc2642bc733856a3f91fc0573afbc17a302d38b7 ExpoGL: ed2c434f1f28722eab63bb89f84ae07afdde33c6 - ExpoHaptics: fb64dfe302cba07591bf1679ecb9531dadfc13cf + ExpoHaptics: 360af6898407ee4e8265d30a1a8fb16491a660eb ExpoImage: bf714e0101812ccbbd1a4fdbfd34905feeefd9f5 - ExpoImageManipulator: b8d510b4d15689d8f276dff3482df5707836035b + ExpoImageManipulator: 851be0965dd9f78019771b140282f1816dcc25ea ExpoImagePicker: bb2dded9c95c0520d343e3d0ce18fff92780c3bf - ExpoKeepAwake: c3aa02ba9d2422679f2b7ce0849134324854504d - ExpoLinearGradient: c206f987c810bf988b1896db8fa88db31b4687d6 + ExpoKeepAwake: be4cbd52d9b177cde0fd66daa1913afa3161fc1d + ExpoLinearGradient: 5966dd5d49872cc9c104fedc8bbc298b6049b2e8 ExpoLocalAuthentication: bd9d9037a96a11ccc456e327ddb404df02da10ca - ExpoLocalization: c1201ba5cfcfb187972138e58c07cc708c5399db - ExpoMailComposer: b9a4871714550d5b4e26d1873f0572e350c86478 - ExpoModulesCore: fb49cd12163cbd5aa5d6288f9533715e8661c8c6 - ExpoModulesTestCore: 42fce831c9601dcfaba09fe7a03dfe99e25754a4 - ExpoNetwork: ef59bebcdbeb6ea188157a8fc88e9ceafbff1f89 - ExpoPrint: 92311a7545d66959c6f3884e085bf336ba6c7c48 - ExpoRandom: 2b8cb73f02f534b083a1f79b10b89ca0f0111b55 - ExpoScreenOrientation: 4a17e4ed1c176532355e7378112ea5bb6c37080a + ExpoLocalization: be37fdd0b5930c6a49cd307b4542f4b426d6134c + ExpoMailComposer: feaebd62095efad901ede864b95406f02bf61681 + ExpoModulesCore: f3c45c38c6d05dbbb8367ccaea9188a8219fd0f4 + ExpoModulesTestCore: f116cd4cc4288e0e0005a1f910efc7cedf455659 + ExpoNetwork: 6ee4b3b6cfdba3bfb90b07f483d1111308a9c76a + ExpoPrint: 2f5fd8fb92bf630eb196e4da122b02e5caa8a339 + ExpoRandom: 4f2bba684312acd6c0700528ae62f85265776c84 + ExpoScreenOrientation: 6fe266925a6be4e5217ff7bbe0d4248ef058768b ExpoSecureStore: 0eca38e7545759c121a731ccfd26c7286ce18653 - ExpoSharing: 3e3efb3d93e169dcce0f749aa8427317c033639f - ExpoSMS: c360a9e17e3590f2b2f95adc57f5143baeec2793 - ExpoSpeech: 3ba0e08a0dfa8533f82e1c4ad21b8df93bd9dc4a - ExpoSQLite: 9710adce5dc48ee6c58515cce2185f6837b88b7c - ExpoStoreReview: 69f68b07656f26540f2b38f971527609860930c8 - ExpoSystemUI: d11bbe88d97a59cf691ccab325ee99ac655d1135 + ExpoSharing: 825b2b3fc919a2656f75def0069f584bbd6e359a + ExpoSMS: c8079b3018ae5206b3f1f6f445fd4eee2a19a335 + ExpoSpeech: 3c06cdcd31c07889a9f7085c2496ab97364427be + ExpoSQLite: 892e21a9ae411d54d189bef35a8f47c8184e645a + ExpoStoreReview: f154c9fdf3dbd877ca0115757f0b2b6f43dd9db4 + ExpoSystemUI: fa4854e3226e87f86d3383570264c6e4e90bc782 ExpoTrackingTransparency: 28cb4ba43e61231c4173507ba05b3ce8c777f173 - ExpoVideoThumbnails: 4c5aa4a1ed34041844da7f8ba2967630d2573bdc - ExpoWebBrowser: eac23f0fd2b8ad7ec7056fc208091722bba17952 - EXScreenCapture: c55e42588fb2dc985a02b4b6aa1fb6e83157c653 - EXSensors: 6422e6bf51cfeee632d9cb61536d6038b680acfb - EXSplashScreen: 8d00c7b625ec0f952a17ab685e1f03ac0e5c1795 - EXStructuredHeaders: f3a6d417d5d12ef369fd1a31320d1c188a1b0f4b - EXTaskManager: a7a387c4e222176988261341680aa7e3f621a335 - EXUpdates: d01f25d40e711ac9b52f64c36410c1b30ac54e3b - EXUpdatesInterface: c08eaa7e4d1fdafff3820e0539a6d42a75fa0258 + ExpoVideoThumbnails: 3b5ec2a802a67b6e1a22d38b4526ef4619dd3938 + ExpoWebBrowser: b0a2dcd2b246b83cc264559c87113d0d0a744e47 + EXScreenCapture: 81002ba5fb40a367fba9047d223068abb558594d + EXSensors: d26e160b5c91ada2df4a638859ef0c5731bf6404 + EXSplashScreen: ca269bd698a7a40a6dac452eff88042a18a40f1b + EXStructuredHeaders: 324cc3130571d2696357fafd8be7fd9a0b5fdf6e + EXTaskManager: f1730c315eb6fe457a3a2ee4ed899a51d717f302 + EXUpdates: 066eafbc9837ee4de1ca9b297399efe32a840764 + EXUpdatesInterface: 65a425322c67e3c96952b47ac110df3fef65c6b3 FBAEMKit: c7efe06720a8b15b1d25b68921ba46dee20996e0 FBAudienceNetwork: e0fcc9091fced34910ed0b6da06f129db46ac9e6 FBLazyVector: bb17efca94c43508cbe54fb0a35e36df30da5213 @@ -3803,7 +3803,7 @@ SPEC CHECKSUMS: StripePaymentSheet: 1fef5afa050bfd684e84553cba613041a2b3d7b7 StripePaymentsUI: 7d2fc8fe17c3fdc63508bc54df2b7cc3f45c8ef7 StripeUICore: 1dc4d2f9afcd908db85190e9091dfe260a1861fe - UMAppLoader: d1cd37524ea948f9e695722994496784a6d6213c + UMAppLoader: e83f024f75f07802fce99739f04b4537d188caaf Yoga: 1d6727ed193122f6adaf435c3de1a768326ff83b ZXingObjC: fdbb269f25dd2032da343e06f10224d62f537bdb diff --git a/packages/expo-modules-core/ios/ExpoModulesCore.h b/packages/expo-modules-core/ios/ExpoModulesCore.h index 9d38b560e2121d..4243f1675a3b26 100644 --- a/packages/expo-modules-core/ios/ExpoModulesCore.h +++ b/packages/expo-modules-core/ios/ExpoModulesCore.h @@ -8,6 +8,6 @@ // Otherwise they won't be visible in `ExpoModulesCore-Swift.h`. #import -#if __has_include("ExpoModulesCore-umbrella.h") -#import "ExpoModulesCore-umbrella.h" +#if __has_include() +#import #endif diff --git a/packages/expo-modules-core/ios/JSI/EXJSIInstaller.h b/packages/expo-modules-core/ios/JSI/EXJSIInstaller.h index 2c0c1b7571e7e8..24f85668b28ada 100644 --- a/packages/expo-modules-core/ios/JSI/EXJSIInstaller.h +++ b/packages/expo-modules-core/ios/JSI/EXJSIInstaller.h @@ -4,7 +4,7 @@ // Swift classes need forward-declaration in the headers. @class EXAppContext; -@class ExpoRuntime; +@class EXRuntime; @interface EXJavaScriptRuntimeManager : NSObject @@ -12,7 +12,7 @@ Gets the JS runtime from the given bridge. May return `nil` when the runtime is not available yet or the remote debugging is enabled. */ -+ (nullable ExpoRuntime *)runtimeFromBridge:(nonnull RCTBridge *)bridge NS_SWIFT_NAME(runtime(fromBridge:)); ++ (nullable EXRuntime *)runtimeFromBridge:(nonnull RCTBridge *)bridge NS_SWIFT_NAME(runtime(fromBridge:)); /** Installs ExpoModules host object in the runtime of the given app context. diff --git a/packages/expo-modules-core/ios/JSI/EXJSIInstaller.mm b/packages/expo-modules-core/ios/JSI/EXJSIInstaller.mm index fe380644d9c7c8..d46d9b0aa44867 100644 --- a/packages/expo-modules-core/ios/JSI/EXJSIInstaller.mm +++ b/packages/expo-modules-core/ios/JSI/EXJSIInstaller.mm @@ -27,15 +27,15 @@ - (void *)runtime; @implementation EXJavaScriptRuntimeManager -+ (nullable ExpoRuntime *)runtimeFromBridge:(nonnull RCTBridge *)bridge ++ (nullable EXRuntime *)runtimeFromBridge:(nonnull RCTBridge *)bridge { jsi::Runtime *jsiRuntime = [bridge respondsToSelector:@selector(runtime)] ? reinterpret_cast(bridge.runtime) : nullptr; - return jsiRuntime ? [[ExpoRuntime alloc] initWithRuntime:jsiRuntime callInvoker:bridge.jsCallInvoker] : nil; + return jsiRuntime ? [[EXRuntime alloc] initWithRuntime:jsiRuntime callInvoker:bridge.jsCallInvoker] : nil; } + (BOOL)installExpoModulesHostObject:(nonnull EXAppContext *)appContext { - ExpoRuntime *runtime = [appContext _runtime]; + EXRuntime *runtime = [appContext _runtime]; // The runtime may be unavailable, e.g. remote debugger is enabled or it hasn't been set yet. if (!runtime) { diff --git a/packages/expo-modules-core/ios/Swift.h b/packages/expo-modules-core/ios/Swift.h index a21af9292bbc69..79f2d67f4d84fe 100644 --- a/packages/expo-modules-core/ios/Swift.h +++ b/packages/expo-modules-core/ios/Swift.h @@ -3,6 +3,8 @@ // The generated swift header may depend on some Objective-C declarations, // adding dependency imports here to prevent declarations not found errors. #import +#import +#import #import // When `use_frameworks!` is used, the generated Swift header is inside ExpoModulesCore module. diff --git a/packages/expo-modules-core/ios/Swift/ExpoRuntime.swift b/packages/expo-modules-core/ios/Swift/ExpoRuntime.swift index 8f85cdfce87c91..486518a9507f1c 100644 --- a/packages/expo-modules-core/ios/Swift/ExpoRuntime.swift +++ b/packages/expo-modules-core/ios/Swift/ExpoRuntime.swift @@ -3,7 +3,7 @@ */ private let coreObjectPropertyName = "expo" -@objc(ExpoRuntime) +@objc(EXRuntime) public final class ExpoRuntime: JavaScriptRuntime { /** The core object of the Expo runtime that is used to scope native Expo-specific functionalities. diff --git a/packages/expo-updates/ios/EXUpdates/UpdatesModule.swift b/packages/expo-updates/ios/EXUpdates/UpdatesModule.swift index 6c1c594c2437bf..7efa5f201afa0a 100644 --- a/packages/expo-updates/ios/EXUpdates/UpdatesModule.swift +++ b/packages/expo-updates/ios/EXUpdates/UpdatesModule.swift @@ -20,6 +20,8 @@ public final class UpdatesModule: Module { public required init(appContext: AppContext) { updatesService = appContext.legacyModule(implementing: EXUpdatesModuleInterface.self) + // Ensures the universal UpdatesConfig can cast to versioned UpdatesConfig without exception in Swift + object_setClass(updatesService?.config, UpdatesConfig.self) super.init(appContext: appContext) } diff --git a/template-files/ios/ExpoKit.podspec b/template-files/ios/ExpoKit.podspec index 171b1373d2ba30..971fb353398b40 100644 --- a/template-files/ios/ExpoKit.podspec +++ b/template-files/ios/ExpoKit.podspec @@ -15,7 +15,7 @@ Pod::Spec.new do |s| s.default_subspec = "Core" s.source = { :git => "http://github.com/expo/expo.git" } s.xcconfig = { - 'CLANG_CXX_LANGUAGE_STANDARD' => 'gnu++14', + 'CLANG_CXX_LANGUAGE_STANDARD' => 'c++17', 'SYSTEM_HEADER_SEARCH_PATHS' => "\"$(PODS_ROOT)/boost\" \"$(PODS_ROOT)/RCT-Folly\" \"$(PODS_ROOT)/Headers/Private/React-Core\"", 'OTHER_CPLUSPLUSFLAGS' => [ "$(OTHER_CFLAGS)", diff --git a/tools/src/vendoring/legacy.ts b/tools/src/vendoring/legacy.ts index fce89b3dcb48c5..29b39264db49ba 100644 --- a/tools/src/vendoring/legacy.ts +++ b/tools/src/vendoring/legacy.ts @@ -77,6 +77,20 @@ const SvgModifier: ModuleModifier = async function ( await addHeaderImport(); }; +const MapsModifier: ModuleModifier = async function ( + moduleConfig: VendoredModuleConfig, + clonedProjectPath: string +): Promise { + const fixGoogleMapsImports = async () => { + const targetPath = path.join(clonedProjectPath, 'ios', 'AirGoogleMaps', 'AIRGoogleMap.m'); + let content = await fs.readFile(targetPath, 'utf8'); + content = content.replace(/^#import "(GMU.+?\.h)"$/gm, '#import '); + await fs.writeFile(targetPath, content, 'utf8'); + }; + + await fixGoogleMapsImports(); +}; + const ReanimatedModifier: ModuleModifier = async function ( moduleConfig: VendoredModuleConfig, clonedProjectPath: string @@ -548,6 +562,7 @@ const vendoredModulesConfig: { [key: string]: VendoredModuleConfig } = { 'react-native-maps': { repoUrl: 'https://github.com/react-native-community/react-native-maps.git', installableInManagedApps: true, + moduleModifier: MapsModifier, steps: [ { sourceIosPath: 'ios/AirGoogleMaps', diff --git a/tools/src/versioning/ios/index.ts b/tools/src/versioning/ios/index.ts index f999763eaaf2ba..fc650f551b8b5f 100644 --- a/tools/src/versioning/ios/index.ts +++ b/tools/src/versioning/ios/index.ts @@ -9,7 +9,13 @@ import path from 'path'; import semver from 'semver'; import { runReactNativeCodegenAsync } from '../../Codegen'; -import { EXPO_DIR, IOS_DIR, VERSIONED_RN_IOS_DIR } from '../../Constants'; +import { + EXPO_DIR, + IOS_DIR, + REACT_NATIVE_SUBMODULE_DIR, + REACT_NATIVE_SUBMODULE_MONOREPO_ROOT, + VERSIONED_RN_IOS_DIR, +} from '../../Constants'; import logger from '../../Logger'; import { getListOfPackagesAsync, Package } from '../../Packages'; import { copyFileWithTransformsAsync } from '../../Transforms'; @@ -35,7 +41,7 @@ import { export { versionVendoredModulesAsync, versionExpoModulesAsync }; const UNVERSIONED_PLACEHOLDER = '__UNVERSIONED__'; -const RELATIVE_RN_PATH = './react-native-lab/react-native'; +const RELATIVE_RN_PATH = path.relative(EXPO_DIR, REACT_NATIVE_SUBMODULE_DIR); const EXTERNAL_REACT_ABI_DEPENDENCIES = [ 'Analytics', @@ -216,6 +222,7 @@ async function generateVersionedReactNativeAsync(versionName: string): Promise "#\\{react_native_path\\}\\/sdks\\/hermes-engine\\/hermes-engine.podspec"`, + `^\\s*pod '${versionName}hermes-engine', :podspec => "#\\{react_native_path\\}\\/sdks\\/hermes-engine\\/hermes-engine.podspec", :tag => hermestag`, 'gm' ), replaceWith: ` if File.exist?("#{react_native_path}/sdks/hermes-engine/destroot") - pod '${versionName}hermes-engine', :path => "#{react_native_path}/sdks/hermes-engine", :project_name => '${versionName}' + pod '${versionName}hermes-engine', :path => "#{react_native_path}/sdks/hermes-engine", :project_name => '${versionName}', :tag => '${hermesVersion}' else - pod '${versionName}hermes-engine', :podspec => "#{react_native_path}/sdks/hermes-engine/${versionName}hermes-engine.podspec", :project_name => '${versionName}' + pod '${versionName}hermes-engine', :podspec => "#{react_native_path}/sdks/hermes-engine/${versionName}hermes-engine.podspec", :project_name => '${versionName}', :tag => '${hermesVersion}' end`, }, { find: new RegExp(`\\b${versionName}(libevent)\\b`, 'g'), replaceWith: '$1' }, @@ -622,11 +642,13 @@ boost_compiler_flags = '-Wno-documentation'\n\n` ` s.pod_target_xcconfig = { "USE_HEADERMAP" => "YES", - "HEADER_SEARCH_PATHS" => "\\"$(PODS_TARGET_SRCROOT)/ReactCommon\\" \\"$(PODS_TARGET_SRCROOT)\\" \\"$(PODS_ROOT)/RCT-Folly\\" \\"$(PODS_ROOT)/boost\\" \\"$(PODS_ROOT)/DoubleConversion\\" \\"$(PODS_ROOT)/Headers/Private/React-Core\\" " + "DEFINES_MODULE" => "YES", + "HEADER_SEARCH_PATHS" => "\\"$(PODS_TARGET_SRCROOT)/ReactCommon\\" \\"$(PODS_TARGET_SRCROOT)\\" \\"$(PODS_ROOT)/RCT-Folly\\" \\"$(PODS_ROOT)/boost\\" \\"$(PODS_ROOT)/DoubleConversion\\" \\"$(PODS_ROOT)/Headers/Private/${versionName}React-Core\\" \\"\$(PODS_CONFIGURATION_BUILD_DIR)/${versionName}ExpoModulesCore/Swift Compatibility Header\\"" } s.compiler_flags = folly_compiler_flags + ' ' + boost_compiler_flags s.xcconfig = { - "HEADER_SEARCH_PATHS" => "\\"$(PODS_ROOT)/boost\\" \\"$(PODS_ROOT)/glog\\" \\"$(PODS_ROOT)/RCT-Folly\\" \\"$(PODS_ROOT)/Headers/Private/${versionName}React-Core\\"", + "CLANG_CXX_LANGUAGE_STANDARD" => "c++17", + "HEADER_SEARCH_PATHS" => "\\"$(PODS_ROOT)/boost\\" \\"$(PODS_ROOT)/glog\\" \\"$(PODS_ROOT)/RCT-Folly\\" \\"$(PODS_ROOT)/Headers/Private/${versionName}React-Core\\" \\"\$(PODS_CONFIGURATION_BUILD_DIR)/${versionName}ExpoModulesCore/Swift Compatibility Header\\"", "OTHER_CFLAGS" => "$(inherited)" + " " + folly_flags }\n\n` ); @@ -804,10 +826,13 @@ if pod_name.start_with?('${versionedPodNames.React}') || pod_name == '${versione target_installation_result.native_target.build_configurations.each do |config| config.build_settings['OTHER_CFLAGS'] = %w[ ${configValues.join(`\n${indent}`)} + -fmodule-map-file="\${PODS_ROOT}/Headers/Public/${versionName}React-Core/${versionName}React/${versionName}React-Core.modulemap" + -fmodule-map-file="\${PODS_ROOT}/Headers/Public/${versionName}ExpoModulesCore/${versionName}ExpoModulesCore.modulemap" ] config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)'] config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << '${versionName}RCT_DEV=1' config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << '${versionName}RCT_ENABLE_INSPECTOR=0' + config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << '${versionName}RCT_REMOTE_PROFILE=0' config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << '${versionName}RCT_DEV_SETTINGS_ENABLE_PACKAGER_CONNECTION=0' # Enable Google Maps support config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << '${versionName}HAVE_GOOGLE_MAPS=1' diff --git a/tools/src/versioning/ios/transforms/expoModulesTransforms.ts b/tools/src/versioning/ios/transforms/expoModulesTransforms.ts index 4928f35b64721c..dfae56c9f40c7a 100644 --- a/tools/src/versioning/ios/transforms/expoModulesTransforms.ts +++ b/tools/src/versioning/ios/transforms/expoModulesTransforms.ts @@ -68,13 +68,13 @@ export function expoModulesTransforms(prefix: string): FileTransforms { { // Prefix `Expo*` frameworks in imports. paths: objcFilesPattern, - find: /#(import|include) <(Expo|EAS)(.*?)\//g, - replaceWith: `#$1 <${prefix}$2$3/`, + find: /#(import |include |if __has_include\()<(Expo|EAS)(.*?)\//g, + replaceWith: `#$1<${prefix}$2$3/`, }, { paths: objcFilesPattern, - find: /#import <(.*?)\/(Expo|EAS)(.*?)\.h>/g, - replaceWith: `#import <$1/${prefix}$2$3.h>`, + find: /#(import |include |if __has_include\()<(.*?)\/(Expo|EAS)(.*?)\.h>/g, + replaceWith: `#$1<$2/${prefix}$3$4.h>`, }, { // Rename Swift compatibility headers from frameworks starting with `Expo`. @@ -137,7 +137,7 @@ export function expoModulesTransforms(prefix: string): FileTransforms { { paths: '*.h', // Use negative look ahead regexp for `prefix` to prevent duplicated versioning - find: new RegExp(`\b(!?${prefix})(\w+-umbrella\.h)\b`, 'g'), + find: new RegExp(`[\b/](!?${prefix})(\w+-umbrella\.h)\b`, 'g'), replaceWith: `${prefix}$1`, }, diff --git a/tools/src/versioning/ios/transforms/podspecTransforms.ts b/tools/src/versioning/ios/transforms/podspecTransforms.ts index 7716cdcb2085b5..bff694cdac3cef 100644 --- a/tools/src/versioning/ios/transforms/podspecTransforms.ts +++ b/tools/src/versioning/ios/transforms/podspecTransforms.ts @@ -55,9 +55,14 @@ export function podspecTransforms(versionName: string): TransformPipeline { }, { // Fixes HEADER_SEARCH_PATHS - paths: ['React-Core.podspec', 'ReactCommon.podspec'], + paths: [ + 'React-Core.podspec', + 'ReactCommon.podspec', + 'React-NativeModulesApple.podspec', + 'React-RCTAppDelegate.podspec', + ], replace: - /(Headers\/Private\/|Headers\/Public\/|_BUILD_DIR\)\/)(React-Core|React-bridging|React-hermes|hermes-engine)/g, + /(Headers\/Private\/|Headers\/Public\/|_BUILD_DIR\)\/)(React-Core|React-bridging|React-hermes|hermes-engine|ReactCommon|React-RCTFabric)/g, with: `$1${versionName}$2`, }, // React-cxxreact @@ -86,10 +91,9 @@ export function podspecTransforms(versionName: string): TransformPipeline { with: `{${versionName}$1,${versionName}$2,${versionName}$3,${versionName}$4,${versionName}$5,${versionName}$6}`, }, - // FBReactNativeSpec + // Remove codegen from build phase script { - // Remove codegen from build phase script - paths: 'FBReactNativeSpec.podspec', + paths: ['FBReactNativeSpec.podspec', 'React-rncore.podspec'], replace: /\n use_react_native_codegen!\((.|\n)+?\n }\)\n/gm, with: '', }, diff --git a/tools/src/versioning/ios/transforms/postTransforms.ts b/tools/src/versioning/ios/transforms/postTransforms.ts index c90241b6f19894..6b78fcfb963af8 100644 --- a/tools/src/versioning/ios/transforms/postTransforms.ts +++ b/tools/src/versioning/ios/transforms/postTransforms.ts @@ -77,6 +77,28 @@ export function postTransforms(versionName: string): TransformPipeline { replace: new RegExp(`(React)\\/${versionName}(bridging)\\/`, 'g'), with: `$1/$2/${versionName}`, }, + { + // Files inside fabric directory used to have nested import paths and we transformed it wrong. + // This rules are here to fix it. + // e.g. `#include ` + // -> `#include ` + // -> `#include ` + paths: ['ReactCommon/react/', 'React/'], + replace: new RegExp( + `(^(#include|#import) <${versionName}React)/${versionName}([^/\\n]+?)/(${versionName})?([^/\\n]+?\\.h>$)`, + 'gm' + ), + with: `$1/$3/${versionName}$5`, + }, + { + // Same as above but for difference nested level. + paths: ['Libraries/AppDelegate/', 'ReactCommon/react/', 'React/'], + replace: new RegExp( + `(^(#include|#import) <${versionName}React)/${versionName}([^/\\n]+?)\\/([^/\\n]+?)\\/(${versionName})?([^/\\n]+?\\.h>$)`, + 'gm' + ), + with: `$1/$3/$4/${versionName}$6`, + }, { // Codegen adds methods to `RCTCxxConvert` that start with `JS_`, which refer to `JS::` // C++ namespace that we prefix, so these methods must be prefixed as well. @@ -140,6 +162,11 @@ export function postTransforms(versionName: string): TransformPipeline { replace: /\b(WMSTileOverlay)\b/g, with: `${versionName}$1`, }, + { + paths: 'AIRGoogleMap', + replace: new RegExp(`^#import "${versionName}(GMU.+?\\.h)"`, 'gm'), + with: `#import `, + }, // react-native-webview { diff --git a/tools/src/versioning/ios/transforms/vendoredModulesTransforms.ts b/tools/src/versioning/ios/transforms/vendoredModulesTransforms.ts index 774b209b8f5b11..3f82d02f5ee3d0 100644 --- a/tools/src/versioning/ios/transforms/vendoredModulesTransforms.ts +++ b/tools/src/versioning/ios/transforms/vendoredModulesTransforms.ts @@ -27,23 +27,18 @@ export default function vendoredModulesTransformsFactory(prefix: string): Config 'react-native-webview': { content: [ { - paths: 'RNCWebView.m', - find: new RegExp(`#import "objc/${prefix}runtime\\.h"`, ''), - replaceWith: '#import "objc/runtime.h"', - }, - { - paths: 'RNCWebView.m', + paths: 'RNCWebViewImpl.m', find: /\b(_SwizzleHelperWK)\b/g, replaceWith: `${prefix}$1`, }, { // see issue: https://github.com/expo/expo/issues/4463 - paths: 'RNCWebView.m', + paths: 'RNCWebViewImpl.m', find: /MessageHandlerName = @"ABI\d+_\d+_\d+ReactNativeWebView";/, replaceWith: `MessageHandlerName = @"ReactNativeWebView";`, }, { - paths: 'RNCWebView.m', + paths: 'RNCWebViewImpl.m', find: 'NSString *const CUSTOM_SELECTOR', replaceWith: 'static NSString *const CUSTOM_SELECTOR', }, @@ -103,29 +98,71 @@ export default function vendoredModulesTransformsFactory(prefix: string): Config replaceWith: `${prefix}$1`, }, { - paths: 'REANodesManager.m', + paths: 'REANodesManager.mm', find: /\b(ComponentUpdate)\b/g, replaceWith: `${prefix}$1`, }, { - // versioning reacthermes import - paths: 'NativeProxy.mm', + paths: 'REASnapshot.m', + find: /^(const int (ScreenStackPresentationModal|DEFAULT_MODAL_TOP_OFFSET))/gm, + replaceWith: `static $1`, + }, + { + paths: [ + 'NativeProxy.mm', + 'ReanimatedRuntime.h', + 'ReanimatedRuntime.cpp', + 'ReanimatedHermesRuntime.h', + 'ReanimatedHermesRuntime.cpp', + 'REAMessageThread.h', + ], find: new RegExp( - `(#if\\s+__has_include\\(|#import\\s+)`, + `(__has_include\\(|#import\\s+|#include\\s+)<(cxxreact|reacthermes)\\/(${prefix})?(MessageQueueThread|HermesExecutorFactory)(\\.h>\\)?)`, 'g' ), - replaceWith: `$1<${prefix}reacthermes/${prefix}HermesExecutorFactory.h>`, + replaceWith: `$1<${prefix}$2/${prefix}$4$5`, + }, + { + paths: ['ReanimatedRuntime.h', 'ReanimatedHermesRuntime.h'], + find: ` ) || __has_include())`, + replaceWith: ` <${prefix}reacthermes/${prefix}HermesExecutorFactory.h>) || __has_include())`, }, { - paths: '**/*.{h,mm}', - find: new RegExp(`${prefix}(REACT_NATIVE_MINOR_VERSION)`, 'g'), - replaceWith: '$1', + paths: ['ReanimatedHermesRuntime.h', 'ReanimatedHermesRuntime.cpp'], + find: /^((#if __has_include|#include).+\/)(RuntimeAdapter|Registration)(\.h>)$/gm, + replaceWith: `$1${prefix}$3$4`, + }, + { + paths: 'RCTAppDelegate+Reanimated.h', + find: new RegExp(`<${prefix}React-${prefix}RCTAppDelegate/`, 'g'), + replaceWith: `<${prefix}React-RCTAppDelegate/`, + }, + { + paths: 'RCTAppDelegate+Reanimated.h', + find: new RegExp( + `(#if __has_include\\(|#import )<${prefix}React-cxxreact/cxxreact/JSExecutor\\.h>`, + 'g' + ), + replaceWith: `$1<${prefix}React-cxxreact/${prefix}cxxreact/${prefix}JSExecutor.h>`, + }, + { + // Workaround for jsi somehow be transformed back to unversioned path + find: /^#include /gm, + replaceWith: `#include <${prefix}jsi/${prefix}jsi.h>`, }, { paths: 'RNReanimated.podspec.json', - find: /(REANIMATED_VERSION)/g, + find: /(REACT_NATIVE_MINOR_VERSION|REANIMATED_VERSION)/g, replaceWith: `${prefix}$1`, }, + { + paths: 'RNReanimated.podspec.json', + find: new RegExp( + `\\/react-native-lab\\/react-native\\/packages\\/react-native\\/${prefix}ReactCommon`, + 'g' + ), + replaceWith: `/ios/versioned-react-native/${prefix}/ReactNative/ReactCommon`, + }, ], }, 'react-native-gesture-handler': { @@ -175,7 +212,7 @@ export default function vendoredModulesTransformsFactory(prefix: string): Config '@shopify/react-native-skia': { path: [ { - find: /\b(DisplayLink|PlatformContext|SkiaDrawView|SkiaDrawViewManager|SkiaManager|SkiaUIView|SkiaPictureViewManager|SkiaDomViewManager)/g, + find: /\b(DisplayLink|PlatformContext|SkiaDrawView|SkiaDrawViewManager|SkiaManager|SkiaUIView|SkiaPictureViewManager|SkiaDomViewManager|ViewScreenshotService)/g, replaceWith: `${prefix}$1`, }, ], @@ -186,7 +223,7 @@ export default function vendoredModulesTransformsFactory(prefix: string): Config replaceWith: `ReactCommon/${prefix}`, }, { - find: /\b(DisplayLink|PlatformContext|SkiaDrawView|SkiaDrawViewManager|SkiaManager|RNJsi|SkiaUIView|SkiaPictureViewManager|SkiaDomViewManager)/g, + find: /\b(DisplayLink|PlatformContext|SkiaDrawView|SkiaDrawViewManager|SkiaManager|RNJsi|SkiaUIView|SkiaPictureViewManager|SkiaDomViewManager|ViewScreenshotService)/g, replaceWith: `${prefix}$1`, }, { diff --git a/tools/src/versioning/ios/versionExpoModules.ts b/tools/src/versioning/ios/versionExpoModules.ts index c42e05d029f0fc..4cd9e85f898235 100644 --- a/tools/src/versioning/ios/versionExpoModules.ts +++ b/tools/src/versioning/ios/versionExpoModules.ts @@ -16,7 +16,7 @@ import { getVersionPrefix, getVersionedDirectory } from './utils'; const TIMER_LABEL = 'Versioning expo modules finished in'; // The pattern that matches the dependency pods that need to be renamed in `*.podspec.json`. -const PODSPEC_DEPS_TO_RENAME_PATTERN = /^(Expo|EX|UM|EAS|React|RCT|Yoga)/; +const PODSPEC_DEPS_TO_RENAME_PATTERN = /^(Expo|EX|UM|EAS|React|RCT|Yoga)(?!-Folly)/; // The pattern that matches the file that need to be renamed in `*.podspec.json`. const PODSPEC_FILES_TO_RENAME_PATTERN = /^(Expo|EX|UM|EAS|React|RCT|Yoga|hermes-engine)(?!-Folly)/; diff --git a/tools/src/versioning/ios/versionHermes.ts b/tools/src/versioning/ios/versionHermes.ts index 8066a48eebe256..30ee354b75cb87 100644 --- a/tools/src/versioning/ios/versionHermes.ts +++ b/tools/src/versioning/ios/versionHermes.ts @@ -18,6 +18,7 @@ const TRANSFORM_HEADERS_PUBLIC = [ 'DebuggerTypes', 'GCConfig', 'GCTripwireContext', + 'HermesExport', ]; const VERSIONED_JSI_DIR = 'versioned-jsi'; @@ -29,7 +30,7 @@ interface VersionHermesOptions { // specify custom hermes download dir, use temp dir by default hermesDir?: string; - // specify hermes git ref, use the version from *react-native-lab/react-native/sdks/.hermesversion* by default + // specify hermes git ref, use the version from *react-native-lab/react-native/packages/react-native/sdks/.hermesversion* by default hermesGitRef?: string; } @@ -125,12 +126,6 @@ async function transformHermesAsync( ) ) ); - // workaround for 0.69 as it doesn't support specifying custom JSI path - await spawnAsync('wget', [ - '-O', - path.join(hermesRoot, 'utils/build-apple-framework.sh'), - 'https://raw.githubusercontent.com/facebook/react-native/0.70-stable/sdks/hermes-engine/utils/build-apple-framework.sh', - ]); // copy versioned jsi files from react-native const versionedJsiDir = path.join(hermesRoot, VERSIONED_JSI_DIR); diff --git a/yarn.lock b/yarn.lock index 1e4f8545495a3e..1b97e016ae0f04 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1310,6 +1310,23 @@ resolved "https://registry.yarnpkg.com/@expo/config-types/-/config-types-48.0.0.tgz#15a46921565ffeda3c3ba010701398f05193d5b3" integrity sha512-DwyV4jTy/+cLzXGAo1xftS6mVlSiLIWZjl9DjTCLPFVgNYQxnh7htPilRv4rBhiNs7KaznWqKU70+4zQoKVT9A== +"@expo/config@~8.0.0": + version "8.0.2" + resolved "https://registry.yarnpkg.com/@expo/config/-/config-8.0.2.tgz#53ecfa9bafc97b990ff9e34e210205b0e3f05751" + integrity sha512-WubrzTNNdAXy1FU8TdyQ7D9YtDj2tN3fWXDq+C8In+nB7Qc08zwH9cVdaGZ+rBVmjFZBh5ACfObKq/m9cm4QQA== + dependencies: + "@babel/code-frame" "~7.10.4" + "@expo/config-plugins" "~6.0.0" + "@expo/config-types" "^48.0.0" + "@expo/json-file" "^8.2.37" + getenv "^1.0.0" + glob "7.1.6" + require-from-string "^2.0.2" + resolve-from "^5.0.0" + semver "7.3.2" + slugify "^1.3.4" + sucrase "^3.20.0" + "@expo/configure-splash-screen@^0.6.0": version "0.6.0" resolved "https://registry.yarnpkg.com/@expo/configure-splash-screen/-/configure-splash-screen-0.6.0.tgz#07d97ee512fd859fcc09506ba3762fd6263ebc39"