From owner-dev-commits-src-main@freebsd.org Thu Jan 14 06:38:58 2021 Return-Path: Delivered-To: dev-commits-src-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 856334D73A9; Thu, 14 Jan 2021 06:38:58 +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 "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4DGZQp3N0Kz4s7B; Thu, 14 Jan 2021 06:38:58 +0000 (UTC) (envelope-from git@FreeBSD.org) 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 66B4725774; Thu, 14 Jan 2021 06:38:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 10E6cwPJ032885; Thu, 14 Jan 2021 06:38:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 10E6cwWg032884; Thu, 14 Jan 2021 06:38:58 GMT (envelope-from git) Date: Thu, 14 Jan 2021 06:38:58 GMT Message-Id: <202101140638.10E6cwWg032884@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: 986deea5b518 - main - build: `make check`: use a PATH search instead for Kyua 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: 986deea5b518ee5bf6b8b1486056a21819bd8bd2 Auto-Submitted: auto-generated X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for the main branch of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jan 2021 06:38:58 -0000 The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=986deea5b518ee5bf6b8b1486056a21819bd8bd2 commit 986deea5b518ee5bf6b8b1486056a21819bd8bd2 Author: Kyle Evans AuthorDate: 2021-01-14 06:34:29 +0000 Commit: Kyle Evans CommitDate: 2021-01-14 06:37:48 +0000 build: `make check`: use a PATH search instead for Kyua which(1) accepts both relative/absolute paths as well as lone binary names. Set KYUA to kyua and use which(1) to confirm that it can find one; if it cannot, just advise the user to set KYUA directly to the kyua binary rather than assuming a relative location from LOCALBASE. This allows `make check` to be operated with the version of kyua in base without losing the flexibility of specifying another one. ngie@ notes that the original intention was to avoid redundant $PATH lookups and improve the determinism of the target. A future change will likely push us back to this state, perhaps in the form of reverting this entirely and just switching to using kyua in base. Accepting any in $PATH should be considered a transitional move, at least until it's declared otherwise, since kyua was only semi-recently added to base. Reviewed-by: brooks, emaste, lwhsu, ngie Differential-Revision: https://reviews.freebsd.org/D28045 --- share/mk/suite.test.mk | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/share/mk/suite.test.mk b/share/mk/suite.test.mk index 69cd02d684de..e772ccd1b292 100644 --- a/share/mk/suite.test.mk +++ b/share/mk/suite.test.mk @@ -77,7 +77,7 @@ Kyuafile: Makefile @mv ${.TARGET}.tmp ${.TARGET} .endif -KYUA= ${LOCALBASE}/bin/kyua +KYUA?= kyua # Definition of the "make check" target and supporting variables. # @@ -90,13 +90,13 @@ KYUA= ${LOCALBASE}/bin/kyua # report bogus results unless the new binaries are put in place. realcheck: .PHONY - @if [ ! -x ${KYUA} ]; then \ + if ! which -s "${KYUA}"; then \ echo; \ echo "kyua binary not installed at expected location (${.TARGET})"; \ echo; \ echo "Please install via pkg install, or specify the path to the kyua"; \ - echo "package via the \$${LOCALBASE} variable, e.g. "; \ - echo "LOCALBASE=\"${LOCALBASE}\""; \ + echo "binary via the \$${KYUA} variable, e.g., "; \ + echo "KYUA=\"${LOCALBASE}/bin/kyua\""; \ false; \ fi @env ${TESTS_ENV:Q} ${KYUA} test -k ${DESTDIR}${TESTSDIR}/Kyuafile