-
July 10th, 2017, 11:17 AM
#1
I need help with makefiles
Can someone please explain the concept behind the make process for Linux kernels.
Many distros - among them Redhat, Fatdog, etc.., use a "tree" structure with a Makefile and some KConfig (for kernel config I assume) in each directory.
This means that if I navigate to a directory and type make somedriver.ko, it errors with:
make: *** No rule to make target 'somedriver.ko'. Stop.
My driver will have about a half dozen or so .c files and a .asm file. It's not large. I would like though, to simply use
the existing make process. How do the rules for the build get in there? What process did the designer of the
make process envision, and is this documented somewhere?
Thank you.
-
July 10th, 2017, 11:54 AM
#2
Re: I need help with makefiles
I have now found the build flags in the directory a few above my drivers, in the 3.10.0-327.el7.x86_64 direcdtory.
It starts with VERSION = 3
PATCHLEVE = 10, etc..
So perhaps I just need to navigate to that directory and run the make.
-
July 10th, 2017, 12:03 PM
#3
Re: I need help with makefiles
If I run the command make help, it gives a recipe for how to navigate to a directory in the make, as in make dir/....
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|