gpt4 book ai didi

ios - WebdriverAgent : linker command failed with exit code 1 (use -v to see invocation)

转载 作者:行者123 更新时间:2023-12-01 16:22:26 24 4
gpt4 key购买 nike

我正在尝试将 webdriveragent 构建到 iOS 真实设备上。直到昨天它工作正常。从那以后,我没有对盒子进行任何更新。我在编译时看到以下错误:

\Ld/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos/WebDriverAgentLib.framework/WebDriverAgentLib 正常 arm64(目标:WebDriverAgentLib)
cd/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent
导出 IPHONEOS_DEPLOYMENT_TARGET=11.3
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch arm64 -dynamiclib -isysroot/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.0.sdk -L/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos -F/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos - F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Frameworks -F/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/Carthage/Build/iOS -F/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/Carthage/Build/Mac -filelist/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Intermediates.noindex/WebDriverAgent.build/Debug-iphoneos/WebDriverAgentLib.build/Objects-normal/arm64/WebDriverAgentLib.LinkFileList -install_name @rpath/WebDriverAgentLib.framework/WebDriverAgentLib -Xlin ker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -miphoneos-version-min=11.3 -dead_strip -Xlinker -object_path_lto -Xlinker/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Intermediates.noindex/WebDriverAgent.build/Debug-iphoneos/WebDriverAgentLib.build/Objects-normal/arm64/WebDriverAgentLib_lto.o -Xlinker -export_dynamic -Xlinker -no_deduplicate -fobjc-arc -fobjc-link-runtime -lxml2 -framework RoutingHTTPServer -framework YYCache -compatibility_version 1 -current_version 1 -Xlinker -dependency_info -Xlinker/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Intermediates.noindex/WebDriverAgent.build/Debug-iphoneos/WebDriverAgentLib.build/Objects-normal/arm64/WebDriverAgentLib_dependency_info.dat -o/Users/qaautomation/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos/WebDriverAgentLib.framework/WebDriverAgentLib

架构 arm64 的 undefined symbol :
“_OBJC_CLASS_$_XCElementSnapshot”,引用自:
l_OBJC_$_CATEGORY_XCElementSnapshot_$_FBIsVisible 在 XCUIElement+FBIsVisible.o
XCUIElement+FBUID.o 中的 l_OBJC_$_CATEGORY_XCElementSnapshot_$_FBUID
XCUIElement+FBWebDriverAttributes.o 中的 l_OBJC_$_CATEGORY_XCElementSnapshot_$_WebDriverAttributes
XCUIElement+FBWebDriverAttributes.o 中的 objc-class-ref
XCUIElement+FBUtilities.o 中的 objc-class-ref
XCUIElement+FBAccessibility.o 中的 l_OBJC_$_CATEGORY_XCElementSnapshot_$_FBAccessibility
l_OBJC_$_CATEGORY_XCElementSnapshot_$_FBScrolling in XCUIElement+FBScrolling.o
...
ld:未找到架构 arm64 的符号
clang:错误:链接器命令失败,退出代码为 1(使用 -v 查看调用)


我正在使用最新的 Xcode 和 appium
有人可以帮我解决这个问题吗?

最佳答案

在 WebDriverAgentLib 目标的其他链接器标志中添加 -Wl,-U,"_OBJC_CLASS_$_XCElementSnapshot"。

关于ios - WebdriverAgent : linker command failed with exit code 1 (use -v to see invocation),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52504743/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com