build: add busybox support to time prereq-check
Busybox time supports the GNU time '-f' syntax used by the build time
logging implemented in ff6e62b288, however the prerequisite check added
only works with GNU time installed as `time` or `gtime`.
As busybox is a multicall binary, the name of the symlink setup by
SetupHostCommand also must be changed from `gtime` to `time` to fix the
value of argv[0]. This causes a number of shells (including bash) to use
their builtin impelementation of time, so the sole invocation has been
changed to use `env time` to use the value found on the $PATH.
Signed-off-by: Andy Boyett <agb@agb.io>
This commit is contained in:
committed by
John Crispin
parent
b1a173d7c3
commit
591780615b
@@ -138,9 +138,10 @@ $(eval $(call SetupHostCommand,bzip2,Please install 'bzip2', \
|
||||
$(eval $(call SetupHostCommand,wget,Please install GNU 'wget', \
|
||||
wget --version | grep GNU))
|
||||
|
||||
$(eval $(call SetupHostCommand,gtime,Please install GNU 'time', \
|
||||
$(eval $(call SetupHostCommand,time,Please install GNU 'time' or BusyBox 'time', \
|
||||
gtime --version 2>&1 | grep GNU, \
|
||||
time --version 2>&1 | grep GNU))
|
||||
time --version 2>&1 | grep GNU, \
|
||||
busybox time 2>&1 | grep BusyBox))
|
||||
|
||||
$(eval $(call SetupHostCommand,perl,Please install Perl 5.x, \
|
||||
perl --version | grep "perl.*v5"))
|
||||
|
||||
Reference in New Issue
Block a user