aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOmar Polo <op@omarpolo.com>2022-03-18 16:31:05 +0000
committerOmar Polo <op@omarpolo.com>2022-03-18 16:31:05 +0000
commit9db5e7051ebb37a9078e79ca46daf7f8f8f3f963 (patch)
tree093cd3e5c2264b88ba522f45cbfb58f9b445d8f7
parent5f966fbe41a18d9ad1577d659da5990994c851bc (diff)
get rid of `which` in the configure too
should have been done already in 12fcba2; reminded by Allen Sobot, thanks!
-rwxr-xr-xconfigure6
1 files changed, 3 insertions, 3 deletions
diff --git a/configure b/configure
index 372b613..74c8e3d 100755
--- a/configure
+++ b/configure
@@ -72,7 +72,7 @@ add_library() {
}
# try to auto detect CFLAGS and LDFLAGS
-if which pkg-config 2>/dev/null 1>&2; then
+if command -v pkg-config >/dev/null; then
add_library "libtls"
add_library "openssl"
@@ -96,11 +96,11 @@ if which pkg-config 2>/dev/null 1>&2; then
fi
# auto detect yacc/bison
-which ${YACC} 2>/dev/null 1>&2 || {
+command -v ${YACC} >/dev/null || {
echo "${YACC} not found: trying bison" 1>&2
echo "${YACC} not found: trying bison" 1>&3
YACC=bison
- which ${YACC} 2>/dev/null 1>&2 || {
+ command -v ${YACC} >/dev/null || {
echo "${YACC} not found: giving up" 1>&2
echo "${YACC} not found: giving up" 1>&3
}