Homebrew 使用中的一些问题
2023-03-31
listxattr for destination failed: 2 遇到这个问题,首先要确定 CommandLineTools 是否安装了正确版本,查看 brew doctor 的提示。
如果安装正确,有可能是使用 OCLP 安装 Sequoia 导致,传递给 /usr/local/Homebrew/Library/Homebrew/cask/utils/copy-xattrs.swift 的参数不正确:
/Library/Developer/CommandLineTools/usr/bin/swift-frontend, -frontend, -interpret, /usr/local/Homebrew/Library/Homebrew/cask/utils/copy-xattrs.swift, -target, x86_64-apple-macosx15, -enable-objc-interop, -stack-check, -sdk, /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk, -color-diagnostics, -new-driver-path, /Library/Developer/CommandLineTools/usr/bin/swift-driver, -empty-abi-descriptor, -resource-dir, /Library/Developer/CommandLineTools/usr/lib/swift, -module-name, main, -disable-clang-spi, -target-sdk-version, 15.5, -target-sdk-name, macosx15.5, -external-plugin-path, /Library/Developer/Developer/usr/lib/swift/host/plugins#/Library/Developer/Developer/usr/bin/swift-plugin-server, -external-plugin-path, /Library/Developer/Developer/usr/local/lib/swift/host/plugins#/Library/Developer/Developer/usr/bin/swift-plugin-server, -in-process-plugin-server-path, /Library/Developer/CommandLineTools/usr/lib/swift/host/libSwiftInProcPluginServer.dylib, -plugin-path, /Library/Developer/CommandLineTools/usr/lib/swift/host/plugins, -plugin-path, /Library/Developer/CommandLineTools/usr/local/lib/swift/host/plugins, --, /usr/local/Caskroom/visual-studio-code/1.104.1/Visual Studio Code.app, /Applications/Visual Studio Code.app copy-xattrs.swift 期望两个参数,即源目录和目标目录,但最终传递的打印出来很长(参数可能与系统或 CLT 版本有关)。
…