[Mesa-dev] [PATCH] util/disk_cache: fix zlib linking with LTO build

Marek Olšák maraeo at gmail.com
Fri Mar 10 12:03:37 UTC 2017


Acked-by: Marek Olšák <marek.olsak at amd.com>

Marek

On Thu, Mar 9, 2017 at 3:39 PM, Steven Newbury <steve at snewbury.org.uk> wrote:
> Introduction of zlib compression for the shader cache means
> zlib needs to be explicitly linked to libOSMesa and libstandalone
> otherwise build fails when LTO is used.
> ---
>  src/compiler/Makefile.glsl.am          | 1 +
>  src/gallium/targets/osmesa/Makefile.am | 3 ++-
>  2 files changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/src/compiler/Makefile.glsl.am
> b/src/compiler/Makefile.glsl.am
> index 41edb3cf4d..7be607c74c 100644
> --- a/src/compiler/Makefile.glsl.am
> +++ b/src/compiler/Makefile.glsl.am
> @@ -141,6 +141,7 @@ glsl_libstandalone_la_LIBADD =
>         \
>         glsl/libglsl.la                                 \
>         $(top_builddir)/src/libglsl_util.la             \
>         $(top_builddir)/src/util/libmesautil.la         \
> +       $(ZLIB_LIBS)                                    \
>         $(PTHREAD_LIBS)
>
>  glsl_compiler_SOURCES = \
> diff --git a/src/gallium/targets/osmesa/Makefile.am
> b/src/gallium/targets/osmesa/Makefile.am
> index 6d340f1d92..b7b9248126 100644
> --- a/src/gallium/targets/osmesa/Makefile.am
> +++ b/src/gallium/targets/osmesa/Makefile.am
> @@ -66,7 +66,8 @@ lib at OSMESA_LIB@_la_LIBADD = \
>         $(top_builddir)/src/mapi/glapi/libglapi.la \
>         $(SHARED_GLAPI_LIB) \
>         $(OSMESA_LIB_DEPS) \
> -       $(CLOCK_LIB)
> +       $(CLOCK_LIB) \
> +       $(ZLIB_LIBS)
>
>  if HAVE_GALLIUM_LLVM
>  AM_CPPFLAGS += -DGALLIUM_LLVMPIPE
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>


More information about the mesa-dev mailing list