From owner-svn-src-all@FreeBSD.ORG Tue Mar 25 22:08:33 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 438F054D; Tue, 25 Mar 2014 22:08:33 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 23C65B7C; Tue, 25 Mar 2014 22:08:33 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s2PM8XV7019667; Tue, 25 Mar 2014 22:08:33 GMT (envelope-from imp@svn.freebsd.org) Received: (from imp@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s2PM8VXj019660; Tue, 25 Mar 2014 22:08:31 GMT (envelope-from imp@svn.freebsd.org) Message-Id: <201403252208.s2PM8VXj019660@svn.freebsd.org> From: Warner Losh Date: Tue, 25 Mar 2014 22:08:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r263749 - in head: . sys/amd64/conf sys/conf sys/i386/conf sys/sparc64/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 25 Mar 2014 22:08:33 -0000 Author: imp Date: Tue Mar 25 22:08:31 2014 New Revision: 263749 URL: http://svnweb.freebsd.org/changeset/base/263749 Log: Rather than require a makeoptions DEBUG to get debug correct, add it in kern.mk, but only if we're using clang. While this option is supported by both clang and gcc, in the future there may be changes to clang which change the defaults that require a tweak to build our kernel such that other tools in our tree will work. Set a good example by forcing -gdwarf-2 only for clang builds, and only if the user hasn't specified another dwarf level already. Update UPDATING to reflect the changed state of affairs. This also keeps us from having to update all the ARM kernels to add this, and also keeps us from in the future having to update all the MIPS kernels and is one less place the user will have to know to do something special for clang and one less thing developers will need to do when moving an architecture to clang. Reviewed by: ian@ MFC after: 1 week Modified: head/UPDATING head/sys/amd64/conf/GENERIC head/sys/conf/kern.mk head/sys/i386/conf/GENERIC head/sys/i386/conf/XEN head/sys/sparc64/conf/GENERIC Modified: head/UPDATING ============================================================================== --- head/UPDATING Tue Mar 25 21:57:50 2014 (r263748) +++ head/UPDATING Tue Mar 25 22:08:31 2014 (r263749) @@ -31,6 +31,13 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11 disable the most expensive debugging functionality run "ln -s 'abort:false,junk:false' /etc/malloc.conf".) +20140325: + It is no longer necessary to include the dwarf version in your DEBUG + options in your kernel config file. The bug that required it to be + placed in the config file has bene fixed. DEBUG should now just + contain -g. The build system will automatically update things + to do the right thing. Ignore the entry from 20140216. + 20140306: Support for libwrap (TCP wrappers) in rpcbind was disabled by default to improve performance. To re-enable it, if needed, run rpcbind @@ -44,16 +51,18 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11 to do so. Set WITHOUT_GPL_DTC if you require the BSDL compiler. 20140216: - Clang and llvm have been upgraded to 3.4 release. Please note that - clang 3.4 now defaults to DWARF4 debug information format when you - specify -g. Since kgdb(1) only supports DWARF2, you should update any - customized kernel configurations which include debug information to - explicitly use -gdwarf-2, e.g: + Clang and llvm have been upgraded to 3.4 release. + + Please note that clang 3.4 now defaults to DWARF4 debug information + format when you specify -g. Since kgdb(1) only supports DWARF2, you + should update any customized kernel configurations which include debug + information to explicitly use -gdwarf-2, e.g: makeoptions DEBUG=-gdwarf-2 This has already been applied to the appropriate GENERIC configuration files, so if you inherit from those, no changes are required. + Please note: this bug has been fixed, please see 20140325. 20140216: The nve(4) driver has been removed. Please use the nfe(4) driver Modified: head/sys/amd64/conf/GENERIC ============================================================================== --- head/sys/amd64/conf/GENERIC Tue Mar 25 21:57:50 2014 (r263748) +++ head/sys/amd64/conf/GENERIC Tue Mar 25 22:08:31 2014 (r263749) @@ -21,7 +21,7 @@ cpu HAMMER ident GENERIC -makeoptions DEBUG=-gdwarf-2 # Build kernel with gdb(1) debug symbols +makeoptions DEBUG=-g makeoptions WITH_CTF=1 # Run ctfconvert(1) for DTrace support options SCHED_ULE # ULE scheduler Modified: head/sys/conf/kern.mk ============================================================================== --- head/sys/conf/kern.mk Tue Mar 25 21:57:50 2014 (r263748) +++ head/sys/conf/kern.mk Tue Mar 25 22:08:31 2014 (r263749) @@ -162,3 +162,10 @@ CFLAGS+= -ffreestanding ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" CFLAGS+= -fstack-protector .endif + +# +# Add -gdwarf-2 when compiling -g +# +.if ${COMPILER_TYPE} == "clang" && ${CFLAGS:M-g} != "" && ${CFLAGS:M-gdwarf} == "" +CFLAGS+= -gdwarf-2 +.endif Modified: head/sys/i386/conf/GENERIC ============================================================================== --- head/sys/i386/conf/GENERIC Tue Mar 25 21:57:50 2014 (r263748) +++ head/sys/i386/conf/GENERIC Tue Mar 25 22:08:31 2014 (r263749) @@ -23,7 +23,7 @@ cpu I586_CPU cpu I686_CPU ident GENERIC -makeoptions DEBUG=-gdwarf-2 # Build kernel with gdb(1) debug symbols +makeoptions DEBUG=-g makeoptions WITH_CTF=1 # Run ctfconvert(1) for DTrace support options SCHED_ULE # ULE scheduler Modified: head/sys/i386/conf/XEN ============================================================================== --- head/sys/i386/conf/XEN Tue Mar 25 21:57:50 2014 (r263748) +++ head/sys/i386/conf/XEN Tue Mar 25 22:08:31 2014 (r263749) @@ -6,7 +6,7 @@ cpu I686_CPU ident XEN -makeoptions DEBUG=-gdwarf-2 # Build kernel with gdb(1) debug symbols +makeoptions DEBUG=-g makeoptions WITHOUT_MODULES="aha ahb amd ctl cxgb dpt drm drm2 hptnr hptmv ida malo mps mwl rdma sound sym trm xfs" options SCHED_ULE # ULE scheduler Modified: head/sys/sparc64/conf/GENERIC ============================================================================== --- head/sys/sparc64/conf/GENERIC Tue Mar 25 21:57:50 2014 (r263748) +++ head/sys/sparc64/conf/GENERIC Tue Mar 25 22:08:31 2014 (r263749) @@ -21,7 +21,7 @@ cpu SUN4U ident GENERIC -makeoptions DEBUG=-gdwarf-2 # Build kernel with gdb(1) debug symbols +makeoptions DEBUG=-g # Platforms supported # At this time all platforms are supported, as-is.