Module Name:    src
Committed By:   rillig
Date:           Sun May  2 19:29:30 UTC 2021

Modified Files:
        src/sys/conf: lint.mk

Log Message:
sys/conf/lint.mk: a small step for linting the kernel

Due to the missing path, the following commands had failed:

        $ cd src/sys/arch/amd64/compile/GENERIC
        $ nbmake-amd64-lint kern_exec.ln
        nbmake: don't know how to make kern/kern_exec.c. Stop

After fixing the path, "make kern_exec.ln" fails with:

        sys/kern/kern_exec.c(65): error: syntax error '"' [249]

The affected line contains:

        __KERNEL_RCSID(0, "...");

The macro __KERNEL_RCSID expands to __asm("some strings").  Since
KERNLINTFLAGS is missing the -g, lint does not recognize __asm as
keyword and tries to parse it as an identifier instead, expecting a
variable or function declaration.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/conf/lint.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/conf/lint.mk
diff -u src/sys/conf/lint.mk:1.1 src/sys/conf/lint.mk:1.2
--- src/sys/conf/lint.mk:1.1	Sat Aug 29 16:27:07 2015
+++ src/sys/conf/lint.mk	Sun May  2 19:29:30 2021
@@ -1,10 +1,11 @@
-# $NetBSD: lint.mk,v 1.1 2015/08/29 16:27:07 uebayasi Exp $
+# $NetBSD: lint.mk,v 1.2 2021/05/02 19:29:30 rillig Exp $
 
 ##
 ## lint
 ##
 
 .if !target(lint)
+.PATH: $S
 ALLSFILES?=	${MD_SFILES} ${SFILES}
 LINTSTUBS?=	${ALLSFILES:T:R:C/^.*$/LintStub_&.c/g}
 KERNLINTFLAGS?=	-bcehnxzFS

Reply via email to