【问题标题】:Duplicated symbols with static library(.a) and dynamic library (.dylib)具有静态库 (.a) 和动态库 (.dylib) 的重复符号
【发布时间】:2013-08-19 23:00:30
【问题描述】:

在我的 iOS 项目中,正在使用库 libbaidumapapi.alibPayPalMPL.a

项目可以正确构建,但它会在运行时发出异常信号。

在调试问题的时候,发现是因为库libPayPalMPL.a调用了库libbaidumapapi.a里面的XMLFreeDoc函数,但是应该是调用了xml2动态库里面的XMLFreeDoc函数。

我没有这两个库的源代码。当我检查libbaidumapapi.a 时,我发现它与minixml.odeflate.o 一起使用XMLFreeDoc 归档,并且放气可能与libPayPalMPL.a 冲突。

libPayPalMPL.a 库依赖于两个动态库:xml2zlib

我可以解决这个崩溃问题吗?我在libbaidumapapi.a 之前已经使用了force_load

以下是链接命令,以备不时之需。

Ld /Users/tony/Library/Developer/Xcode/DerivedData/travel-aaytjupqtzenxvaepekwcapqqzpv/Build/Products/Debug-iphonesimulator/travel.app/travel normal i386
cd /Users/tony/Documents/temp/mapapp
setenv IPHONEOS_DEPLOYMENT_TARGET 6.1
setenv 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 i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator6.1.sdk -L/Users/tony/Library/Developer/Xcode/DerivedData/itravel-aaytjupqtzenxvaepekwcapqqzpv/Build/Products/Debug-iphonesimulator -L/Users/tony/Documents/temp/mapapp/libs/Release-iphonesimulator -L/Users/tony/Documents/temp/mapapp/libs/Release-iphoneos -L/Users/tony/Documents/temp/mapapp/libs/Release-iphonesimulator -L/Users/tony/Documents/temp/mapapp/libs -L/Users/tony/Documents/temp/mapapp/libWeiboSDK -L/Users/tony/Documents/temp/mapapp/Library -F/Users/tony/Library/Developer/Xcode/DerivedData/travel-aaytjupqtzenxvaepekwcapqqzpv/Build/Products/Debug-iphonesimulator -filelist /Users/tony/Library/Developer/Xcode/DerivedData/travel-aaytjupqtzenxvaepekwcapqqzpv/Build/Intermediates/travel.build/Debug-iphonesimulator/travel.build/Objects-normal/i386/travel.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -force_load /Users/tony/Documents/temp/mapapp/libs/Release-iphonesimulator/libbaidumapapi.a -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=6.1 -lz -lxml2 -framework Security -framework SystemConfiguration -framework OpenGLES -framework QuartzCore -lc++ -lopts -framework MapKit -framework CoreLocation -framework UIKit -framework Foundation -framework CoreGraphics -lPayPalMPL -lWeiboSDK -o /Users/tony/Library/Developer/Xcode/DerivedData/travel-aaytjupqtzenxvaepekwcapqqzpv/Build/Products/Debug-iphonesimulator/travel.app/travel*

【问题讨论】:

    标签: ios paypal


    【解决方案1】:

    MPL 已被弃用。相反,建议您使用 iOS SDK:https://github.com/paypal/PayPal-iOS-SDK

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2023-03-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-12-12
    • 2014-11-23
    • 2021-09-02
    相关资源
    最近更新 更多