Xcode 3 -> 4 引发错误
我有一个基于 Carbon 的项目,可以在 XCode 3 上编译,但在 XCode 4 上失败。 它似乎找不到任何 Carbon 或 QT 函数,即使我已经包含了 和 #include
我收到很多这样的错误: 全局命名空间中没有名为“InitCursor”的成员
我尝试从 System/Library/Frameworks 文件夹中重新添加 Carbon.framework
I have a Carbon-based project that compiles on XCode 3, but fails on XCode 4.
It can't seem to find any Carbon or QT functions, even though I've included
and #include
I get lots of errors like this:
No member named 'InitCursor' in the global namespace
I tried re-adding in the Carbon.framework from the System/Library/Frameworks folder
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
InitCursor
函数,以及 QuickDraw 中的几乎所有其他内容在 Lion 中都被删除了。您将需要删除对所有已删除 API 的使用,并可能用更现代的替代品来替换其中的大部分。这是一项不简单的任务,但如果您想使用现代工具进行构建并针对 Mac OS X 的当前和未来版本,
那么这是必要的。 QuickDraw 已被弃用多年。
大部分 Carbon 仍然受支持,您应该会发现您没有收到有关这些 API 的错误。
你提到了Qt;我听说Qt现在有Cocoa版本了。
The
InitCursor
function, along with pretty much everything else in QuickDraw, was removed in Lion. You will need to remove your uses of all removed APIs, and probably replace most of them with more modern replacements.This is a non-trivial task, but it is necessary if you want to build with modern tools and target current and future versions of Mac OS X.
It's been a long time coming, too; QuickDraw has been deprecated for years.
Much of Carbon is still supported, and you should find that you are not getting errors about those APIs.
You mention Qt; I've heard that there is a Cocoa version of Qt now.