摘要:
在对makefile进行了部分学习后,感觉到还是多看看简短的例子比较好。发现下面这个网站讲得很好:http://www.cs.colby.edu/maxwell/courses/tutorials/maketutor/hellomake.c:#include int main() { // call a function in another file myPrintHelloMake(); return(0);}hellofunc.c:#include #include void myPrintHelloMake(void) { printf("Hello makefiles!\n 阅读全文
摘要:
继续翻译3.6 Overriding Part of Another Makefile ======================================= Sometimes it is useful to have a makefile that is mostly just like another makefile. You can often use the `include' directive to include one in ... 阅读全文
摘要:
继续翻译 However, on occasion you might actually wish to prevent updating of even the makefiles. You can do this by specifying the makefiles asgoals in the command line as well as specifying them as makefiles. When the makefile name is specified explicitly as a goal, the options `-t' and so on do ap 阅读全文
摘要:
继续翻译 When you use the `-t' or `--touch' option (*note Instead of Executing Recipes: Instead of Execution.), you would not want to use anout-of-date makefile to decide which targets to touch. So the `-t' option has no effect on updating makefiles; they are really updated even if `-t' 阅读全文
摘要:
继续翻译 If you do not specify any makefiles to be read with `-f' or `--file'options, `make' will try the default makefile names; *note What Name to Give Your Makefile: Makefile Names. Unlike makefiles explicitly requested with `-f' or `--file' options, `make' is not certain that 阅读全文
摘要:
继续翻译 If you know that one or more of your makefiles cannot be remade and you want to keep `make' from performing an implicit rule search onthem, perhaps for efficiency reasons, you can use any normal method of preventing implicit rule lookup to do so. For example, you can write an explicit rule 阅读全文
摘要:
继续翻译3.5 How Makefiles Are Remade ============================ Sometimes makefiles can be remade from other files, such as RCS or SCCS files. If a makefile can be remade from other files, you probably want `make' to get an up-to-d... 阅读全文
摘要:
继续翻译3.4 The Variable `MAKEFILES' ============================ If the environment variable `MAKEFILES' is defined, `make' considers its value as a list of names (separated by whitespace) of additionalmakefiles to be rea... 阅读全文
摘要:
继续翻译 For compatibility with some other `make' implementations, `sinclude'is another name for `-include'. ---------- Footnotes ---------- (1) GNU Make compiled for MS-DOS and MS-Windo... 阅读全文
摘要:
继续翻译 If you want `make' to simply ignore a makefile which does not exist or cannot be remade, with no error message, use the `-include' directive instead of `include', like this: -include FILENAMES... ... 阅读全文