Page MenuHomeFreeBSD

build: `make check`: use a PATH search instead for Kyua
ClosedPublic

Authored by kevans on Jan 8 2021, 8:14 PM.

Details

Reviewers
ngie
brooks
lwhsu
emaste
Group Reviewers
tests
Summary

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.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 36042
Build 32931: arc lint + arc unit

Event Timeline

kevans requested review of this revision.Jan 8 2021, 8:14 PM

Add in the problem we're solving; wanting to use kyua in base.

This revision is now accepted and ready to land.Jan 8 2021, 10:19 PM

The reason why I hardcoded the path was to reduce redundant $PATH lookups and to ensure that random kyua(1) binaries wouldn't get picked up from someone's environment, increasing overall determinism of the target.

I prefer the old method, but also acknowledge that making this work more out of the box is more important for widespread adoption of the target.

share/mk/suite.test.mk
98

Grammar nit: e.g. must be followed by a comma: , e.g., .

I just ran into this issue and ended up making an equivalent fix in my tree.