MAKE.1
上传用户:jnzhq888
上传日期:2007-01-18
资源大小:51694k
文件大小:2k
- .TH MAKE 1
- .SH NAME
- make - a program for maintaining large programs
- .SH SYNOPSIS
- fBmakefR [fB-f fIfilefR]fR [fB-iknpqrstfR] [fIoptionfR] ... [fItargetfR]fR
- .br
- .de FL
- .TP
- \fB\$1\fR
- \$2
- ..
- .de EX
- .TP 20
- \fB\$1\fR
- # \$2
- ..
- .SH OPTIONS
- .FL "-f" "Use fIfilefP as the makefile"
- .FL "-i" "Ignore status returned by commands"
- .FL "-k" "On error, skip to next command"
- .FL "-n" "Report, but do not execute"
- .FL "-p" "Print macros and targets"
- .FL "-q" "Question up-to-dateness of target"
- .FL "-r" "Rule inhibit; do not use default rules"
- .FL "-s" "Silent mode"
- .FL "-t" "Touch files instead of making them"
- .SH EXAMPLES
- .EX "make kernel" "Make fIkernelfP up to date"
- .EX "make -n -f mfile" "Tell what needs to be done"
- .SH DESCRIPTION
- .PP
- .I Make
- is a program that is normally used for developing large programs consisting of
- multiple files.
- It keeps track of which object files depend on which source and header files.
- When called, it does the minimum amount of recompilation to bring the target
- file up to date.
- .PP
- The file dependencies are expected in
- .I makefile
- or
- .I Makefile ,
- unless another file is specified with fB-ffR.
- .I Make
- has some default rules built in, for example, it knows how to make
- .I .s
- files
- from
- .I .c
- files.
- Here is a sample
- .I makefile .
- .PP
- .nf
- .ta 0.25i 1.0i 3.0i
- d=/user/ast # fIdfP is a macro
- program: head.s tail.s # fIprogramfR depends on these
- cc -o program head.s tail.s # tells how to make fIprogramfP
- echo Program done. # announce completion
- head.s: $d/def.h head.c # fIhead.sfP depends on these
- .br
- tail.s: $d/var.h tail.c # fItail.sfP depends on these
- .PP
- .fi
- A complete description of fImakefR would require too much space here.
- Many books on
- s-2UNIXs+2
- discuss
- .I make .
- Study the numerous fIMakefilesfR in the
- s-2MINIXs+2
- source tree for examples.
- .SH "SEE ALSO"
- .BR cc (1).