The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=ae0a3632b5080b953e138b69d2b96de54d9be8a3
commit ae0a3632b5080b953e138b69d2b96de54d9be8a3 Author: Ed Maste <[email protected]> AuthorDate: 2026-05-04 14:34:07 +0000 Commit: Ed Maste <[email protected]> CommitDate: 2026-07-10 15:20:34 +0000 build: Retire LLVM_COV src.conf knob I introduced it in commit 1b49115a40ad ("Promote llvm-cov to a standalone option"). llvm-cov was previously enabled as part of the CLANG_EXTRAS option. I made it a standalone, default-enabled option for parity with the tools provided by the GCC-based toolchain. We no longer provide an in-tree GCC toolchain. Now, just build llvm-cov along with Clang to simplify build infrastructure. Reviewed by: dim Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D58155 --- lib/clang/libllvm/Makefile | 5 ++--- share/man/man5/src.conf.5 | 10 +--------- share/mk/src.opts.mk | 2 -- tools/build/mk/OptionalObsoleteFiles.inc | 4 ++-- tools/build/options/WITHOUT_LLVM_COV | 3 --- tools/build/options/WITH_LLVM_COV | 3 --- usr.bin/clang/Makefile | 2 +- usr.bin/clang/toolchain/Makefile | 2 -- 8 files changed, 6 insertions(+), 25 deletions(-) diff --git a/lib/clang/libllvm/Makefile b/lib/clang/libllvm/Makefile index ea90b37f8cbd..a234c73b15b9 100644 --- a/lib/clang/libllvm/Makefile +++ b/lib/clang/libllvm/Makefile @@ -2205,10 +2205,9 @@ SRCS_ALL+= ${SRCS_XDL} .if ${MK_CLANG_EXTRAS} != "no" || ${MK_LLDB} != "no" || !defined(TOOLS_PREFIX) SRCS_ALL+= ${SRCS_XDW} .endif -.if ${MK_LLVM_COV} != "no" +# LLVM_COV retired, just part of Clang now SRCS_ALL+= ${SRCS_COV} -.endif -.if ${MK_LLVM_COV} != "no" || ${MK_LLD} != "no" || \ +.if ${MK_LLD} != "no" || \ (defined(TOOLS_PREFIX) && ${MK_LLD_BOOTSTRAP} != "no") SRCS_ALL+= ${SRCS_COL} .endif diff --git a/share/man/man5/src.conf.5 b/share/man/man5/src.conf.5 index b1c511f596ef..c9c9c01cbc99 100644 --- a/share/man/man5/src.conf.5 +++ b/share/man/man5/src.conf.5 @@ -1,5 +1,5 @@ .\" DO NOT EDIT-- this file is @generated by tools/build/options/makeman. -.Dd July 9, 2026 +.Dd July 10, 2026 .Dt SRC.CONF 5 .Os .Sh NAME @@ -397,8 +397,6 @@ When set, it enforces these options: .Va WITHOUT_CLANG_FORMAT .It .Va WITHOUT_CLANG_FULL -.It -.Va WITHOUT_LLVM_COV .El .Pp When set, these options are also in effect: @@ -993,10 +991,6 @@ To be able to build the system alternate binary utilities must be provided via and .Ev XSTRIPBIN . -.It Va WITHOUT_LLVM_COV -Do not build the -.Xr llvm-cov 1 -tool. .It Va WITH_LLVM_FULL_DEBUGINFO Generate full debug information for LLVM libraries and tools, which uses more disk space and build resources, but allows for easier debugging. @@ -1841,8 +1835,6 @@ When set, it enforces these options: .Va WITHOUT_LLD .It .Va WITHOUT_LLDB -.It -.Va WITHOUT_LLVM_COV .El .Pp When set, these options are also in effect: diff --git a/share/mk/src.opts.mk b/share/mk/src.opts.mk index 1dbd1d2d9703..13136b174860 100644 --- a/share/mk/src.opts.mk +++ b/share/mk/src.opts.mk @@ -124,7 +124,6 @@ __DEFAULT_YES_OPTIONS = \ LLVM_ASSERTIONS \ LLVM_BINUTILS \ LLVM_BINUTILS_BOOTSTRAP \ - LLVM_COV \ LOADER_BIOS \ LOADER_BIOS_TEXTONLY \ LOADER_GELI \ @@ -511,7 +510,6 @@ MK_LLVM_BINUTILS:= no MK_CLANG_EXTRAS:= no MK_CLANG_FORMAT:= no MK_CLANG_FULL:= no -MK_LLVM_COV:= no .endif .if ${MK_ASAN} == "yes" diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index e46618644f7d..842ecec362a6 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -895,7 +895,7 @@ OLD_LIBS+=usr/lib/libprivateclang.so.21 .endif .if (${MK_CLANG_EXTRAS} == no && ${MK_CLANG} == no && ${MK_LLDB} == no && \ - ${MK_LLD} == no && ${MK_LLVM_BINUTILS} == no && ${MK_LLVM_COV} == no) || \ + ${MK_LLD} == no && ${MK_LLVM_BINUTILS} == no) || \ ${MK_LLVM_LINK_STATIC_LIBRARIES} != no OLD_LIBS+=usr/lib/libprivatellvm.so.21 .endif @@ -3925,7 +3925,7 @@ OLD_FILES+=usr/share/man/man1/lldb-server.1.gz OLD_FILES+=usr/share/man/man1/lldb.1.gz .endif -.if ${MK_LLVM_COV} == no +.if ${MK_CLANG} == no OLD_FILES+=usr/bin/gcov OLD_FILES+=usr/bin/llvm-cov OLD_FILES+=usr/bin/llvm-profdata diff --git a/tools/build/options/WITHOUT_LLVM_COV b/tools/build/options/WITHOUT_LLVM_COV deleted file mode 100644 index d95e76ddf659..000000000000 --- a/tools/build/options/WITHOUT_LLVM_COV +++ /dev/null @@ -1,3 +0,0 @@ -Do not build the -.Xr llvm-cov 1 -tool. diff --git a/tools/build/options/WITH_LLVM_COV b/tools/build/options/WITH_LLVM_COV deleted file mode 100644 index 8cfe078ee231..000000000000 --- a/tools/build/options/WITH_LLVM_COV +++ /dev/null @@ -1,3 +0,0 @@ -Build the -.Xr llvm-cov 1 -tool. diff --git a/usr.bin/clang/Makefile b/usr.bin/clang/Makefile index 1d80fad2936f..3252e077d42f 100644 --- a/usr.bin/clang/Makefile +++ b/usr.bin/clang/Makefile @@ -62,7 +62,7 @@ SUBDIR+= lld SUBDIR+= lldb SUBDIR+= lldb-server .endif -.if ${MK_LLVM_COV} != "no" +.if ${MK_CLANG} != "no" SUBDIR+= llvm-cov SUBDIR+= llvm-profdata SUBDIR_DEPEND_toolchain= llvm-cov diff --git a/usr.bin/clang/toolchain/Makefile b/usr.bin/clang/toolchain/Makefile index 5f66ae1433b1..728c945bea10 100644 --- a/usr.bin/clang/toolchain/Makefile +++ b/usr.bin/clang/toolchain/Makefile @@ -7,10 +7,8 @@ SYMLINKS+= llvm-ar ${BINDIR}/ar SYMLINKS+= llvm-ranlib ${BINDIR}/ranlib MLINKS+= llvm-ar.1 ar.1 llvm-ar.1 ranlib.1 -.if ${MK_LLVM_COV} != "no" SYMLINKS+= llvm-cov ${BINDIR}/gcov MLINKS= llvm-cov.1 gcov.1 -.endif SYMLINKS+= llvm-cxxfilt ${BINDIR}/c++filt MLINKS+= llvm-cxxfilt.1 c++filt.1
