Some OS may have the true bin to a different location than /bin/true.
BSD based system and macos have true on /usr/bin/true.
Fix this by checking both location and take the one available in the
system.
Reported-by: Sergey V. Lobanov <sergey@lobanov.in>
Suggested-by: Huangbin Zhan <zhanhb88@gmail.com>
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
# Install ldconfig stub
$(eval $(call TestHostCommand,ldconfig-stub,Failed to install stub, \
- $(LN) /bin/true $(STAGING_DIR_HOST)/bin/ldconfig))
+ $(LN) $(firstword $(wildcard /bin/true /usr/bin/true)) $(STAGING_DIR_HOST)/bin/ldconfig))