aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2020-12-31 19:31:12 +0000
committerEd Maste <emaste@FreeBSD.org>2020-12-31 20:56:18 +0000
commit1e54857bd9f5791ec1edfc5c21edb374519e9061 (patch)
tree7448f24f3ee8593295ccd4135e90c902d5bec23c
parentf492599d7bc48b64bf039c5a61295a31fb6887da (diff)
downloadsrc-1e54857bd9f5791ec1edfc5c21edb374519e9061.tar.gz
src-1e54857bd9f5791ec1edfc5c21edb374519e9061.zip
Stop defaulting to DWRAF2 in kernel compilation
After the removal of obsolete GDB 6.1.1 from the base system in 1c0ea326aa6d we no longer need to downgrade to DWARF2 debug info. We will need to ensure that our tools (e.g. ctfconvert) handle DWARF5 prior to it becoming the default in the Clang and GCC versions we use. Reported by: jhb Relnotes: Yes Sponsored by: The FreeBSD Foundation
-rw-r--r--sys/conf/kern.mk11
1 files changed, 0 insertions, 11 deletions
diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk
index e897249c32e6..8f0163a3d0a0 100644
--- a/sys/conf/kern.mk
+++ b/sys/conf/kern.mk
@@ -245,17 +245,6 @@ CFLAGS+= -ftrivial-auto-var-init=pattern
.endif
.endif
-#
-# Add -gdwarf-2 when compiling -g. The default starting in clang v3.4
-# and gcc 4.8 is to generate DWARF version 4. However, our tools don't
-# cope well with DWARF 4, so force it to genereate DWARF2, which they
-# understand. Do this unconditionally as it is harmless when not needed,
-# but critical for these newer versions.
-#
-.if ${CFLAGS:M-g} != "" && ${CFLAGS:M-gdwarf*} == ""
-CFLAGS+= -gdwarf-2
-.endif
-
CFLAGS+= ${CWARNFLAGS:M*} ${CWARNFLAGS.${.IMPSRC:T}}
CFLAGS+= ${CWARNFLAGS.${COMPILER_TYPE}}
CFLAGS+= ${CFLAGS.${COMPILER_TYPE}} ${CFLAGS.${.IMPSRC:T}}