From 55229da0714dfbbed1ee4b142bb4c3b30a3eed18 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Wed, 21 Feb 2024 15:30:32 +0100 Subject: [PATCH 1/2] Apply workaround in `gutenberg_post_install` to address build failure This workaround solves the issue related to redefining `clockid_t` in the pod `RCT-Folly` when using a local bundle. --- Gutenberg/cocoapods_helpers.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Gutenberg/cocoapods_helpers.rb b/Gutenberg/cocoapods_helpers.rb index 3a038b2e7030..33fd5a322b11 100644 --- a/Gutenberg/cocoapods_helpers.rb +++ b/Gutenberg/cocoapods_helpers.rb @@ -124,6 +124,12 @@ def gutenberg_post_install(installer:) react_native_path = Pathname.new(react_native_path).relative_path_from(Dir.pwd) react_native_post_install(installer, react_native_path) + + # The following workaround is needed to avoid the error `typedef redefinition with different types ('uint8_t' (aka 'unsigned char') vs 'enum clockid_t')`. + # This solution is referenced in https://github.com/facebook/react-native/issues/39568#issuecomment-1762890606. + # It will be needed until RCT-Folly version is bumped in React Native to version v2022.08.29.00 or above. + # Referece: https://github.com/facebook/folly/commit/4a2410fae65afb85e1fec6d922005054b05de59f + __apply_Xcode_12_5_M1_post_install_workaround(installer) end def gutenberg_post_integrate From 29476af6cfe3a8875abeb9836951a551505c95f8 Mon Sep 17 00:00:00 2001 From: Carlos Garcia Date: Wed, 21 Feb 2024 15:56:54 +0100 Subject: [PATCH 2/2] Fix missing space in inline comment --- Gutenberg/cocoapods_helpers.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gutenberg/cocoapods_helpers.rb b/Gutenberg/cocoapods_helpers.rb index 33fd5a322b11..af2272be1fed 100644 --- a/Gutenberg/cocoapods_helpers.rb +++ b/Gutenberg/cocoapods_helpers.rb @@ -125,7 +125,7 @@ def gutenberg_post_install(installer:) react_native_post_install(installer, react_native_path) - # The following workaround is needed to avoid the error `typedef redefinition with different types ('uint8_t' (aka 'unsigned char') vs 'enum clockid_t')`. + # The following workaround is needed to avoid the error `typedef redefinition with different types ('uint8_t' (aka 'unsigned char') vs 'enum clockid_t')`. # This solution is referenced in https://github.com/facebook/react-native/issues/39568#issuecomment-1762890606. # It will be needed until RCT-Folly version is bumped in React Native to version v2022.08.29.00 or above. # Referece: https://github.com/facebook/folly/commit/4a2410fae65afb85e1fec6d922005054b05de59f