Commit 7b78543b authored by ian@well-typed.com's avatar ian@well-typed.com
Browse files

Improve the testsuite's LLVM detection

parent 10081794
......@@ -26,6 +26,7 @@ main = do
getGhcFieldOrDefault fields "GhcDynamicByDefault" "Dynamic by default" "NO"
getGhcFieldOrDefault fields "GhcDynamic" "GHC Dynamic" "NO"
getGhcFieldProgWithDefault fields "AR" "ar command" "ar"
getGhcFieldProgWithDefault fields "LLC" "LLVM llc command" "llc"
let pkgdb_flag = case lookup "Project version" fields of
Just v
......
......@@ -118,7 +118,12 @@ else
RUNTEST_OPTS += -e ghc_with_smp=0
endif
ifneq "$(shell $(SHELL) -c 'llc --version | grep version' 2> /dev/null)" ""
ifeq "$(LLC)" ""
RUNTEST_OPTS += -e ghc_with_llvm=0
else ifneq "$(LLC)" "llc"
# If we have a real detected value for LLVM, then it really ought to work
RUNTEST_OPTS += -e ghc_with_llvm=1
else ifneq "$(shell $(SHELL) -c 'llc --version | grep version' 2> /dev/null)" ""
RUNTEST_OPTS += -e ghc_with_llvm=1
else
RUNTEST_OPTS += -e ghc_with_llvm=0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment