gallium: Fix automake for Android (v2)

Chromium OS uses Autotools and pkg-config when building Mesa for
Android. The gallium drivers were failing to find the headers and
libraries for zlib and Android's libbacktrace.

v2:
  - Don't add a check for zlib.pc. configure.ac already checks for
    zlib.pc elsewhere. [for tfiga]
  - Check for backtrace.pc separately from the other Android libs.
    [for tfiga]

Reviewed-by: Tomasz Figa <tfiga@chromium.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
This commit is contained in:
Chad Versace 2018-05-31 19:57:55 -07:00
parent 2a5121bf35
commit dc6665422a
3 changed files with 13 additions and 0 deletions

View file

@ -1836,6 +1836,9 @@ for plat in $platforms; do
android)
PKG_CHECK_MODULES([ANDROID], [cutils hardware sync])
if test -n "$with_gallium_drivers"; then
PKG_CHECK_MODULES([BACKTRACE], [backtrace])
fi
DEFINES="$DEFINES -DHAVE_ANDROID_PLATFORM"
;;

View file

@ -59,6 +59,12 @@ GALLIUM_COMMON_LIB_DEPS += \
$(LIBDRM_LIBS)
endif
if HAVE_PLATFORM_ANDROID
GALLIUM_COMMON_LIB_DEPS += \
$(ANDROID_LIBS) \
$(BACKTRACE_LIBS)
endif
GALLIUM_WINSYS_CFLAGS = \
-I$(top_srcdir)/src \
-I$(top_srcdir)/include \

View file

@ -21,6 +21,10 @@ libgallium_la_SOURCES = \
$(NIR_SOURCES) \
$(GENERATED_SOURCES)
if HAVE_PLATFORM_ANDROID
libgallium_la_SOURCES += util/u_debug_stack_android.cpp
endif
if HAVE_LIBDRM
AM_CFLAGS += \