Question regarding 2.6 kernel module makefiles
Hi all, I understand that for kernel 2.6 driver modules, the makefile is in the below format:
obj-m += hello.o
hello-objs:= hello1.o hello2.o
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean
This is a very simple makefile for 2 files kernel 2.6 modules existing in a single directory. So what if there is more files involved in different directories? Is there any way that I can make different object files inside different directories but generated the objects into one consolidated directory (eg ../obj/)?