Module Name:    src
Committed By:   maxv
Date:           Sun May 10 06:38:24 UTC 2020

Modified Files:
        src/doc: HACKS
        src/share/mk: bsd.lib.mk

Log Message:
Pass -Wno-unused-command-line-argument for LLVM, discussed on
tech-toolchain@.


To generate a diff of this commit:
cvs rdiff -u -r1.206 -r1.207 src/doc/HACKS
cvs rdiff -u -r1.380 -r1.381 src/share/mk/bsd.lib.mk

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

Modified files:

Index: src/doc/HACKS
diff -u src/doc/HACKS:1.206 src/doc/HACKS:1.207
--- src/doc/HACKS:1.206	Wed May  6 14:33:52 2020
+++ src/doc/HACKS	Sun May 10 06:38:24 2020
@@ -1,4 +1,4 @@
-# $NetBSD: HACKS,v 1.206 2020/05/06 14:33:52 snj Exp $
+# $NetBSD: HACKS,v 1.207 2020/05/10 06:38:24 maxv Exp $
 #
 # This file is intended to document workarounds for currently unsolved
 # (mostly) compiler bugs.
@@ -27,6 +27,16 @@
 #
 # this is a comment.
 
+hack	llvm needs no-unused-command-line-argument
+mdate	10 May 2020
+who	maxv
+file	share/mk/bsd.lib.mk 1.380 -> 1.381
+descr
+	To avoid LLVM warnings when compiling the kernel with special
+	CFLAGS such as KASAN on amd64 or ARMV83_PAC on aarch64, pass
+	-Wno-unused-command-line-argument.
+kcah
+
 hack	static linking with libpthread
 mdate	7 May 2019
 who	maya

Index: src/share/mk/bsd.lib.mk
diff -u src/share/mk/bsd.lib.mk:1.380 src/share/mk/bsd.lib.mk:1.381
--- src/share/mk/bsd.lib.mk:1.380	Tue Aug 27 22:48:54 2019
+++ src/share/mk/bsd.lib.mk	Sun May 10 06:38:24 2020
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.lib.mk,v 1.380 2019/08/27 22:48:54 kamil Exp $
+#	$NetBSD: bsd.lib.mk,v 1.381 2020/05/10 06:38:24 maxv Exp $
 #	@(#)bsd.lib.mk	8.3 (Berkeley) 4/22/94
 
 .include <bsd.init.mk>
@@ -568,7 +568,7 @@ __archivesymlinkpic: .USE
 __buildstdlib: .USE
 	@echo building standard ${.TARGET:T:S/.o//:S/lib//} library
 	@rm -f ${.TARGET}
-	@${LINK.c:S/-nostdinc//} -nostdlib ${LDFLAGS} -r -o ${.TARGET} `NM=${NM} ${LORDER} ${.ALLSRC:M*o} | ${TSORT}`
+	@${LINK.c:S/-nostdinc//} -nostdlib ${LDFLAGS} -Wno-unused-command-line-argument -r -o ${.TARGET} `NM=${NM} ${LORDER} ${.ALLSRC:M*o} | ${TSORT}`
 .endif
 
 .if !target(__buildproflib)

Reply via email to