From owner-svn-src-head@FreeBSD.ORG Fri Apr 11 18:40:30 2014 Return-Path: Delivered-To: svn-src-head@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 9345C95; Fri, 11 Apr 2014 18:40:30 +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)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6762B1DDD; Fri, 11 Apr 2014 18:40:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s3BIeUkV084782; Fri, 11 Apr 2014 18:40:30 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s3BIeU71084781; Fri, 11 Apr 2014 18:40:30 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201404111840.s3BIeU71084781@svn.freebsd.org> From: Dimitry Andric Date: Fri, 11 Apr 2014 18:40:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r264350 - head/contrib/llvm/patches X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Apr 2014 18:40:30 -0000 Author: dim Date: Fri Apr 11 18:40:29 2014 New Revision: 264350 URL: http://svnweb.freebsd.org/changeset/base/264350 Log: Update the llvm/clang patch for r264345. Added: head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff - copied, changed from r264345, head/contrib/llvm/patches/patch-r263891-dwarf2-freebsd10.diff Deleted: head/contrib/llvm/patches/patch-r263891-dwarf2-freebsd10.diff Copied and modified: head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff (from r264345, head/contrib/llvm/patches/patch-r263891-dwarf2-freebsd10.diff) ============================================================================== --- head/contrib/llvm/patches/patch-r263891-dwarf2-freebsd10.diff Fri Apr 11 16:51:35 2014 (r264345, copy source) +++ head/contrib/llvm/patches/patch-r264345-dwarf2-freebsd10.diff Fri Apr 11 18:40:29 2014 (r264350) @@ -1,22 +1,20 @@ -This patch makes clang default to DWARF2 debug info format for FreeBSD -10.x and earlier. +This patch makes clang default to DWARF2 debug info format for FreeBSD. -Introduced here: http://svnweb.freebsd.org/changeset/base/263891 +Introduced here: http://svnweb.freebsd.org/changeset/base/264345 Index: tools/clang/lib/Driver/Tools.cpp =================================================================== --- tools/clang/lib/Driver/Tools.cpp +++ tools/clang/lib/Driver/Tools.cpp -@@ -2628,8 +2628,10 @@ void Clang::ConstructJob(Compilation &C, const Job +@@ -2627,8 +2635,9 @@ void Clang::ConstructJob(Compilation &C, const Job CmdArgs.push_back("-gdwarf-4"); else if (!A->getOption().matches(options::OPT_g0) && !A->getOption().matches(options::OPT_ggdb0)) { - // Default is dwarf-2 for darwin. - if (getToolChain().getTriple().isOSDarwin()) -+ // Default is dwarf-2 for darwin and FreeBSD <= 10. ++ // Default is dwarf-2 for darwin and FreeBSD. + const llvm::Triple &Triple = getToolChain().getTriple(); -+ if (Triple.isOSDarwin() || (Triple.getOS() == llvm::Triple::FreeBSD && -+ Triple.getOSMajorVersion() <= 10)) ++ if (Triple.isOSDarwin() || Triple.getOS() == llvm::Triple::FreeBSD) CmdArgs.push_back("-gdwarf-2"); else CmdArgs.push_back("-g");