Skip to content

Commit

Permalink
Use command -v for environments where which isn't available
Browse files Browse the repository at this point in the history
  • Loading branch information
jhasse committed Mar 18, 2019
1 parent 7ddda73 commit bfad59e
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions build-common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -283,14 +283,7 @@ check_md5sum ()
#
find_program ()
{
local PROG
PROG=`which $2 2>/dev/null`
if [ -n "$PROG" ] ; then
if pattern_match '^no ' "$PROG"; then
PROG=
fi
fi
eval $1="$PROG"
eval $1=`command -v $2`
}

prepare_download ()
Expand Down

0 comments on commit bfad59e

Please sign in to comment.