【问题标题】:Installed CocoaPods and Braintree now my project won't build安装 CocoaPods 和 Braintree 现在我的项目将无法构建
【发布时间】:2015-10-20 02:42:50
【问题描述】:
    Ld /Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Products/Debug-iphonesimulator/Podding.app/Podding normal x86_64
    cd /Users/admin/Development/zift/Podding
    export IPHONEOS_DEPLOYMENT_TARGET=8.4
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.4.sdk -L/Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Products/Debug-iphonesimulator -L/Users/admin/Development/zift/Podding/Pods/Braintree/Braintree/PayPal/mSDK -F/Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Products/Debug-iphonesimulator -filelist /Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Intermediates/Podding.build/Debug-iphonesimulator/Podding.build/Objects-normal/x86_64/Podding.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -objc_abi_version -Xlinker 2 -ObjC -lBraintree -lPayPalMobile-BT -lc++ -framework AVFoundation -framework Accelerate -framework AddressBook -framework AudioToolbox -framework CoreLocation -framework CoreMedia -framework MessageUI -framework MobileCoreServices -framework SystemConfiguration -framework UIKit -weak_framework PassKit -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator -Xlinker -add_ast_path -Xlinker /Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Intermediates/Podding.build/Debug-iphonesimulator/Podding.build/Objects-normal/x86_64/Podding.swiftmodule -mios-simulator-version-min=8.4 -lPods -Xlinker -dependency_info -Xlinker /Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Intermediates/Podding.build/Debug-iphonesimulator/Podding.build/Objects-normal/x86_64/Podding_dependency_info.dat -o /Users/admin/Library/Developer/Xcode/DerivedData/Podding-ffudeqoeybkocbevxvjrdlvtdswc/Build/Products/Debug-iphonesimulator/Podding.app/Podding

duplicate symbol _llvm.cmdline in:
    /Users/admin/Development/zift/Podding/Pods/Braintree/Braintree/PayPal/mSDK/libPayPalMobile-BT.a(PPZebraAnalyticsWidgetCategories.o)
    /Users/admin/Development/zift/Podding/Pods/Braintree/Braintree/PayPal/mSDK/libPayPalMobile-BT.a(PP2FAViewController.o)
duplicate symbol _llvm.embedded.module in:
    /Users/admin/Development/zift/Podding/Pods/Braintree/Braintree/PayPal/mSDK/libPayPalMobile-BT.a(PPZebraAnalyticsWidgetCategories.o)
    /Users/admin/Development/zift/Podding/Pods/Braintree/Braintree/PayPal/mSDK/libPayPalMobile-BT.a(PP2FAViewController.o)

最后 2 个“重复”行重复大约一百次,然后出现此错误

ld: 250 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

我完全按照 CocoaPods 网站的说明进行了安装。快速使用 Xcode6。我尝试了一个桥接头仍然没有成功。我尝试使用一个全新的项目以及相同的结果。我错过了什么?

【问题讨论】:

    标签: swift xcode6 cocoapods braintree


    【解决方案1】:

    我通过更改构建设置解决了这个问题。在 Xcode 中单击项目的根目录,然后查看 Build Settings。导航到链接并确保您显示“所有”设置(构建设置窗口的右上角区域)。然后从 'Other Linker Flags' 以及 $inherited 设置中删除 Obj C。我能够清洁和建造。希望这可以帮助。我在其他地方看到了这个答案,但我没有弄清楚,因为他们没有删除 $inherited 标志。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2023-03-30
      • 1970-01-01
      • 1970-01-01
      • 2022-10-03
      • 2019-09-29
      • 2016-08-22
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多