After installing react-native-firebase/[email protected]
with react-native-0.68.1
using use_frameworks!
and remove flipper
in the podfile of the project , but when i ran npx react-native run-ios
it’s Build failed
The following build commands failed:
Ld /Users/userName/Library/Developer/Xcode/DerivedData/-gvnovwrlbjvxedcquaumtvgvdgmn/Build/Products/Debug-iphonesimulator/react-native-razorpay/react_native_razorpay.framework/react_native_razorpay normal (in target ‘react-native-razorpay’ from project ‘Pods’)
(1 failure) , The Project also contain react-native-razorpay
previously added ..now what to do for removing the error and build will succeed with out any crash, Please help i am new to react-native
my podfile looks like “` #use_modular_headers!
require_relative ‘../node_modules/react-native/scripts/react_native_pods’
require_relative ‘../node_modules/@react-native-community/cli-platform-ios/native_modules’
platform :ios, ‘12.0’
install! ‘cocoapods’, :deterministic_uuids => false
target ‘DussriShadi’ do
use_frameworks!
config = use_native_modules!
Flags change depending on the env values.
flags = get_default_flags()
use_react_native!(
:path => config[:reactNativePath],
# to enable hermes on iOS, change false
to true
and then install pods
:hermes_enabled => flags[:hermes_enabled],
:fabric_enabled => flags[:fabric_enabled],
# An absolute path to your application root.
:app_path => "#{Pod::Config.instance.installation_root}/.."
)
target ‘DussriShadiTests’ do
inherit! :complete
# Pods for
end
Enables Flipper.
Note that if you have use_frameworks! enabled, Flipper will not work and
you should disable the next line.
#use_flipper!()
post_install do |installer|
react_native_post_install(installer)
__apply_Xcode_12_5_M1_post_install_workaround(installer)
end
end
2
Answers
This is what worked for me using
first add this into podfile:
in between
and
Then delete podfile.lock.
Then do:
Then clean build folder under XCode -> Product -> Clean Build Folder.
Then run from within XCode.
Adding pods with modular headers (as Charlotte_Anne) do truly work but it is important NOT to use
use_frameworks!
Do not place use_frameworks! in podfile (although firebase installation instructions tell you to do so)
And it works!
Also encountered different problems after rebuilding (appregistry not found etc) which have many false solutions/answers and it still didnt work. What worked for me is to rebuild the project from git (git clone original project, modify podfile, pod install).