From 9ee3eadfc8e7d4bff273920f109fb5784a7639a7 Mon Sep 17 00:00:00 2001 From: emaste Date: Fri, 9 Nov 2018 18:35:09 +0000 Subject: [PATCH] Move llvm-profdata build into MK_LLVM_COV block llvm-profdata is used with llvm-cov for code coverage (although llvm-cov can also operate independently in a gcov-compatible mode). Although llvm-profdata can be used independently of llvm-cov it makes sense to group these under one option. Also handle these in OptionalObsoleteFiles.inc while here. Sponsored by: The FreeBSD Foundation --- tools/build/mk/OptionalObsoleteFiles.inc | 6 ++++++ usr.bin/clang/Makefile | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index 45b0a27865f8..77ae362208ff 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -2466,6 +2466,12 @@ OLD_FILES+=usr/bin/gcov OLD_FILES+=usr/share/man/man1/gcov.1.gz .endif +.if ${MK_LLVM_COV} == no +OLD_FILES+=usr/bin/llvm-cov +OLD_FILES+=usr/bin/llvm-profdata +OLD_FILES+=usr/share/man/man1/llvm-cov.1.gz +.endif + .if ${MK_GDB} == no || ${MK_GDB_LIBEXEC} == yes OLD_FILES+=usr/bin/gdb OLD_FILES+=usr/bin/gdbserver diff --git a/usr.bin/clang/Makefile b/usr.bin/clang/Makefile index 9d081c0fdda8..2054657186bd 100644 --- a/usr.bin/clang/Makefile +++ b/usr.bin/clang/Makefile @@ -31,7 +31,6 @@ SUBDIR+= llvm-modextract SUBDIR+= llvm-nm SUBDIR+= llvm-objcopy SUBDIR+= llvm-pdbutil -SUBDIR+= llvm-profdata SUBDIR+= llvm-rtdyld SUBDIR+= llvm-symbolizer SUBDIR+= llvm-xray @@ -46,6 +45,7 @@ SUBDIR+= lldb .endif .if ${MK_LLVM_COV} != "no" SUBDIR+= llvm-cov +SUBDIR+= llvm-profdata .endif .endif # TOOLS_PREFIX