Changeset 3140 for trunk/src/kmk/make.1


Ignore:
Timestamp:
Mar 14, 2018, 10:28:10 PM (7 years ago)
Author:
bird
Message:

kmk: Merged in changes from GNU make 4.2.1 (2e55f5e4abdc0e38c1d64be703b446695e70b3b6 / https://git.savannah.gnu.org/git/make.git).

Location:
trunk/src/kmk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk

  • trunk/src/kmk/make.1

    r2591 r3140  
    1 .TH MAKE 1 "22 August 1989" "GNU" "LOCAL USER COMMANDS"
     1.TH MAKE 1 "28 February 2016" "GNU" "User Commands"
    22.SH NAME
    33make \- GNU make utility to maintain groups of programs
    44.SH SYNOPSIS
    5 .B "make "
    6 [
    7 .B \-f
    8 .I makefile
    9 ] [ options ] ... [ targets ] ...
    10 .SH WARNING
    11 This man page is an extract of the documentation of GNU
    12 .IR make .
    13 It is updated only occasionally, because the GNU project does not use nroff.
    14 For complete, current documentation, refer to the Info file
    15 .B make.info
    16 which is made from the Texinfo source file
    17 .BR make.texi .
     5.B make
     6[\fIOPTION\fR]... [\fITARGET\fR]...
    187.SH DESCRIPTION
    198.LP
    20 The purpose of the
     9The
    2110.I make
    22 utility is to determine automatically which
    23 pieces of a large program need to be recompiled, and issue the commands to
    24 recompile them.
    25 The manual describes the GNU implementation of
    26 .IR make ,
    27 which was written by Richard Stallman and Roland McGrath, and is
    28 currently maintained by Paul Smith.
    29 Our examples show C programs, since they are most common, but you can use
    30 .I make
    31 with any programming language whose compiler can be run with a
    32 shell command.
     11utility will determine automatically which pieces of a large program need to
     12be recompiled, and issue the commands to recompile them.  The manual describes
     13the GNU implementation of
     14.BR make ,
     15which was written by Richard Stallman and Roland McGrath, and is currently
     16maintained by Paul Smith.  Our examples show C programs, since they are very
     17common, but you can use
     18.B make
     19with any programming language whose compiler can be run with a shell command.
    3320In fact,
    34 .I make
    35 is not limited to programs.
    36 You can use it to describe any task where some files must be
    37 updated automatically from others whenever the others change.
     21.B make
     22is not limited to programs.  You can use it to describe any task where some
     23files must be updated automatically from others whenever the others change.
    3824.LP
    3925To prepare to use
    40 .IR make ,
     26.BR make ,
    4127you must write a file called the
    4228.I makefile
    43 that describes the relationships among files in your program, and the
    44 states the commands for updating each file.
    45 In a program, typically the executable file is updated from object
    46 files, which are in turn made by compiling source files.
     29that describes the relationships among files in your program, and the states
     30the commands for updating each file.  In a program, typically the executable
     31file is updated from object files, which are in turn made by compiling source
     32files.
    4733.LP
    4834Once a suitable makefile exists, each time you change some source files,
     
    5541suffices to perform all necessary recompilations.
    5642The
    57 .I make
    58 program uses the makefile data base and the last-modification times
    59 of the files to decide which of the files need to be updated.
    60 For each of those files, it issues the commands recorded in the data base.
    61 .LP
    62 .I make
     43.B make
     44program uses the makefile description and the last-modification times of the
     45files to decide which of the files need to be updated.  For each of those
     46files, it issues the commands recorded in the makefile.
     47.LP
     48.B make
    6349executes commands in the
    6450.I makefile
    65 to update
    66 one or more target
     51to update one or more target
    6752.IR names ,
    6853where
     
    7257.B \-f
    7358option is present,
    74 .I make
     59.B make
    7560will look for the makefiles
    7661.IR GNUmakefile ,
     
    9176The first name checked,
    9277.IR GNUmakefile ,
    93 is not recommended for most makefiles.
    94 You should use this name if you have a makefile that is specific to GNU
    95 .IR make ,
     78is not recommended for most makefiles.  You should use this name if you have a
     79makefile that is specific to GNU
     80.BR make ,
    9681and will not be understood by other versions of
    97 .IR make .
     82.BR make .
    9883If
    9984.I makefile
    100 is `\-', the standard input is read.
    101 .LP
    102 .I make
     85is '\-', the standard input is read.
     86.LP
     87.B make
    10388updates a target if it depends on prerequisite files
    10489that have been modified since the target was last modified,
     
    10792.sp 1
    10893.TP 0.5i
    109 .BR \-b , " \-m"
     94\fB\-b\fR, \fB\-m\fR
    11095These options are ignored for compatibility with other versions of
    111 .IR make .
    112 .TP 0.5i
    113 .BR \-B , " \-\-always\-make"
     96.BR make .
     97.TP 0.5i
     98\fB\-B\fR, \fB\-\-always\-make\fR
    11499Unconditionally make all targets.
    115100.TP 0.5i
     
    127112.BR "\-C " /etc.
    128113This is typically used with recursive invocations of
    129 .IR make .
     114.BR make .
    130115.TP 0.5i
    131116.B \-d
     
    135120which files actually need to be remade, which implicit rules are
    136121considered and which are applied---everything interesting about how
    137 .I make
     122.B make
    138123decides what to do.
    139124.TP 0.5i
     
    159144for details on invocation of commands, and
    160145.I m
    161 for debugging while remaking makefiles.
    162 .TP 0.5i
    163 .BR \-e , " \-\-environment\-overrides"
     146for debugging while remaking makefiles.  Use
     147.I n
     148to disable all previous debugging flags.
     149.TP 0.5i
     150\fB\-e\fR, \fB\-\-environment\-overrides\fR
    164151Give variables taken from the environment precedence
    165152over variables from makefiles.
     
    170157as a makefile.
    171158.TP 0.5i
    172 .BR \-i , " \-\-ignore\-errors"
     159\fB\-i\fR, \fB\-\-ignore\-errors\fR
    173160Ignore all errors in commands executed to remake files.
    174161.TP 0.5i
     
    182169searched in the order specified.
    183170Unlike the arguments to other flags of
    184 .IR make ,
     171.BR make ,
    185172directories given with
    186173.B \-I
     
    188175.BI \-I dir
    189176is allowed, as well as
    190 .BI "\-I " dir.
     177.B \-I
     178.IR dir .
    191179This syntax is allowed for compatibility with the C
    192180preprocessor's
     
    204192.B \-j
    205193option is given without an argument,
    206 .IR make
     194.BR make
    207195will not limit the number of jobs that can run simultaneously.
    208196.TP 0.5i
    209 .BR \-k , " \-\-keep\-going"
     197\fB\-k\fR, \fB\-\-keep\-going\fR
    210198Continue as much as possible after an error.
    211199While the target that failed, and those that depend on it, cannot
     
    220208With no argument, removes a previous load limit.
    221209.TP 0.5i
    222 .BR \-L , " \-\-check\-symlink\-times"
     210\fB\-L\fR, \fB\-\-check\-symlink\-times\fR
    223211Use the latest mtime between symlinks and target.
    224212.TP 0.5i
    225 .BR \-n , " \-\-just\-print" , " \-\-dry\-run" , " \-\-recon"
     213\fB\-n\fR, \fB\-\-just\-print\fR, \fB\-\-dry\-run\fR, \fB\-\-recon\fR
    226214Print the commands that would be executed, but do not execute them (except in
    227215certain circumstances).
     
    235223Essentially the file is treated as very old and its rules are ignored.
    236224.TP 0.5i
    237 .BR \-p , " \-\-print\-data\-base"
     225\fB\-O\fR[\fItype\fR], \fB\-\-output\-sync\fR[=\fItype\fR]
     226When running multiple jobs in parallel with \fB-j\fR, ensure the output of
     227each job is collected together rather than interspersed with output from
     228other jobs.  If
     229.I type
     230is not specified or is
     231.B target
     232the output from the entire recipe for each target is grouped together.  If
     233.I type
     234is
     235.B line
     236the output from each command line within a recipe is grouped together.
     237If
     238.I type
     239is
     240.B recurse
     241output from an entire recursive make is grouped together.  If
     242.I type
     243is
     244.B none
     245output synchronization is disabled.
     246.TP 0.5i
     247\fB\-p\fR, \fB\-\-print\-data\-base\fR
    238248Print the data base (rules and variable values) that results from
    239249reading the makefiles; then execute as usual or as otherwise
     
    243253switch (see below).
    244254To print the data base without trying to remake any files, use
    245 .B make
    246 .B \-p
    247 .BI \-f /dev/null.
    248 .TP 0.5i
    249 .BR \-q , " \-\-question"
     255.IR "make \-p \-f/dev/null" .
     256.TP 0.5i
     257\fB\-q\fR, \fB\-\-question\fR
    250258``Question mode''.
    251259Do not run any commands, or print anything; just return an exit status
     
    253261otherwise.
    254262.TP 0.5i
    255 .BR \-r , " \-\-no\-builtin\-rules"
     263\fB\-r\fR, \fB\-\-no\-builtin\-rules\fR
    256264Eliminate use of the built\-in implicit rules.
    257265Also clear out the default list of suffixes for suffix rules.
    258266.TP 0.5i
    259 .BR \-R , " \-\-no\-builtin\-variables"
     267\fB\-R\fR, \fB\-\-no\-builtin\-variables\fR
    260268Don't define any built\-in variables.
    261269.TP 0.5i
    262 .BR \-s , " \-\-silent" , " \-\-quiet"
     270\fB\-s\fR, \fB\-\-silent\fR, \fB\-\-quiet\fR
    263271Silent operation; do not print the commands as they are executed.
    264272.TP 0.5i
    265 .BR \-S , " \-\-no\-keep\-going" , " \-\-stop"
     273\fB\-S\fR, \fB\-\-no\-keep\-going\fR, \fB\-\-stop\fR
    266274Cancel the effect of the
    267275.B \-k
    268276option.
    269277This is never necessary except in a recursive
    270 .I make
     278.B make
    271279where
    272280.B \-k
    273281might be inherited from the top-level
    274 .I make
     282.B make
    275283via MAKEFLAGS or if you set
    276284.B \-k
    277285in MAKEFLAGS in your environment.
    278286.TP 0.5i
    279 .BR \-t , " \-\-touch"
     287\fB\-t\fR, \fB\-\-touch\fR
    280288Touch files (mark them up to date without really changing them)
    281289instead of running their commands.
    282290This is used to pretend that the commands were done, in order to fool
    283291future invocations of
    284 .IR make .
    285 .TP 0.5i
    286 .BR \-v , " \-\-version"
     292.BR make .
     293.TP 0.5i
     294.B \-\-trace
     295Information about the disposition of each target is printed (why the target is
     296being rebuilt and what commands are run to rebuild it).
     297.TP 0.5i
     298\fB\-v\fR, \fB\-\-version\fR
    287299Print the version of the
    288 .I make
     300.B make
    289301program plus a copyright, a list of authors and a notice that there
    290302is no warranty.
    291303.TP 0.5i
    292 .BR \-w , " \-\-print\-directory"
     304\fB\-w\fR, \fB\-\-print\-directory\fR
    293305Print a message containing the working directory
    294306before and after other processing.
    295307This may be useful for tracking down errors from complicated nests of
    296308recursive
    297 .I make
     309.B make
    298310commands.
    299311.TP 0.5i
     
    315327.I touch
    316328command on the given file before running
    317 .IR make ,
     329.BR make ,
    318330except that the modification time is changed only in the imagination of
    319 .IR make .
     331.BR make .
    320332.TP 0.5i
    321333.B \-\-warn\-undefined\-variables
     
    323335.SH "EXIT STATUS"
    324336GNU
    325 .I make
     337.B make
    326338exits with a status of zero if all makefiles were successfully parsed
    327339and no targets that were built failed.  A status of one will be returned
     
    329341.B \-q
    330342flag was used and
    331 .I make
     343.B make
    332344determines that a target needs to be rebuilt.  A status of two will be
    333345returned if any errors were encountered.
    334346.SH "SEE ALSO"
    335 .I "The GNU Make Manual"
     347The full documentation for
     348.B make
     349is maintained as a Texinfo manual.  If the
     350.B info
     351and
     352.B make
     353programs are properly installed at your site, the command
     354.IP
     355.B info make
     356.PP
     357should give you access to the complete manual.
    336358.SH BUGS
    337 See the chapter `Problems and Bugs' in
     359See the chapter ``Problems and Bugs'' in
    338360.IR "The GNU Make Manual" .
    339361.SH AUTHOR
    340362This manual page contributed by Dennis Morse of Stanford University.
    341 It has been reworked by Roland McGrath.  Further updates contributed by
    342 Mike Frysinger.
     363Further updates contributed by Mike Frysinger.  It has been reworked by Roland
     364McGrath.  Maintained by Paul Smith.
    343365.SH "COPYRIGHT"
    344 Copyright (C) 1992, 1993, 1996, 1999, 2007 Free Software Foundation, Inc.
    345 This file is part of GNU
    346 .IR make .
     366Copyright \(co 1992-1993, 1996-2016 Free Software Foundation, Inc.
     367This file is part of
     368.IR "GNU make" .
    347369.LP
    348370GNU Make is free software; you can redistribute it and/or modify it under the
Note: See TracChangeset for help on using the changeset viewer.