Go to the first, previous, next, last section, table of contents.

Errors Generated by Make

Here is a list of the most common errors you might see generated by make, and some information about what they mean and how to fix them.

Sometimes make errors are not fatal, especially in the presence of a - prefix on a command script line, or the -k command line option. Errors that are fatal are prefixed with the string ***.

Error messages are all either prefixed with the name of the program (usually `make'), or, if the error is found in a makefile, the name of the file and linenumber containing the problem.

In the table below, these common prefixes are left off.

`[foo] Error NN'
`[foo] signal description'
These errors are not really make errors at all. They mean that a program that make invoked as part of a command script returned a non-0 error code (`Error NN'), which make interprets as failure, or it exited in some other abnormal fashion (with a signal of some type). If no *** is attached to the message, then the subprocess failed but the rule in the makefile was prefixed with the - special character, so make ignored the error.
`missing separator. Stop.'
This is make's generic "Huh?" error message. It means that make was completely unsuccessful at parsing this line of your makefile. It basically means "syntax error". One of the most common reasons for this message is that you (or perhaps your oh-so-helpful editor, as is the case with many MS-Windows editors) have attempted to indent your command scripts with spaces instead of a TAB character. Remember that every line in the command script must begin with a TAB character. Eight spaces do not count.
`commands commence before first target. Stop.'
`missing rule before commands. Stop.'
This means the first thing in the makefile seems to be part of a command script: it begins with a TAB character and doesn't appear to be a legal make command (such as a variable assignment). Command scripts must always be associated with a target. The second form is generated if the line has a semicolon as the first non-whitespace character; make interprets this to mean you left out the "target: dependency" section of a rule.
`No rule to make target `xxx'.'
`No rule to make target `xxx', needed by `yyy'.'
This means that make decided it needed to build a target, but then couldn't find any instructions in the makefile on how to do that, either explicit or implicit (including in the default rules database). If you want that file to be built, you will need to add a rule to your makefile describing how that target can be built. Other possible sources of this problem are typos in the makefile (if that filename is wrong) or a corrupted source tree (if that file is not supposed to be built, but rather only a dependency).
`No targets specified and no makefile found. Stop.'
`No targets. Stop.'
The former means that you didn't provide any targets to be built on the command line, and make couldn't find any makefiles to read in. The latter means that some makefile was found, but it didn't contain any default target and none was given on the command line. GNU make has nothing to do in these situations.
`Makefile `xxx' was not found.'
`Included makefile `xxx' was not found.'
A makefile specified on the command line (first form) or included (second form) was not found.
`warning: overriding commands for target `xxx''
`warning: ignoring old commands for target `xxx''
GNU make allows commands to be specified only once per target (except for double-colon rules). If you give commands for a target which already has been defined to have commands, this warning is issued and the second set of commands will overwrite the first set.
`Circular xxx <- yyy dependency dropped.'
This means that make detected a loop in the dependency graph: after tracing the dependency yyy of target xxx, and its dependencies, etc., one of them depended on xxx again.
`Recursive variable `xxx' references itself (eventually). Stop.'
This means you've defined a normal (recursive) make variable xxx that, when its expanded, will refer to itself (xxx). This is not allowed; either use simply-expanded variables (:=) or use the append operator (+=).
`Unterminated variable reference. Stop.'
This means you forgot to provide the proper closing parenthesis or brace in your variable or function reference.
`insufficient arguments to function `xxx'. Stop.'
This means you haven't provided the requisite number of arguments for this function. See the documentation of the function for a description of its arguments.
`missing target pattern. Stop.'
`multiple target patterns. Stop.'
`target pattern contains no `%'. Stop.'
These are generated for malformed static pattern rules. The first means there's no pattern in the target section of the rule, the second means there are multiple patterns in the target section, and the third means the target doesn't contain a pattern character (%).

Go to the first, previous, next, last section, table of contents.