summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorAdrian Ratiu <adrian.ratiu@collabora.com>2022-02-14 15:40:58 +0200
committerMatthew Pickering <matthewtpickering@gmail.com>2022-04-01 10:49:52 +0100
commitfb65e6e3e27a56cd16142c0eb7bd0a7e1e259742 (patch)
treeddbb498fd4683e8fa6bf46b7338dc4b4f3518584 /m4
parenta952dd80d40bf6b67194a44ff71d7bf75957d29e (diff)
downloadhaskell-fb65e6e3e27a56cd16142c0eb7bd0a7e1e259742.tar.gz
fp_prog_ar.m4: take AR var into consideration
In ChromeOS and Gentoo we want the ability to use LLVM ar instead of GNU ar even though both are installed, thus we pass (for eg) AR=llvm-ar to configure. Unfortunately GNU ar always gets picked regardless of the AR setting because the check does not consider the AR var when setting fp_prog_ar, hence this fix.
Diffstat (limited to 'm4')
-rw-r--r--m4/fp_prog_ar.m43
1 files changed, 2 insertions, 1 deletions
diff --git a/m4/fp_prog_ar.m4 b/m4/fp_prog_ar.m4
index 0ad6c694ac..1b74f7a795 100644
--- a/m4/fp_prog_ar.m4
+++ b/m4/fp_prog_ar.m4
@@ -14,7 +14,8 @@ if test -z "$fp_prog_ar"; then
fp_prog_ar=$(cygpath -m $fp_prog_ar)
fi
else
- AC_CHECK_TARGET_TOOL([fp_prog_ar], [ar])
+ AC_CHECK_TARGET_TOOL([AR], [ar])
+ fp_prog_ar="$AR"
fi
fi
if test -z "$fp_prog_ar"; then