【发布时间】:2014-02-25 04:29:04
【问题描述】:
我试图将我的驱动程序作为 Linux 内核的一部分。以下是Makefile。模块 rs_pci 依赖于 rs_9x。但是,内核会在构建 rs_9x 之前尝试构建 rs_pci,这会导致 rs_pci 的编译失败。我希望内核先编译 rs_9x,然后再编译 rs_pci。我该怎么做?
以下是我的 Makefile
rs_9x-y += rs_a.o
rs_9x-y += rs_b.o
rs_9x-y += rs_c.o
rs_pci-y += rs_pci.o rs_pci_ops.o
obj-$(CONFIG_RS) := rs_9x.o
obj-$(CONFIG_RS_PCI) := rs_pci.o
In the .config file, I have both options enabled as modules.
CONFIG_RS=m
CONFIG_RS_PCI=m
请帮帮我。
【问题讨论】:
-
如果您发布构建输出可能会更容易帮助您
-
为什么编译顺序很重要?这表明
rs_pci模块中存在错误。
标签: linux makefile linux-kernel linux-device-driver embedded-linux