.ko文件是如何建成 [英] How .ko file is built

查看:455
本文介绍了.ko文件是如何建成的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想我端口自己的驱动程序到的的Beagle Board XM臂的cortex-A8 的。虽然移植我试图找出如何在 .ko 文件实际上构建。在我们的的Makefile :我们只有一个命令建立一个的.o 文件。

I am trying to port my own driver to a Beagle board xm arm-cortex-A8. While porting I am trying to figuring out how the .ko file actually builds. In our Makefile we only have a command to build an.o file.

.ko 文件是如何建成的?

使用Linux的 2.6.38.8 内核并尝试配置我的司机对我的内核。

Using linux-2.6.38.8 kernel and trying to configure my driver for my kernel.

推荐答案

内核<一个href=\"https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/tree/Documentation/kbuild/modules.txt\"相对=nofollow> 有很多关于如何建立一个外部模块的kbuild模块文件。如果你有 Raspberian 或其他一些嵌入ARM Linux,你将需要获得源代码包你的内核。这个过程会有所不同基于该模块是否要编译在同一台机器上运行,或者如果你正在试图建立它的PC(希望在Linux电脑)。

The kernel kbuild module document has lots of information on how to build an external module. If you have Raspberian or some other embedded ARM Linux, you will need to get the source package for your kernel. The process differs based on whether you are compiling on the same machine the module will run on, or if you are trying to build it on a PC (hopefully a Linux PC).

请注明您需要的方式来建立,如果在的kbuild模块文档不解释的东西不够好。

Please specify which way you need to build, if the kbuild module document doesn't explain things well enough.

这篇关于.ko文件是如何建成的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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