Add loud debugging facility (-dl option) which allows programmers/developers
to override @-prefixed commands in Makefiles. It is especially useful for debugging ports and/or complex Makefiles in such a manner that is basically a last resort, but is quite effective if the output is well-handled. I'll update the manpage after dinner. ;-) Better patch submitted by: steve Reviewed by: phk, steve, chuckr, obrien, Lyndon Nerenberg <lyndon@orthanc.ab.ca>
This commit is contained in:
parent
3c841ca5e3
commit
ea9b438956
@ -240,7 +240,7 @@ CompatRunCommand (cmdp, gnp)
|
||||
|
||||
while ((*cmd == '@') || (*cmd == '-')) {
|
||||
if (*cmd == '@') {
|
||||
silent = TRUE;
|
||||
silent = DEBUG(LOUD) ? FALSE : TRUE;
|
||||
} else {
|
||||
errCheck = FALSE;
|
||||
}
|
||||
|
@ -555,7 +555,7 @@ JobPrintCommand(cmdp, jobp)
|
||||
*/
|
||||
while (*cmd == '@' || *cmd == '-') {
|
||||
if (*cmd == '@') {
|
||||
shutUp = TRUE;
|
||||
shutUp = DEBUG(LOUD) ? FALSE : TRUE;
|
||||
} else {
|
||||
errOff = TRUE;
|
||||
}
|
||||
|
@ -262,6 +262,9 @@ rearg: while((c = getopt(argc, argv, OPTFLAGS)) != -1) {
|
||||
case 'j':
|
||||
debug |= DEBUG_JOB;
|
||||
break;
|
||||
case 'l':
|
||||
debug |= DEBUG_LOUD;
|
||||
break;
|
||||
case 'm':
|
||||
debug |= DEBUG_MAKE;
|
||||
break;
|
||||
|
@ -360,6 +360,7 @@ extern int debug;
|
||||
#define DEBUG_TARG 0x0100
|
||||
#define DEBUG_VAR 0x0200
|
||||
#define DEBUG_FOR 0x0400
|
||||
#define DEBUG_LOUD 0x0800
|
||||
|
||||
#ifdef __STDC__
|
||||
#define CONCAT(a,b) a##b
|
||||
|
Loading…
x
Reference in New Issue
Block a user