
- replace repetition of linking
gcc *.c -o prog- quick compiling time (prev way is 1 for everytime so that’s O(n))
Functions of makefile
- build
- link
build
write inside makefile
|
|
terminal make reports no change when changes occur
update/rebuild
|
|
parallel option
adding -jn n=num of buildtasks
eg make -j4 #means compile 4 tasks
makefile can be used as parallel execution as well
Common error
Makefile:2: *** missing separator. Stop.
solution is to check for tabs




近期评论