Commit d4840c0c authored by Emil Velikov's avatar Emil Velikov Committed by Emil Velikov

configure.ac: correctly manage llvm auto-detection

Earlier refactoring commits changed from one, dare I say it, broken
behaviour to another. Namely:

Before, as you explicitly --enable-gallium-llvm your selection was
ignored when llvm-config was not present/detected.
Today, the "auto" heuristics enables gallium llvm regardless if you have
llvm/llvm-config available or not.

Rework the auto-detection to attribute for llvm's presence.

v2: Set enable_gallium_llvm=no when LLVM is not found.

Cc: "17.0" <mesa-stable@lists.freedesktop.org>
Signed-off-by: default avatarEmil Velikov <emil.velikov@collabora.com>
Reviewed-by: default avatarTobias Droste <tdroste@gmx.de>
Reported-by: Samuel Pitoiset's avatarSamuel Pitoiset <samuel.pitoiset@gmail.com>
Tested-by: Samuel Pitoiset's avatarSamuel Pitoiset <samuel.pitoiset@gmail.com>
parent ce65cc1f
......@@ -1729,10 +1729,14 @@ AC_ARG_ENABLE([gallium-llvm],
[enable_gallium_llvm=auto])
if test "x$enable_gallium_llvm" = xauto; then
case "$host_cpu" in
i*86|x86_64|amd64) enable_gallium_llvm=yes;;
*) enable_gallium_llvm=no;;
esac
if test "x$FOUND_LLVM" = xyes; then
case "$host_cpu" in
i*86|x86_64|amd64) enable_gallium_llvm=yes;;
*) enable_gallium_llvm=no;;
esac
else
enable_gallium_llvm=no
fi
fi
if test "x$enable_gallium_llvm" = xyes -a "x$FOUND_LLVM" = xno; then
......
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