To prepare to use make, you must write a file called the makefile that describes the relationships among files in your program, and the states the commands for updating each file. In a program, typically the executable file is updated from object files, which are in turn made by compiling source files.
How do I run a makefile in Linux?
make: *** No targets specified and no makefile found. Stop.
…
Linux: How to Run make.
| Option | Meaning |
|---|---|
| -e | Allows environment variables to override definitions of similarly named variables in the makefile. |
| -f FILE | Reads FILE as the makefile. |
| -h | Displays the list of make options. |
| -i | Ignores all errors in commands executed when building a target. |
What is the purpose of make command?
The makefile is read by the make command, which determines the target file or files that are to be made and then compares the dates and times of the source files to decide which rules need to be invoked to construct the target. Often, other intermediate targets have to be created before the final target can be made.