On Sat, Jul 18, 2009 at 3:26 PM, Rishi Agrawal<rishi.b.agrawal@xxxxxxxxx> wrote: > Hello All, > > I have this particular directory Hierarchy > > foo > | > |__ include(directory) > | > |__kernel(directory) > | > |__user_space(directory) > > > Include directory has the header file which is required by both the kernel > space code and the user space code > > kernel has a character device driver, and a kern_make_file.mk to compile the > chardev > > user_space has the user space code, make_file and the configure script. > > I want to compile the chardev using the user space make file > > for this I added a line "include kern_make_file.mk" in the user space make > file > > but it is giving me the warnings and does not compile the user space code > > the warnings are : > > Makefile:16: warning: overriding commands for target `all' > ../kernel/make_kernel.mk:8: warning: ignoring old commands for target `all' Is there "all" target in your kernel makefile? seems there is a clash.... Perhaps you need to show us the content of your Makefile, both for user and kernel space code, to ease clarification... > Moreover I would like to know wether it is possible to compile the user > space code and kernel space code in one make file I think yes, you just need to be careful for things like : CFLAGS (likely it will be different for user and kernel code), include path and so on. So, to avoid headache, I think it's better to separate the Makefile.... -- regards, Mulyadi Santosa Freelance Linux trainer blog: the-hydra.blogspot.com -- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ