From nobody Tue Jan 9 04:22:42 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4T8HpW3TQCz563lH; Tue, 9 Jan 2024 04:22:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4T8HpW0S09z4lcn; Tue, 9 Jan 2024 04:22:43 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704774163; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wU2aXlIUnITOmDVvHe/b8tN40+Aw9cSKP6Ik6/afJgw=; b=GhhNo6Te/qGd96wt17IP0NhPYmABuIugcF5NFfuOBY3upKw5z+y7UxC/b4blNebLIi87SM NXaDrgP1tysQEF3P3sWfhDRduP7C6GC89wLJnuRrRSIh41O3JeyRHqW/Q10KEs9h+4TU4O vJJlZWfgtY+tKzmBrrnOTScGepnQdli0eseXhc84LyG03olsPGzrstHf8ki2lwJln4LDfg YenLC9x+kA3/5G9uLoKeuRaCj1DPmf0DF95TBhZsbBX/CzE84TXT4Mk7M9ZGJ8AuSR9+9A sedl3xqVut/IGIajlNlIFiOyETfI/xCJe9xDaLQ7E8TobTLlcN0wWNMv8bRTbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1704774163; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=wU2aXlIUnITOmDVvHe/b8tN40+Aw9cSKP6Ik6/afJgw=; b=EIrmP+8KJyEpbhdyYJ5VLWPmwEmT4UiOpafdue/6sMOrc07gks3mTGUa1UuVNNcneSaVc7 ac6v8cqYEvGiuOQk4hSXziXWcUACUyKq+q6eVnuY1JsoVi7rXWH7rQkF/FT/0p/97roUXv /gNkvvc5Hm71jMaK5LNgayRIGMIS3GkzklghepgvfPIr0uRSvqTvPvi+dnkTOW/nfHH6Z6 BZKIPMusDOZwCYzF5rdI3S6+m7Uqh74fNVo+RaKzkCv/9eyp5gA2OLLQWD8Bhrn2BoVmeu 1/exavkD7vdm9XkLaqkA/xRAieil8vpfV6eovhoPEKwBCcgtpFxoETSKGAgYyA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1704774163; a=rsa-sha256; cv=none; b=ZyJ5d/+/KztBZGPY36KK9QabdCP0WULvqdA/kifeMbbqY8wbYWw27mCp7ALkYfHhW6pO9K HRpfiKGaEZmgv4/TJHMWfFUyxG8T+e6fRlyEezazYIKE8h3I84WhBcmMiefExWuCaUVmeN OippB6v5AileWPGwdz2BZAdt7iBt8KX4EY0MfL60TVsWu0P/9Rod36jVdmYOEJF0fUZYLn abcwCKYACnHEbuvfXk7uYlrGFwBvENtnEZXfglrX9pD+gsDFSfrq2ll50wRFKqW69dIltC mEfn8ktnGAzpCFrfNlml/16IZw3NHRfXsXDtgherCFH1V1Gz6G+7daEI3QRlEw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4T8HpV6dwRzcHc; Tue, 9 Jan 2024 04:22:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 4094MgEW015281; Tue, 9 Jan 2024 04:22:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 4094Mgd3015279; Tue, 9 Jan 2024 04:22:42 GMT (envelope-from git) Date: Tue, 9 Jan 2024 04:22:42 GMT Message-Id: <202401090422.4094Mgd3015279@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 5d1ecf0b6184 - main - build: only inspect the first word of toolchain tools List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5d1ecf0b6184748a51bca01b497c808c3e13aa67 Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=5d1ecf0b6184748a51bca01b497c808c3e13aa67 commit 5d1ecf0b6184748a51bca01b497c808c3e13aa67 Author: Kyle Evans AuthorDate: 2024-01-09 04:21:36 +0000 Commit: Kyle Evans CommitDate: 2024-01-09 04:22:25 +0000 build: only inspect the first word of toolchain tools CC/CXX/CPP/LD may all have arguments supplied in various circumstances, which break the logic here. We only need to determine which of these tools we're expecting to invoke from PATH, which just requires examination of the first word. Limit our scope to exactly that. Patch suggested by: jrtc27 Reviewed by: imp, jrtc27 Differential Revision: https://reviews.freebsd.org/D43372 --- tools/build/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/build/Makefile b/tools/build/Makefile index 187d5593564d..e60c8694d56d 100644 --- a/tools/build/Makefile +++ b/tools/build/Makefile @@ -370,9 +370,9 @@ _WRAP_HOST_TOOL= ${_LINK_HOST_TOOL} .endif .for var in CC CXX CPP LD .for X in $${_empty_var_} X -.if !empty(${X}${var}) && !${${X}${var}:M/*} && \ - !${_toolchain_tools_to_symlink:U:M${${X}${var}}} -_toolchain_tools_to_symlink+= ${${X}${var}} +.if !empty(${X}${var}) && !${${X}${var}:[1]:M/*} && \ + !${_toolchain_tools_to_symlink:U:M${${X}${var}:[1]}} +_toolchain_tools_to_symlink+= ${${X}${var}:[1]} .endif .endfor .endfor