HomeFreeBSD

Makefile.inc1: Avoid hanging if pkg is not installed

Description

Makefile.inc1: Avoid hanging if pkg is not installed

For pkg --version, Redirect stdin from /dev/null to avoid waiting on
/usr/sbin/pkg's bootstrap prompt if the pkg package is not installed.
Also redirect stderr to /dev/null to discard the warning message in
this case.

Reported by: mjg
Fixes: 4e224e4be7c3 ("pkgbase: accommodate pkg < 1.17")
Sponsored by: The FreeBSD Foundation

Details

Provenance
emasteAuthored on Aug 8 2021, 1:50 AM
Parents
rG1f88aa09417f: zfs: merge openzfs/zfs@f3678d70f (master) into main
Branches
Unknown
Tags
Unknown