我发现,新(iOS16 Xcode 14)引入的单目标watchOS应用程序在我试图用XcodeGen实现它时不起作用。
我收到以下错误:
Prepare build
note: Building targets in dependency order
error: Multiple commands produce '/Users/martin/Library/Developer/Xcode/DerivedData/WatchTestGen-eqtccuxbzqoyuncgwdiwyamlfkpb/Build/Products/Debug-watchsimulator/WatchTestWatch Watch App.app/WatchTestWatch Watch App'
note: Target 'WatchTestWatch Watch App' (project 'WatchTestGen'): CopyAndPreserveArchs /Users/martin/Library/Developer/Xcode/DerivedData/WatchTestGen-eqtccuxbzqoyuncgwdiwyamlfkpb/Build/Products/Debug-watchsimulator/WatchTestWatch Watch App.app/WatchTestWatch Watch App
note: Target 'WatchTestWatch Watch App' (project 'WatchTestGen') has a command with output '/Users/martin/Library/Developer/Xcode/DerivedData/WatchTestGen-eqtccuxbzqoyuncgwdiwyamlfkpb/Build/Products/Debug-watchsimulator/WatchTestWatch Watch App.app/WatchTestWatch Watch App'
Multiple commands produce '/Users/martin/Library/Developer/Xcode/DerivedData/WatchTestGen-eqtccuxbzqoyuncgwdiwyamlfkpb/Build/Products/Debug-watchsimulator/WatchTestWatch Watch App.app/WatchTestWatch Watch App'
Build failed 2022-08-30 16:41 1.2 seconds
我创建了一个包含失败的project.yml
的样例项目,如下所示:https://github.com/MartinP7r/xcodegen-watch-sampleWatchTest.xcodeproj
工作正常,而生成的WatchTestGen.xcodeproj
则不正常。
这需要Xcode 14测试版。
我很乐意得到任何关于在我的项目或其他地方寻找错误的建议。🙏
1条答案
按热度按时间pkwftd7m1#
我能够让这个工作。看起来目标类型应该简单地是
application
,而不是application.watchapp2
。