Skip to content
  • Tobias Droste's avatar
    configure.ac: Check gallium LLVM version in gallium_require_llvm · b3119a33
    Tobias Droste authored
    
    
    This moves the LLVM version check to the helper function
    gallium_require_llvm() and uses the llvm_check_version_for() helper
    instead of open conding the LLVM version check.
    
    gallium_require_llvm is functionally the same as before, because
    "enable_gallium_llvm" is only set to "yes" if the host cpu is x86:
    
    if test "x$enable_gallium_llvm" = xauto; then
        case "$host_cpu" in
        i*86|x86_64|amd64) enable_gallium_llvm=yes;;
        esac
    fi
    
    This function is also only called now when needed.
    Before this patch llvmpipe would call this as soon as LLVM is
    installed. Now it only gets called by llvmpipe if gallium
    LLVM is actually enabled (i.e. only on x86).
    
    Both reasons mentioned above remove the need to check host cpu
    in the gallium_require_llvm function.
    
    Signed-off-by: default avatarTobias Droste <tdroste@gmx.de>
    Reviewed-by: default avatarEmil Velikov <emil.velikov@collabora.com>
    b3119a33