On Fri, 5 Jun 2026 at 20:56, Andrew Pinski <[email protected]> wrote: > > On Fri, Jun 5, 2026 at 8:05 AM Jonathan Wakely <[email protected]> wrote: > > > > If wget is not installed, this script prints a message to standard error > > which makes it looks like something is wrong: > > > > ./contrib/download_prerequisites: line 53: type: wget: not found > > > > But if curl is installed then the script works fine. The command should > > also redirect stderr with 2>&1 but it seems preferable to just replace > > the use of 'type' with 'command -v' which is silent when the command is > > not found. > > > > Also add an explicit check for curl and print a more helpful error if > > not found. > > > > contrib/ChangeLog: > > > > * download_prerequisites: use 'command -v' to check for wget and > > curl. > > --- > > > > OK for trunk? > > Ok. I went and checked that POSIX-2004 defined command the say way. > Just in case there was any portability issues with some older systems.
Yeah, and it works in dash and on AIX (ksh) and Solaris (ksh93). Pushed to trunk, thanks.
