使用 Xcode Cocoa 应用程序创建设备驱动程序

发布于 2024-12-09 17:06:50 字数 942 浏览 1 评论 0原文

    Hi Friends..
    I am try  to create a Device driver Application In X-Code, From This Link:- http://developer.apple.com/library/mac/#documentation/Darwin/Conceptual/KEXTConcept/KEXTConceptIOKit/iokit_tutorial.html I Got little bit Idea. Based on that I completed 

1)Create a New Project
    2)Edit the Information Property List
    3)Fill in the Header File
    4)Implement the Driver’s Entry Points.

    The Fifth Step is:  **Add Library Declarations**
    That mention like this .
    At this stage of creating your driver, you need to find out what those libraries are. The best way to do so is to run the kextlibs tool on your built kext and copy its output into your kext’s Info.plist file.

    But I a can't understand this lines,more over I can't fount $MyDriver/Build/Debug Folder. I opened Info.Plist file On Terminal I got Kext File . now I trying this in X-Code 4.

如果有人对此有想法,请提供一些提示.. 感谢您的重播

    Hi Friends..
    I am try  to create a Device driver Application In X-Code, From This Link:- http://developer.apple.com/library/mac/#documentation/Darwin/Conceptual/KEXTConcept/KEXTConceptIOKit/iokit_tutorial.html I Got little bit Idea. Based on that I completed 

1)Create a New Project
    2)Edit the Information Property List
    3)Fill in the Header File
    4)Implement the Driver’s Entry Points.

    The Fifth Step is:  **Add Library Declarations**
    That mention like this .
    At this stage of creating your driver, you need to find out what those libraries are. The best way to do so is to run the kextlibs tool on your built kext and copy its output into your kext’s Info.plist file.

    But I a can't understand this lines,more over I can't fount $MyDriver/Build/Debug Folder. I opened Info.Plist file On Terminal I got Kext File . now I trying this in X-Code 4.

If Any one having idea about this please give some tips..
Thanks For Your Replay

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

尐籹人 2024-12-16 17:06:50

请注意,只有在您实现了驱动程序的代码并且构建成功后,运行 kextlibs 才会起作用。一旦您完成了这一步,在 XCode 中:

  • 构建您的 kext
  • 在项目的文件树中
  • ,在“产品”下找到 kext ,打开一个终端窗口,输入 kextlibs 后跟一个空格。
  • 将 kext 从 XCode 拖放到终端窗口上,
  • 按 Enter 键,几秒钟后您应该会得到如下所示的输出:
    For all architectures:
        com.apple.iokit.IOStorageFamily = 1.6.3
        com.apple.kpi.bsd = 10.8
        com.apple.kpi.iokit = 10.8
        com.apple.kpi.libkern = 10.8
        com.apple.kpi.mach = 10.8

然后将这些库标识符和版本添加到 Info.plist 并重建。请注意,如果您希望 kext 在比您正在运行的系统更旧的 Mac OS X 版本上运行,则需要提供旧的库版本。 (最好是在最旧的受支持版本上运行 kextlibs)

Note that running kextlibs will only work once you have implemented the code for your driver, and it builds successfully. Once you have got that far, in XCode:

  • build your kext
  • in the project's file tree, find the kext under 'products'
  • open up a terminal window, type kextlibs followed by a space.
  • drag the kext from XCode and drop it onto the Terminal window
  • press Enter and after a few seconds you should get some output like the following:
    For all architectures:
        com.apple.iokit.IOStorageFamily = 1.6.3
        com.apple.kpi.bsd = 10.8
        com.apple.kpi.iokit = 10.8
        com.apple.kpi.libkern = 10.8
        com.apple.kpi.mach = 10.8

You then add those library identifiers and versions to the Info.plist and rebuild. Note that if you want the kext to work on older versions of Mac OS X than your running system, you'll need to supply older library versions. (ideally by running kextlibs on your oldest supported version)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文