Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/make CHECK_VALID_META is too agressive for CMD check.
details: https://anonhg.NetBSD.org/src/rev/e2dc773e2700
branches: trunk
changeset: 850363:e2dc773e2700
user: sjg <sjg%NetBSD.org@localhost>
date: Fri Apr 03 03:32:28 2020 +0000
description:
CHECK_VALID_META is too agressive for CMD check.
An empty CMD is perfectly valid.
So using CHECK_VALID_META results in too much rebuilding.
diffstat:
usr.bin/make/make.h | 6 +++++-
usr.bin/make/meta.c | 6 +++---
2 files changed, 8 insertions(+), 4 deletions(-)
diffs (38 lines):
diff -r caa7cb4932bc -r e2dc773e2700 usr.bin/make/make.h
--- a/usr.bin/make/make.h Fri Apr 03 03:05:39 2020 +0000
+++ b/usr.bin/make/make.h Fri Apr 03 03:32:28 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: make.h,v 1.105 2020/03/30 02:41:06 sjg Exp $ */
+/* $NetBSD: make.h,v 1.106 2020/04/03 03:32:28 sjg Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -532,4 +532,8 @@
#define KILLPG(pid, sig) killpg((pid), (sig))
#endif
+#ifndef __arraycount
+#define __arraycount(__x) (sizeof(__x) / sizeof(__x[0]))
+#endif
+
#endif /* _MAKE_H_ */
diff -r caa7cb4932bc -r e2dc773e2700 usr.bin/make/meta.c
--- a/usr.bin/make/meta.c Fri Apr 03 03:05:39 2020 +0000
+++ b/usr.bin/make/meta.c Fri Apr 03 03:32:28 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: meta.c,v 1.80 2020/03/18 23:53:02 sjg Exp $ */
+/* $NetBSD: meta.c,v 1.81 2020/04/03 03:32:28 sjg Exp $ */
/*
* Implement 'meta' mode.
@@ -1558,8 +1558,8 @@
if (buf[x - 1] == '\n')
buf[x - 1] = '\0';
}
- CHECK_VALID_META(p);
- if (!hasOODATE &&
+ if (p &&
+ !hasOODATE &&
!(gn->type & OP_NOMETA_CMP) &&
strcmp(p, cmd) != 0) {
if (DEBUG(META))
Home |
Main Index |
Thread Index |
Old Index