[Mesa-dev] [PATCH] configure: fix LLVM 4.0.0svn compilation, add libs for LLVM static linking

Eric Engestrom eric.engestrom at imgtec.com
Wed Jul 27 10:15:45 UTC 2016


On Tue, Jul 26, 2016 at 09:54:27PM +0200, Jan Ziak wrote:
> Signed-off-by: Jan Ziak (atom-symbol.net) <0xe2.0x9a.0x9b at gmail.com>
> ---
>  configure.ac | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 5c196a9..58c2db4 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -2187,6 +2187,7 @@ if test "x$enable_gallium_llvm" = xyes; then
>  
>              LLVM_COMPONENTS="${LLVM_COMPONENTS} all-targets ipo linker instrumentation"
>              LLVM_COMPONENTS="${LLVM_COMPONENTS} irreader option objcarcopts profiledata"
> +            LLVM_COMPONENTS="${LLVM_COMPONENTS} coverage"
>          fi
>          DEFINES="${DEFINES} -DHAVE_LLVM=0x0$LLVM_VERSION_INT -DMESA_LLVM_VERSION_PATCH=$LLVM_VERSION_PATCH"
>          MESA_LLVM=1
> @@ -2534,8 +2535,8 @@ if test "x$MESA_LLVM" != x0; then
>          AC_MSG_WARN([Building mesa with statically linked LLVM may cause compilation issues])
>          dnl We need to link to llvm system libs when using static libs
>          dnl However, only llvm 3.5+ provides --system-libs
> -        if test $LLVM_VERSION_MAJOR -eq 3 -a $LLVM_VERSION_MINOR -ge 5; then
> -            LLVM_LIBS="$LLVM_LIBS `$LLVM_CONFIG --system-libs`"
> +        if test $LLVM_VERSION_MAJOR -ge 4 -o $LLVM_VERSION_MAJOR -eq 3 -a $LLVM_VERSION_MINOR -ge 5; then
> +            LLVM_LIBS="$LLVM_LIBS `$LLVM_CONFIG --system-libs` $(pkg-config --libs ncurses zlib)"
>          fi
>      fi
>  fi

You're doing two unrelated changes, with two commit titles mashed
together... you can probably guess you should send those as two different
patches as well :)

The version change is good and would get my r-b, but the LLVM_COMPONENTS
change would need some testing to make sure it doesn't interfere with
anything before enabling it for everyone.

Cheers,
  Eric


More information about the mesa-dev mailing list