“路径上的数据模型的编译失败”当编译Core Data模型时升级到狮子 [英] "Compilation failed for data model at path" when compiling Core Data model after upgrading to lion

查看:126
本文介绍了“路径上的数据模型的编译失败”当编译Core Data模型时升级到狮子的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

升级到lion后,以下错误会阻止成功编译核心数据模型:


core-data-model / MyModel。 xcdatamodeld:0:错误:编译
失败的路径
'资源/ MyModel.momd / MyModel.mom'数据模型


这是执行以下命令的结果:


/ Developer / usr / bin / momc core-data-model /MyModel.xcdatamodeld resources / MyModel.momd


请注意,此命令在独立于xcode的自定义构建脚本中执行,在升级到Lion之前,我已经读过模型编译错误(例如,请参阅问题,但详细的解决方案似乎不适用。 p>

任何人在升级到Lion之后手动调用模型编译时遇到问题?有任何想法吗?感谢。

解决方案

看起来像对象模型编译器现在期望目标路径是绝对的。这个工作方式:


/ Developer / usr / bin / momc core-data-model / MyModel.xcdatamodeld
/ Users / amos /projects/my-project/resources/MyModel.momd



After upgrading to lion, the following error prevents successful compilation of a core data model:

core-data-model/MyModel.xcdatamodeld:0: error: Compilation failed for data model at path 'resources/MyModel.momd/MyModel.mom'

This is the result of executing the following command:

/Developer/usr/bin/momc core-data-model/MyModel.xcdatamodeld resources/MyModel.momd

Note that this command is executing in a custom build script independently of xcode, and that it ran without problems before upgrading to Lion.

I've read of model compilation errors after upgrading to Lion (for instance see this question), but the solutions detailed there do not seem to apply.

Anyone else encounter problems manually invoking model compilation after upgrading to Lion? Any ideas? Thanks.

解决方案

Figured it out - it seems like the object model compiler now expects the destination path to be absolute. This works:

/Developer/usr/bin/momc core-data-model/MyModel.xcdatamodeld /Users/amos/projects/my-project/resources/MyModel.momd

这篇关于“路径上的数据模型的编译失败”当编译Core Data模型时升级到狮子的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆