好的,所以我正在解决一个关于可可荚架构中重复符号的问题。在接受的解决方案中安装了带有post_install
的pod之后,我构建了xcworkspace项目,并遇到以下错误:
文件位置和错误的屏幕截图。
错误为:预处理器表达式中应为行尾
在行上:#if HAVE_FULLFSYNC
在方法中:SyncFd(int fd, const std::string& fd_path)
文件的位置为:Pods/Pods/leveldb-library/env_posix.cc
我添加的引发这一系列问题的Pod是"CodableFirebase"。
这是我的播客文件:
platform :ios, '13.2'
post_install do |installer_representation|
installer_representation.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] = '$(inherited), PodsDummy_Pods=SomeOtherNamePodsDummy_Pods'
end
end
end
target 'ShoeSwiperMenus' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for ShoeSwiperMenus
# add the Firebase pod for Google Analytics
pod 'Firebase/Analytics'
# add pods for any other desired Firebase products
# https://firebase.google.com/docs/ios/setup#available-pods
pod 'Firebase/Core'
pod 'Firebase/Firestore'
pod ‘FirebaseUI/Auth'
pod 'FirebaseUI/Google'
pod 'FirebaseUI'
pod 'MaterialComponents/Buttons'
pod 'MaterialComponents/Buttons+Theming'
# pod 'MaterialComponents/schemes/Color'
pod 'Shuffle-iOS'
pod 'JGProgressHUD'
pod 'LBTATools'
pod 'CodableFirebase'
end
删除post_install
块时,我回溯到我的原始错误,即:
ld:202体系结构x86_64的重复符号。
clang:error:链接器命令失败,退出代码为1(使用-v查看调用(
我在这里真的是力不从心。。。我甚至不知道如何开始解决这个问题(谷歌上没有(。请帮忙!
我刚刚将您的Podfile添加到一个空项目中,得到了相同的错误,然后删除了post_install
块,并且能够在没有错误的情况下进行构建。
因此,请删除post_install
块。无论它应该解决什么问题,它都会产生这个问题。
此外,我建议将inhibit_all_warnings!
添加到Podfile中。