From owner-svn-src-all@freebsd.org Tue Jun 19 23:39:56 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 7C73B1016047; Tue, 19 Jun 2018 23:39:56 +0000 (UTC) (envelope-from bdrewery@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 2E0617B359; Tue, 19 Jun 2018 23:39:56 +0000 (UTC) (envelope-from bdrewery@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 E3F721A6FC; Tue, 19 Jun 2018 23:39:55 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w5JNdtoe002573; Tue, 19 Jun 2018 23:39:55 GMT (envelope-from bdrewery@FreeBSD.org) Received: (from bdrewery@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w5JNdtix002572; Tue, 19 Jun 2018 23:39:55 GMT (envelope-from bdrewery@FreeBSD.org) Message-Id: <201806192339.w5JNdtix002572@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bdrewery set sender to bdrewery@FreeBSD.org using -f From: Bryan Drewery Date: Tue, 19 Jun 2018 23:39:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r335391 - head X-SVN-Group: head X-SVN-Commit-Author: bdrewery X-SVN-Commit-Paths: head X-SVN-Commit-Revision: 335391 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: Tue, 19 Jun 2018 23:39:56 -0000 Author: bdrewery Date: Tue Jun 19 23:39:55 2018 New Revision: 335391 URL: https://svnweb.freebsd.org/changeset/base/335391 Log: Fix X_COMPILER_* and X_LINKER_* not being passed to installworld environment. This could lead to 'sh: head: not found' warnings which were a symptom of running 'ld --version' during installworld. This was only happening with XCC or XLD set. It is intended that cc and ld do not run during installworld. The metadata for these are already stored in compiler-metadata.mk added in r316794. This also removes redundant CROSSENV additions that were for WITH_SYSTEM_COMPILER, WITHOUT_CROSS_COMPILER, and WITHOUT_TOOLCHAIN which all don't have a cc or ld in their PATH during install. Reported by: Mark Millard MFC after: 2 weeks Sponsored by: Dell EMC Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Tue Jun 19 23:30:55 2018 (r335390) +++ head/Makefile.inc1 Tue Jun 19 23:39:55 2018 (r335391) @@ -169,22 +169,6 @@ test-system-compiler: .PHONY .info SYSTEM_COMPILER: Determined that CC=${CC} matches the source tree. Not bootstrapping a cross-compiler. .endif -# For installworld need to ensure that the looked-up compiler metadata is -# passed along rather than trying to run cc from the restricted -# STRICTTMPPATH. -.if ${MK_CLANG_BOOTSTRAP} == "no" && ${MK_GCC_BOOTSTRAP} == "no" -.if !defined(X_COMPILER_TYPE) -CROSSENV+= COMPILER_VERSION=${COMPILER_VERSION} \ - COMPILER_TYPE=${COMPILER_TYPE} \ - COMPILER_FEATURES="${COMPILER_FEATURES}" \ - COMPILER_FREEBSD_VERSION=${COMPILER_FREEBSD_VERSION} -.else -CROSSENV+= COMPILER_VERSION=${X_COMPILER_VERSION} \ - COMPILER_FEATURES="${X_COMPILER_FEATURES}" \ - COMPILER_TYPE=${X_COMPILER_TYPE} \ - COMPILER_FREEBSD_VERSION=${X_COMPILER_FREEBSD_VERSION} -.endif -.endif # Store some compiler metadata for use in installworld where we don't # want to invoke CC at all. _COMPILER_METADATA_VARS= COMPILER_VERSION \ @@ -201,8 +185,10 @@ compiler-metadata.mk: .PHONY .META @echo "_LOADED_COMPILER_METADATA=t" >> ${.TARGET} .for v in ${_COMPILER_METADATA_VARS} @echo "${v}=${${v}}" >> ${.TARGET} + @echo "X_${v}=${X_${v}}" >> ${.TARGET} .endfor @echo ".export ${_COMPILER_METADATA_VARS}" >> ${.TARGET} + @echo ".export ${_COMPILER_METADATA_VARS:C,^,X_,}" >> ${.TARGET} # Handle external binutils. .if defined(CROSS_TOOLCHAIN_PREFIX)