From owner-svn-src-all@freebsd.org Thu Jun 28 21:26:15 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3F3D31027B97; Thu, 28 Jun 2018 21:26:15 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E36098F2D1; Thu, 28 Jun 2018 21:26:14 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id C357117B8D; Thu, 28 Jun 2018 21:26:14 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w5SLQEIg067680; Thu, 28 Jun 2018 21:26:14 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w5SLQExK067679; Thu, 28 Jun 2018 21:26:14 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201806282126.w5SLQExK067679@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Thu, 28 Jun 2018 21:26:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r335782 - head X-SVN-Group: head X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: head X-SVN-Commit-Revision: 335782 X-SVN-Commit-Repository: base 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.26 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: Thu, 28 Jun 2018 21:26:15 -0000 Author: jhb Date: Thu Jun 28 21:26:14 2018 New Revision: 335782 URL: https://svnweb.freebsd.org/changeset/base/335782 Log: Remove the various build flag hacks for GCC cross-compile. The xtoolchain GCC packages have not required these flags since ports commits r465416 and r466701. The in-tree GCC 4.2.1 has also been patched in r335716 and r335717 to correctly honor --sysroot when looking for includes and libraries. Reviewed by: bdrewery Sponsored by: DARPA / AFRL Differential Revision: https://reviews.freebsd.org/D16055 Modified: head/Makefile.inc1 head/Makefile.libcompat Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Thu Jun 28 21:23:05 2018 (r335781) +++ head/Makefile.inc1 Thu Jun 28 21:26:14 2018 (r335782) @@ -750,19 +750,6 @@ BFLAGS+= -B${WORLDTMP}/usr/bin .endif .if ${WANT_COMPILER_TYPE} == gcc || \ (defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} == gcc) -# GCC requires -isystem and -L when using a cross-compiler. --sysroot -# won't set header path and -L is used to ensure the base library path -# is added before the port PREFIX library path. -XCFLAGS+= -isystem ${WORLDTMP}/usr/include -L${WORLDTMP}/usr/lib -# GCC requires -B to find /usr/lib/crti.o when using a cross-compiler -# combined with --sysroot. -XCFLAGS+= -B${WORLDTMP}/usr/lib -# Force using libc++ for external GCC. -.if defined(X_COMPILER_TYPE) && \ - ${X_COMPILER_TYPE} == gcc && ${X_COMPILER_VERSION} >= 40800 -XCXXFLAGS+= -isystem ${WORLDTMP}/usr/include/c++/v1 -std=c++11 \ - -nostdinc++ -.endif .elif ${WANT_COMPILER_TYPE} == clang || \ (defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} == clang) XCFLAGS+= -target ${TARGET_TRIPLE} Modified: head/Makefile.libcompat ============================================================================== --- head/Makefile.libcompat Thu Jun 28 21:23:05 2018 (r335781) +++ head/Makefile.libcompat Thu Jun 28 21:26:14 2018 (r335782) @@ -100,22 +100,6 @@ LIBCOMPATCFLAGS+= ${LIBCOMPATCPUFLAGS} \ # Clang/GCC. LIBCOMPATCFLAGS+= -B${LIBCOMPATTMP}/usr/lib${libcompat} -.if ${WANT_COMPILER_TYPE} == gcc || \ - (defined(X_COMPILER_TYPE) && ${X_COMPILER_TYPE} == gcc) -# GCC requires -isystem when using a cross-compiler and --sysroot. Note that -# Makefile.inc1 only applies this with an external compiler but libcompat -# always does since even in-tree GCC 4.2 needs this to override the built-in -# sysroot path which --sysroot does not actually do for headers. -LIBCOMPATCFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include -# Force using libc++ for external GCC. -.if defined(X_COMPILER_TYPE) && \ - ${X_COMPILER_TYPE} == gcc && ${X_COMPILER_VERSION} >= 40800 && \ - (${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no") -LIBCOMPATCXXFLAGS+= -isystem ${LIBCOMPATTMP}/usr/include/c++/v1 -std=c++11 \ - -nostdinc++ -.endif -.endif - # Yes, the flags are redundant. LIBCOMPATWMAKEENV+= \ INSTALL="sh ${.CURDIR}/tools/install.sh" \