aboutsummaryrefslogtreecommitdiff
path: root/lib/Makefile
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2021-10-29 00:49:12 +0000
committerEd Maste <emaste@FreeBSD.org>2021-10-29 14:05:49 +0000
commitad09e2c8cfbc2cf6f2b8826c121d6de8b3bfe96d (patch)
treeb42e99bea4f4200392bfe0ce9cd22389e8872d56 /lib/Makefile
parent6547153e4618c3b57e5f76062de006a04ecbd64b (diff)
Diffstat (limited to 'lib/Makefile')
-rw-r--r--lib/Makefile7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/Makefile b/lib/Makefile
index 3f30917173af..93761cc06b21 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -176,10 +176,9 @@ SUBDIR.${MK_KERBEROS_SUPPORT}+= libcom_err
SUBDIR.${MK_LDNS}+= libldns
SUBDIR.${MK_STATS}+= libstats
-# The libraries under libclang_rt can only be built by clang, and only make
-# sense to build when clang is enabled at all. Furthermore, they can only be
-# built for certain architectures.
-.if ${COMPILER_TYPE} == "clang" && \
+# The libraries under libclang_rt can only be built by clang and when we enable
+# C++ support. Furthermore, they can only be built for certain architectures.
+.if ${COMPILER_TYPE} == "clang" && ${MK_CXX} != "no" && \
(${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \
${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "i386" || \
${MACHINE_CPUARCH} == "powerpc")