将英文翻译成中文:
在更新我的应用程序到react-native v0.66.0之后,如果启用了hermes,我会不断收到此错误。我尝试删除DerivedData文件夹、podfile podfile.lock等,但没有帮助。
终端输出:
我想使用Flipper调试我的应用程序,并启用了Hermes,谢谢。
编辑:我可以从Xcode构建项目。
在更新我的应用程序到react-native v0.66.0之后,如果启用了hermes,我会不断收到此错误。我尝试删除DerivedData文件夹、podfile podfile.lock等,但没有帮助。
终端输出:
duplicate symbol 'folly::exception_wrapper::from_exception_ptr(std::exception_ptr&&)' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exception_wrapper::from_exception_ptr(std::exception_ptr const&)' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exception_wrapper::onNoExceptionError(char const*)' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exceptionStr(folly::exception_wrapper const&)' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exception_wrapper::uninit_' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exception_wrapper::ExceptionPtr::ops_' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
duplicate symbol 'folly::exception_wrapper::SharedPtr::ops_' in:
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/Flipper-Folly/libFlipper-Folly.a(ExceptionWrapper.o)
/Users/cuongtd/Library/Developer/Xcode/DerivedData/MyApp-ekbbcdnefrapxuertuowclstsjop/Build/Products/Debug-iphonesimulator/RCT-Folly/libRCT-Folly.a(ExceptionWrapper.o)
ld: 7 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ios/podfile
platform :ios, '11.0'
require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
target 'MyApp' do
config = use_native_modules!
use_react_native!(
:path => config[:reactNativePath],
# to enable hermes on iOS, change `false` to `true` and then install pods
:hermes_enabled => true
)
# Pods for MyApp
pod 'Firebase/Analytics'
pod 'AFNetworking', '~> 4.0', :source => 'https://github.com/ElfSundae/CocoaPods-Specs.git'
use_flipper!()
post_install do |installer|
react_native_post_install(installer)
__apply_Xcode_12_5_M1_post_install_workaround(installer)
installer.aggregate_targets.each do |aggregate_target|
aggregate_target.user_project.native_targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['LIBRARY_SEARCH_PATHS'] = ['$(SDKROOT)/usr/lib/swift', '$(inherited)']
end
end
aggregate_target.user_project.save
end
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '11.0'
end
end
`sed -i -e $'s/__IPHONE_10_0/__IPHONE_12_0/' #{installer.sandbox.root}/RCT-Folly/folly/portability/Time.h`
end
end
我想使用Flipper调试我的应用程序,并启用了Hermes,谢谢。
编辑:我可以从Xcode构建项目。