Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern Add a /* LINTSTUB: include <foo.h> */ mechanism.
details: https://anonhg.NetBSD.org/src/rev/e6c148dd76f4
branches: trunk
changeset: 509964:e6c148dd76f4
user: perry <perry%NetBSD.org@localhost>
date: Wed May 16 04:17:04 2001 +0000
description:
Add a /* LINTSTUB: include <foo.h> */ mechanism.
diffstat:
sys/kern/genlintstub.awk | 18 +++++++++++++-----
1 files changed, 13 insertions(+), 5 deletions(-)
diffs (46 lines):
diff -r 6f96975d177f -r e6c148dd76f4 sys/kern/genlintstub.awk
--- a/sys/kern/genlintstub.awk Wed May 16 03:58:34 2001 +0000
+++ b/sys/kern/genlintstub.awk Wed May 16 04:17:04 2001 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: genlintstub.awk,v 1.3 2001/05/16 03:58:14 perry Exp $
+# $NetBSD: genlintstub.awk,v 1.4 2001/05/16 04:17:04 perry Exp $
#
# Copyright 2001 Wasabi Systems, Inc.
# All rights reserved.
@@ -47,6 +47,12 @@
# kernel has declared as char * and such, like various bits of
# trampoline code.
#
+# /* LINTSTUB: include foo */
+# Turns into a literal `#include foo' line in the source. Useful for
+# making sure the stubs are checked against system prototypes like
+# systm.h, cpu.h, etc., and to make sure that various types are
+# properly declared.
+#
# /* LINTSTUB: Ignore */
# This is used as an indicator to humans (and possible future
# automatic tools) that the entry is only used internally by other .S
@@ -62,10 +68,7 @@
printf "/* This file was automatically generated. */\n";
printf "/* DO NOT EDIT! DO NOT EDIT! DO NOT EDIT! */\n";
printf "/* DO NOT EDIT! DO NOT EDIT! DO NOT EDIT! */\n";
- # Do we really want this? I figure it will catch a lot
- # of stuff early on (while processing the same file
- # rather than in a later lint pass) and is thus worth it.
- printf "\n#include <sys/systm.h>\n\n\n";
+ printf "\n\n";
}
@@ -116,6 +119,11 @@
exit 1;
}
+/^\/\* LINTSTUB: include[ \t]+.*\*\/[ \t]*$/ {
+ printf "#include %s\n", $4;
+ next;
+ }
+
/^\/\* LINTSTUB: Ignore.*\*\/[ \t]*$/ { next; }
/^\/\* LINTSTUB: Ignore/ {
Home |
Main Index |
Thread Index |
Old Index