解决[IOS自动化]Xcode build时报错: Cannot link directly with dylib/framework
XcodeDriverAgent文件包,用于替换 /usr/local/lib/node_modules/appium/node_modules/appium-webdriveragent/WebDriverAgent.xcodeproj 文件
因为最新安装的appium这个文件夹是有问题的  npm install -g appium

error build: Cannot link directly with dylib/framework, your binary is not an allowed client of /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/PrivateFrameworks/XCTAutomationSupport.framework/XCTAutomationSupport for architecture arm64

解决办法如下:

1. 如果你的appium版本是最新的,直接跳到第3步。
否则卸载appium desktop(finder/application里找到app后直接拖到垃圾桶)
2. 下载安装最新的appium desktop: ​​​​​​​Releases · appium/WebDriverAgent · GitHub
3. finder/application里找到最新安装的appium app, 右击选择show package contents,定位到WebDriverAgent.xcodeproj所在路径:
参考:/Applications/Appium Server GUI.app/Contents/Resources/app/node_modules/appium/node_modules/appium-webdriveragent

4. 下载最新的WedDriverAgent:Releases · appium/WebDriverAgent · GitHub

已经上传到我的资源:https://download.csdn.net/download/qq_30273575/88889734
把下载好的WedDriverAgent里的全部内容替换到第三步的路径下(原内容可全部删除)

Logo

一站式 AI 云服务平台

更多推荐