home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Atari / Gnu / gmake362.zoo / make.txt < prev    next >
Text File  |  1991-08-05  |  8KB  |  265 lines

  1.  
  2.  
  3.  
  4. MAKE(1L)         Printed August 3, 1991         MAKE(1L)
  5.  
  6.  
  7.  
  8. NAME
  9.      make - GNU    make utility to    maintain groups    of programs
  10.  
  11. SYNOPSIS
  12.      make [ -f makefile    ] [ option ] ...  target ...
  13.  
  14. WARNING
  15.      This man paage is an extract of the documentation of GNU
  16.      make . It is updated only occasionally, because the GNU
  17.      project does not use nroff.  For complete,    current
  18.      documentation, refer to the Info file make    or the DVI file
  19.      make.dvi which are    made from the Texinfo source file
  20.      make.texinfo.
  21.  
  22. DESCRIPTION
  23.      The purpose of the    make utility is    to determine
  24.      automatically which pieces    of a large program need    to be
  25.      recompiled, and issue the commands    to recompile them.  This
  26.      manual describes the GNU implementation of    make, which was
  27.      written by    Richard    Stallman and Roland McGrath.  Our
  28.      examples show C programs, since they are most common, but
  29.      you can use make with any programming language whose
  30.      compiler can be run with a    shell command.    In fact, make is
  31.      not limited to programs.  You can use it to describe any
  32.      task where    some files must    be updated automatically from
  33.      others whenever the others    change.
  34.  
  35.      To    prepare    to use make, you must write a file called the
  36.      makefile that describes the relationships among files in
  37.      your program, and the states the commands for updating each
  38.      file.  In a program, typically the    executable file    is
  39.      updated from object files,    which are in turn made by
  40.      compiling source files.
  41.  
  42.      Once a suitable makefile exists, each time    you change some
  43.      source files, this    simple shell command:
  44.  
  45.       make
  46.  
  47.      suffices to perform all necessary recompilations.    The make
  48.      program uses the makefile data base and the last-
  49.      modification times    of the files to    decide which of    the files
  50.      need to be    updated.  For each of those files, it issues the
  51.      commands recorded in the data base.
  52.  
  53.      make executes commands in the makefile to update one or more
  54.      target names, where name is typically a program.  If no -f
  55.      option is present,    make will look for the makefiles
  56.      GNUmakefile, makefile, and    Makefile, in that order.
  57.  
  58.      Normally you should call your makefile either makefile or
  59.      Makefile.    (We recommend Makefile because it appears
  60.  
  61.  
  62.  
  63. Page 1                     TARGON /35     Operating System
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. MAKE(1L)         Printed August 3, 1991         MAKE(1L)
  71.  
  72.  
  73.  
  74.      prominently near the beginning of a directory listing, right
  75.      near other    important files    such as    README.)  The first name
  76.      checked, GNUmakefile, is not recommended for most makefiles.
  77.      You should    use this name if you have a makefile that is
  78.      specific to GNU make, and will not    be understood by other
  79.      versions of make.    If makefile is `-', the    standard input is
  80.      read.
  81.  
  82.      make updates a target if it depends on prerequisite files
  83.      that have been modified since the target was last modified,
  84.      or    if the target does not exist.
  85.  
  86. OPTIONS
  87.      -b
  88.  
  89.      -m      These    options    are ignored for    compatibility with other
  90.       versions of make.
  91.  
  92.      -C    dir
  93.       Change to directory dir before reading the makefiles or
  94.       doing    anything else.    If multiple -C options are
  95.       specified, each is interpreted relative to the previous
  96.       one:    -C / -C    etc is equivalent to -C    /etc.  This is
  97.       typically used with recursive    invocations of make.
  98.  
  99.      -d      Print    debugging information in addition to normal
  100.       processing.  The debugging information says which files
  101.       are being considered for remaking, which file-times are
  102.       being    compared and with what results,    which files
  103.       actually need    to be remade, which implicit rules are
  104.       considered and which are applied---everything
  105.       interesting about how    make decides what to do.
  106.  
  107.      -f    file
  108.       Use file as a    makefile.
  109.  
  110.      -i      Ignore all errors in commands    executed to remake files.
  111.  
  112.      -I    dir
  113.       Specifies a directory    dir to search for included
  114.       makefiles.  If several -I options are    used to    specify
  115.       several directories, the directories are searched in
  116.       the order specified.    Unlike the arguments to    other
  117.       flags    of make, directories given with    -I flags may come
  118.       directly after the flag:  -Idir is allowed, as well as
  119.       -I dir.  This    syntax is allowed for compatibility with
  120.       the C    preprocessor's -I flag.
  121.  
  122.      -j    jobs
  123.       Specifies the    number of jobs (commands) to run
  124.       simultaneously.  If there is more than one -j    option,
  125.       the last one is effective.  If the -j    option is given
  126.  
  127.  
  128.  
  129. Page 2                     TARGON /35     Operating System
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. MAKE(1L)         Printed August 3, 1991         MAKE(1L)
  137.  
  138.  
  139.  
  140.       without an argument, make will not limit the number of
  141.       jobs that can    run simultaneously.
  142.  
  143.      -k      Continue as much as possible after an    error.    While the
  144.       target that failed, and those    that depend on it, cannot
  145.       be remade, the other dependencies of these targets can
  146.       be processed all the same.
  147.  
  148.      -l
  149.  
  150.      -l    load
  151.       Specifies that no new    jobs (commands)    should be started
  152.       if there are others jobs running and the load    average
  153.       is at    least load (a floating-point number).  With no
  154.       argument, removes a previous load limit.
  155.  
  156.      -n      Print    the commands that would    be executed, but do not
  157.       execute them.
  158.  
  159.      -o    file
  160.       Do not remake    the file file even if it is older than
  161.       its dependencies, and    do not remake anything on account
  162.       of changes in    file.  Essentially the file is treated as
  163.       very old and its rules are ignored.
  164.  
  165.      -p      Print    the data base (rules and variable values) that
  166.       results from reading the makefiles; then execute as
  167.       usual    or as otherwise    specified.  This also prints the
  168.       version information given by the -v switch (see below).
  169.       To print the data base without trying    to remake any
  170.       files, use make -p -f/dev/null.
  171.  
  172.      -q      ``Question mode''.  Do not run any commands, or print
  173.       anything; just return    an exit    status that is zero if
  174.       the specified    targets    are already up to date,    nonzero
  175.       otherwise.
  176.  
  177.      -r      Eliminate use    of the built-in    implicit rules.     Also
  178.       clear    out the    default    list of    suffixes for suffix
  179.       rules.
  180.  
  181.      -s      Silent operation; do not print the commands as they are
  182.       executed.
  183.  
  184.      -S      Cancel the effect of the -k option.  This is never
  185.       necessary except in a    recursive make where -k    might be
  186.       inherited from the top-level make via    MAKEFLAGS or if
  187.       you set -k in    MAKEFLAGS in your environment.
  188.  
  189.      -t      Touch    files (mark them up to date without really
  190.       changing them) instead of running their commands.  This
  191.       is used to pretend that the commands were done, in
  192.  
  193.  
  194.  
  195. Page 3                     TARGON /35     Operating System
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. MAKE(1L)         Printed August 3, 1991         MAKE(1L)
  203.  
  204.  
  205.  
  206.       order    to fool    future invocations of make.
  207.  
  208.      -v      Print    the version of the make    program    plus a copyright,
  209.       a list of authors and    a notice that there is no
  210.       warranty.  After this    information is printed,
  211.       processing continues normally.  To get this information
  212.       without doing    anything else, use make    -v -f/dev/null.
  213.  
  214.      -w      Print    a message containing the working directory before
  215.       and after before and after other processing.    This may
  216.       be useful for    tracking down errors from complicated
  217.       nests    of recursive make commands.
  218.  
  219.      -W    file
  220.       Pretend that the target file has just    been modified.
  221.       When used with the -n    flag, this shows you what would
  222.       happen if you    were to    modify that file.  Without -n, it
  223.       is almost the    same as    running    a touch    command    on the
  224.       given    file before running make, except that the
  225.       modification time is changed only in the imagination of
  226.       make.
  227.  
  228. SEE ALSO
  229.      /usr/local/doc/gnumake.dvi
  230.              The GNU Make Manual
  231.  
  232. BUGS
  233.      See the chapter `Problems and Bugs' in The    GNU Make Manual    .
  234.  
  235. AUTHOR
  236.      This manual page contributed by Dennis Morse of Stanford
  237.      University.  It has been reworked by Roland McGrath.
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261. Page 4                     TARGON /35     Operating System
  262.  
  263.  
  264.  
  265.