Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/share/mk Add SANITIZER_RENAME_CLASSES in bsd.prog.mk
details: https://anonhg.NetBSD.org/src/rev/6b597f63ae75
branches: trunk
changeset: 453511:6b597f63ae75
user: kamil <kamil%NetBSD.org@localhost>
date: Thu Aug 15 08:42:59 2019 +0000
description:
Add SANITIZER_RENAME_CLASSES in bsd.prog.mk
This adds a more flexible version of SANITIZER_RENAME_SYMBOL.
New symbol allows to specify MKSANITIZER specific renames on per-file and
per-symbol basis.
diffstat:
share/mk/bsd.prog.mk | 12 +++++++++++-
1 files changed, 11 insertions(+), 1 deletions(-)
diffs (26 lines):
diff -r 55a806030de4 -r 6b597f63ae75 share/mk/bsd.prog.mk
--- a/share/mk/bsd.prog.mk Thu Aug 15 08:37:13 2019 +0000
+++ b/share/mk/bsd.prog.mk Thu Aug 15 08:42:59 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.prog.mk,v 1.320 2019/08/10 12:46:38 christos Exp $
+# $NetBSD: bsd.prog.mk,v 1.321 2019/08/15 08:42:59 kamil Exp $
# @(#)bsd.prog.mk 8.2 (Berkeley) 4/2/94
.ifndef HOSTPROG
@@ -20,6 +20,16 @@
. endfor
.endif
+.if ${MKSANITIZER:Uno} == "yes" && defined(SANITIZER_RENAME_CLASSES)
+. for _class in ${SANITIZER_RENAME_CLASSES}
+. for _file in ${SANITIZER_RENAME_FILES.${_class}}
+. for _symbol in ${SANITIZER_RENAME_SYMBOL.${_class}}
+COPTS.${_file}+= -D${_symbol}=__mksanitizer_${_symbol}
+. endfor
+. endfor
+. endfor
+.endif
+
#
# Definitions and targets shared among all programs built by a single
# Makefile.
Home |
Main Index |
Thread Index |
Old Index