From 84927818ee68c6826327abc26d4647fb56053fb7 Mon Sep 17 00:00:00 2001 From: Ben Gamari Date: Tue, 9 Mar 2021 11:37:18 -0500 Subject: llvmGen: Accept range of LLVM versions Previously we would support only one LLVM major version. Here we generalize this to accept a range, taking this range to be LLVM 10 to 11, as 11 is necessary for Apple M1 support. We also accept 12, as that is what apple ships with BigSur on the M1. --- distrib/configure.ac.in | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'distrib') diff --git a/distrib/configure.ac.in b/distrib/configure.ac.in index 4de89941df..c287c3368d 100644 --- a/distrib/configure.ac.in +++ b/distrib/configure.ac.in @@ -118,19 +118,20 @@ AC_SUBST([StripCmd]) # tools we are looking for. In the past, GHC supported a number of # versions of LLVM simultaneously, but that stopped working around # 3.5/3.6 release of LLVM. -LlvmVersion=@LlvmVersion@ +LlvmMinVersion=@LlvmMinVersion@ +LlvmMaxVersion=@LlvmMaxVersion@ dnl ** Which LLVM llc to use? dnl -------------------------------------------------------------- AC_ARG_VAR(LLC,[Use as the path to LLVM's llc [default=autodetect]]) -FIND_LLVM_PROG([LLC], [llc], [$LlvmVersion]) +FIND_LLVM_PROG([LLC], [llc], [$LlvmMinVersion], [$LlvmMaxVersion]) LlcCmd="$LLC" AC_SUBST([LlcCmd]) dnl ** Which LLVM opt to use? dnl -------------------------------------------------------------- AC_ARG_VAR(OPT,[Use as the path to LLVM's opt [default=autodetect]]) -FIND_LLVM_PROG([OPT], [opt], [$LlvmVersion]) +FIND_LLVM_PROG([OPT], [opt], [$LlvmMinVersion], [$LlvmMaxVersion]) OptCmd="$OPT" AC_SUBST([OptCmd]) -- cgit v1.2.1