[Mesa-dev] [PATCH] anv: Link to libX11-xcb only when unneeded

Nanley Chery nanleychery at gmail.com
Thu Sep 8 16:12:03 UTC 2016


Should the title the say needed instead of unneeded?

- Nanley

On Wed, Sep 07, 2016 at 08:29:30PM -0700, Chad Versace wrote:
> The Makefile unconditionally linked libX11-xcb into libvulkan_intel.so.
> But it's needed only if HAVE_PLATFORM_X11.
> 
> Fixes build of libvulkan_intel.so on Chromium OS, which has no X11
> libraries.
> 
> Cc: Kevin Strasser <kevin.strasser at intel.com>
> Cc: Jason Ekstrand <jason at jlekstrand.net>
> Change-Id: Ib42db7db582c4531cf13db65f2ad5d57db1d774d
> ---
>  src/intel/vulkan/Makefile.am | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/src/intel/vulkan/Makefile.am b/src/intel/vulkan/Makefile.am
> index 2d20de9..cf16ea4 100644
> --- a/src/intel/vulkan/Makefile.am
> +++ b/src/intel/vulkan/Makefile.am
> @@ -91,7 +91,9 @@ AM_CPPFLAGS += \
>  	-DVK_USE_PLATFORM_XLIB_KHR
>  
>  VULKAN_SOURCES += $(VULKAN_WSI_X11_FILES)
> -VULKAN_LIB_DEPS += $(XCB_DRI3_LIBS)
> +
> +# FIXME: Use pkg-config for X11-xcb ldflags.
> +VULKAN_LIB_DEPS += $(XCB_DRI3_LIBS) -lX11-xcb
>  endif
>  
>  
> @@ -149,7 +151,7 @@ EXTRA_DIST = \
>  	dev_icd.json.in \
>  	intel_icd.json
>  
> -libvulkan_intel_la_LIBADD = $(VULKAN_LIB_DEPS) -lX11-xcb
> +libvulkan_intel_la_LIBADD = $(VULKAN_LIB_DEPS)
>  
>  libvulkan_intel_la_LDFLAGS = \
>  	-shared \
> @@ -184,7 +186,7 @@ intel_icd.json : intel_icd.json.in
>  
>  # Libvulkan with dummy gem. Used for unit tests.
>  libvulkan_test_la_SOURCES = $(VULKAN_GEM_STUB_FILES)
> -libvulkan_test_la_LIBADD = $(VULKAN_LIB_DEPS) -lX11-xcb
> +libvulkan_test_la_LIBADD = $(VULKAN_LIB_DEPS)
>  
>  include $(top_srcdir)/install-lib-links.mk
>  
> -- 
> 2.10.0
> 
> _______________________________________________
> 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