diff options
| author | 2006-04-27 18:09:52 +0000 | |
|---|---|---|
| committer | 2006-04-27 18:09:52 +0000 | |
| commit | 3ad89290bf50d486eff84d1129e924880887eb30 (patch) | |
| tree | d4b60754413874c9bb8e461449f09fd666a7d795 /usr.sbin/config/files.c | |
| parent | move 'midi* at umidi?' to the same place as for i386. (diff) | |
| download | wireguard-openbsd-3ad89290bf50d486eff84d1129e924880887eb30.tar.xz wireguard-openbsd-3ad89290bf50d486eff84d1129e924880887eb30.zip | |
lint(1) support in config:
- LINTS variables to hold the list of *.ln files.
- OBJS derives from it, since it can contain more files.
- add set of explicit rules for each .ln file.
- add a lint-with keyword that duplicates compile-with functionality
to special-case linting instead of compilation.
Full linting is dependent on LINT_* macros in the arch dependent template
files.
As is, doesn't break normal build. Just creates larger Makefiles.
Review/ok miod@, cloder@, deraadt@
Diffstat (limited to 'usr.sbin/config/files.c')
| -rw-r--r-- | usr.sbin/config/files.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.sbin/config/files.c b/usr.sbin/config/files.c index 404f30733ea..9f5c53b25c7 100644 --- a/usr.sbin/config/files.c +++ b/usr.sbin/config/files.c @@ -1,4 +1,4 @@ -/* $OpenBSD: files.c,v 1.13 2003/06/28 04:55:07 deraadt Exp $ */ +/* $OpenBSD: files.c,v 1.14 2006/04/27 18:09:52 espie Exp $ */ /* $NetBSD: files.c,v 1.6 1996/03/17 13:18:17 cgd Exp $ */ /* @@ -84,7 +84,8 @@ initfiles(void) } void -addfile(const char *path, struct nvlist *optx, int flags, const char *rule) +addfile(const char *path, struct nvlist *optx, int flags, const char *rule, + const char *lintrule) { struct files *fi; const char *dotp, *tail; @@ -141,7 +142,8 @@ addfile(const char *path, struct nvlist *optx, int flags, const char *rule) fi->fi_base = intern(base); fi->fi_optx = optx; fi->fi_optf = NULL; - fi->fi_mkrule = rule; + fi->fi_mkrule[0] = rule; + fi->fi_mkrule[1] = lintrule; *nextfile = fi; nextfile = &fi->fi_next; return; |
