diff options
author | will <will@FreeBSD.org> | 2000-05-14 22:24:28 +0000 |
---|---|---|
committer | will <will@FreeBSD.org> | 2000-05-14 22:24:28 +0000 |
commit | 17b80016d68e8bbedfe3006cfd75f0b6ac6a269c (patch) | |
tree | 76dc0c22b1dbd7e5df425a7aadfd9413bf5ef6c1 /usr.bin/make | |
parent | b528d5f7f9ad0070de6da684f55f8b6d9504bec2 (diff) | |
download | FreeBSD-src-17b80016d68e8bbedfe3006cfd75f0b6ac6a269c.zip FreeBSD-src-17b80016d68e8bbedfe3006cfd75f0b6ac6a269c.tar.gz |
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>
Diffstat (limited to 'usr.bin/make')
-rw-r--r-- | usr.bin/make/compat.c | 2 | ||||
-rw-r--r-- | usr.bin/make/job.c | 2 | ||||
-rw-r--r-- | usr.bin/make/main.c | 3 | ||||
-rw-r--r-- | usr.bin/make/make.h | 1 |
4 files changed, 6 insertions, 2 deletions
diff --git a/usr.bin/make/compat.c b/usr.bin/make/compat.c index f9f7e79..4e14429 100644 --- a/usr.bin/make/compat.c +++ b/usr.bin/make/compat.c @@ -240,7 +240,7 @@ CompatRunCommand (cmdp, gnp) while ((*cmd == '@') || (*cmd == '-')) { if (*cmd == '@') { - silent = TRUE; + silent = DEBUG(LOUD) ? FALSE : TRUE; } else { errCheck = FALSE; } diff --git a/usr.bin/make/job.c b/usr.bin/make/job.c index 2fa1e0c..5e318e7 100644 --- a/usr.bin/make/job.c +++ b/usr.bin/make/job.c @@ -555,7 +555,7 @@ JobPrintCommand(cmdp, jobp) */ while (*cmd == '@' || *cmd == '-') { if (*cmd == '@') { - shutUp = TRUE; + shutUp = DEBUG(LOUD) ? FALSE : TRUE; } else { errOff = TRUE; } diff --git a/usr.bin/make/main.c b/usr.bin/make/main.c index ae3f820..3fe39ed 100644 --- a/usr.bin/make/main.c +++ b/usr.bin/make/main.c @@ -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; diff --git a/usr.bin/make/make.h b/usr.bin/make/make.h index 874eaa6..5d7eb3d 100644 --- a/usr.bin/make/make.h +++ b/usr.bin/make/make.h @@ -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 |