diff options
Diffstat (limited to 'lib/mesa/src/egl')
-rw-r--r-- | lib/mesa/src/egl/Makefile.in | 368 | ||||
-rw-r--r-- | lib/mesa/src/egl/drivers/dri2/egl_dri2.c | 100 | ||||
-rw-r--r-- | lib/mesa/src/egl/drivers/dri2/platform_x11.c | 203 | ||||
-rw-r--r-- | lib/mesa/src/egl/wayland/wayland-drm/Makefile.in | 30 | ||||
-rw-r--r-- | lib/mesa/src/egl/wayland/wayland-egl/Makefile.in | 30 |
5 files changed, 438 insertions, 293 deletions
diff --git a/lib/mesa/src/egl/Makefile.in b/lib/mesa/src/egl/Makefile.in index cc2ead011..41dbe6553 100644 --- a/lib/mesa/src/egl/Makefile.in +++ b/lib/mesa/src/egl/Makefile.in @@ -77,11 +77,10 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ target_triplet = @target@ -DIST_COMMON = $(egl_HEADERS) $(khr_HEADERS) $(srcdir)/Makefile.am \ +DIST_COMMON = $(egl_HEADERS) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/Makefile.sources \ $(top_srcdir)/bin/depcomp $(top_srcdir)/install-lib-links.mk -@HAVE_PLATFORM_X11_TRUE@am__append_1 = -DHAVE_X11_PLATFORM \ -@HAVE_PLATFORM_X11_TRUE@ $(XCB_DRI2_CFLAGS) +@HAVE_PLATFORM_X11_TRUE@am__append_1 = $(XCB_DRI2_CFLAGS) @HAVE_PLATFORM_X11_TRUE@am__append_2 = $(XCB_DRI2_LIBS) @HAVE_PLATFORM_X11_TRUE@am__append_3 = drivers/dri2/platform_x11.c @HAVE_DRI3_TRUE@@HAVE_PLATFORM_X11_TRUE@am__append_4 = \ @@ -89,37 +88,20 @@ DIST_COMMON = $(egl_HEADERS) $(khr_HEADERS) $(srcdir)/Makefile.am \ @HAVE_DRI3_TRUE@@HAVE_PLATFORM_X11_TRUE@ drivers/dri2/platform_x11_dri3.h @HAVE_DRI3_TRUE@@HAVE_PLATFORM_X11_TRUE@am__append_5 = $(top_builddir)/src/loader/libloader_dri3_helper.la -@HAVE_PLATFORM_WAYLAND_TRUE@am__append_6 = -DHAVE_WAYLAND_PLATFORM \ -@HAVE_PLATFORM_WAYLAND_TRUE@ $(WAYLAND_CFLAGS) +@HAVE_PLATFORM_WAYLAND_TRUE@am__append_6 = $(WAYLAND_CFLAGS) @HAVE_PLATFORM_WAYLAND_TRUE@am__append_7 = $(WAYLAND_LIBS) \ @HAVE_PLATFORM_WAYLAND_TRUE@ $(LIBDRM_LIBS) \ @HAVE_PLATFORM_WAYLAND_TRUE@ $(top_builddir)/src/egl/wayland/wayland-drm/libwayland-drm.la @HAVE_PLATFORM_WAYLAND_TRUE@am__append_8 = drivers/dri2/platform_wayland.c -@HAVE_EGL_PLATFORM_DRM_TRUE@am__append_9 = -DHAVE_DRM_PLATFORM -@HAVE_EGL_PLATFORM_DRM_TRUE@am__append_10 = $(top_builddir)/src/gbm/libgbm.la -@HAVE_EGL_PLATFORM_DRM_TRUE@am__append_11 = drivers/dri2/platform_drm.c -@HAVE_EGL_PLATFORM_SURFACELESS_TRUE@am__append_12 = -DHAVE_SURFACELESS_PLATFORM -@HAVE_EGL_PLATFORM_SURFACELESS_TRUE@am__append_13 = drivers/dri2/platform_surfaceless.c -@HAVE_EGL_PLATFORM_ANDROID_TRUE@am__append_14 = -DHAVE_ANDROID_PLATFORM -@HAVE_EGL_PLATFORM_ANDROID_TRUE@am__append_15 = drivers/dri2/platform_android.c -@HAVE_EGL_DRIVER_DRI2_TRUE@am__append_16 = \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_srcdir)/src/loader \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_srcdir)/src/egl/drivers/dri2 \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_srcdir)/src/gbm/backends/dri \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_srcdir)/src/egl/wayland/wayland-egl \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_builddir)/src/egl/wayland/wayland-drm \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -I$(top_srcdir)/src/egl/wayland/wayland-drm \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -DDEFAULT_DRIVER_DIR=\"$(DRI_DRIVER_SEARCH_DIR)\" \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ -D_EGL_BUILT_IN_DRIVER_DRI2 - -@HAVE_EGL_DRIVER_DRI2_TRUE@am__append_17 = \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(dri2_backend_core_FILES) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(dri2_backend_FILES) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(dri3_backend_FILES) - -@HAVE_EGL_DRIVER_DRI2_TRUE@am__append_18 = $(top_builddir)/src/loader/libloader.la \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(DLOPEN_LIBS) $(LIBDRM_LIBS) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(CLOCK_LIB) +@HAVE_PLATFORM_DRM_TRUE@am__append_9 = $(top_builddir)/src/gbm/libgbm.la +@HAVE_PLATFORM_DRM_TRUE@am__append_10 = drivers/dri2/platform_drm.c +@HAVE_PLATFORM_SURFACELESS_TRUE@am__append_11 = drivers/dri2/platform_surfaceless.c +@HAVE_PLATFORM_ANDROID_TRUE@am__append_12 = $(ANDROID_CFLAGS) +@HAVE_PLATFORM_ANDROID_TRUE@am__append_13 = $(ANDROID_LIBS) +@HAVE_PLATFORM_ANDROID_TRUE@am__append_14 = drivers/dri2/platform_android.c +@USE_LIBGLVND_TRUE@am__append_15 = \ +@USE_LIBGLVND_TRUE@ $(GLVND_CFLAGS) + subdir = src/egl ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_gnu_make.m4 \ @@ -165,22 +147,33 @@ am__uninstall_files_from_dir = { \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(pkgconfigdir)" \ - "$(DESTDIR)$(egldir)" "$(DESTDIR)$(khrdir)" -LTLIBRARIES = $(lib_LTLIBRARIES) + "$(DESTDIR)$(vendorjsondir)" "$(DESTDIR)$(egldir)" +LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) +@USE_LIBGLVND_FALSE@libEGL_la_DEPENDENCIES = libEGL_common.la +am_libEGL_la_OBJECTS = +libEGL_la_OBJECTS = $(am_libEGL_la_OBJECTS) +AM_V_lt = $(am__v_lt_@AM_V@) +am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) +am__v_lt_0 = --silent +am__v_lt_1 = +libEGL_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ + $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ + $(libEGL_la_LDFLAGS) $(LDFLAGS) -o $@ +@USE_LIBGLVND_FALSE@am_libEGL_la_rpath = -rpath $(libdir) am__DEPENDENCIES_1 = @HAVE_PLATFORM_X11_TRUE@am__DEPENDENCIES_2 = $(am__DEPENDENCIES_1) @HAVE_PLATFORM_WAYLAND_TRUE@am__DEPENDENCIES_3 = \ @HAVE_PLATFORM_WAYLAND_TRUE@ $(am__DEPENDENCIES_1) \ @HAVE_PLATFORM_WAYLAND_TRUE@ $(am__DEPENDENCIES_1) \ @HAVE_PLATFORM_WAYLAND_TRUE@ $(top_builddir)/src/egl/wayland/wayland-drm/libwayland-drm.la -@HAVE_EGL_DRIVER_DRI2_TRUE@am__DEPENDENCIES_4 = $(top_builddir)/src/loader/libloader.la \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(am__DEPENDENCIES_1) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(am__DEPENDENCIES_1) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(am__DEPENDENCIES_1) -libEGL_la_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_2) \ - $(am__append_5) $(am__DEPENDENCIES_3) $(am__append_10) \ - $(am__DEPENDENCIES_4) -am__libEGL_la_SOURCES_DIST = main/eglapi.c main/eglapi.h \ +@HAVE_PLATFORM_ANDROID_TRUE@am__DEPENDENCIES_4 = \ +@HAVE_PLATFORM_ANDROID_TRUE@ $(am__DEPENDENCIES_1) +libEGL_common_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_2) $(am__append_5) $(am__DEPENDENCIES_3) \ + $(am__append_9) $(am__DEPENDENCIES_4) \ + $(top_builddir)/src/loader/libloader.la $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) +am__libEGL_common_la_SOURCES_DIST = main/eglapi.c main/eglapi.h \ main/eglarray.c main/eglarray.h main/eglcompiler.h \ main/eglconfig.c main/eglconfig.h main/eglcontext.c \ main/eglcontext.h main/eglcurrent.c main/eglcurrent.h \ @@ -189,10 +182,10 @@ am__libEGL_la_SOURCES_DIST = main/eglapi.c main/eglapi.h \ main/eglglobals.c main/eglglobals.h main/eglimage.c \ main/eglimage.h main/egllog.c main/egllog.h main/eglsurface.c \ main/eglsurface.h main/eglsync.c main/eglsync.h \ - main/egltypedefs.h drivers/dri2/egl_dri2.c \ - drivers/dri2/egl_dri2.h drivers/dri2/egl_dri2_fallbacks.h \ - drivers/dri2/platform_x11.c drivers/dri2/platform_wayland.c \ - drivers/dri2/platform_drm.c \ + main/eglentrypoint.h main/egltypedefs.h \ + drivers/dri2/egl_dri2.c drivers/dri2/egl_dri2.h \ + drivers/dri2/egl_dri2_fallbacks.h drivers/dri2/platform_x11.c \ + drivers/dri2/platform_wayland.c drivers/dri2/platform_drm.c \ drivers/dri2/platform_surfaceless.c \ drivers/dri2/platform_android.c \ drivers/dri2/platform_x11_dri3.c \ @@ -207,25 +200,30 @@ am__objects_2 = drivers/dri2/egl_dri2.lo @HAVE_PLATFORM_X11_TRUE@am__objects_3 = drivers/dri2/platform_x11.lo @HAVE_PLATFORM_WAYLAND_TRUE@am__objects_4 = \ @HAVE_PLATFORM_WAYLAND_TRUE@ drivers/dri2/platform_wayland.lo -@HAVE_EGL_PLATFORM_DRM_TRUE@am__objects_5 = \ -@HAVE_EGL_PLATFORM_DRM_TRUE@ drivers/dri2/platform_drm.lo -@HAVE_EGL_PLATFORM_SURFACELESS_TRUE@am__objects_6 = drivers/dri2/platform_surfaceless.lo -@HAVE_EGL_PLATFORM_ANDROID_TRUE@am__objects_7 = drivers/dri2/platform_android.lo +@HAVE_PLATFORM_DRM_TRUE@am__objects_5 = drivers/dri2/platform_drm.lo +@HAVE_PLATFORM_SURFACELESS_TRUE@am__objects_6 = drivers/dri2/platform_surfaceless.lo +@HAVE_PLATFORM_ANDROID_TRUE@am__objects_7 = \ +@HAVE_PLATFORM_ANDROID_TRUE@ drivers/dri2/platform_android.lo am__objects_8 = $(am__objects_3) $(am__objects_4) $(am__objects_5) \ $(am__objects_6) $(am__objects_7) @HAVE_DRI3_TRUE@@HAVE_PLATFORM_X11_TRUE@am__objects_9 = drivers/dri2/platform_x11_dri3.lo am__objects_10 = $(am__objects_9) -@HAVE_EGL_DRIVER_DRI2_TRUE@am__objects_11 = $(am__objects_2) \ -@HAVE_EGL_DRIVER_DRI2_TRUE@ $(am__objects_8) $(am__objects_10) -am_libEGL_la_OBJECTS = $(am__objects_1) $(am__objects_11) -libEGL_la_OBJECTS = $(am_libEGL_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -libEGL_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(libEGL_la_LDFLAGS) $(LDFLAGS) -o $@ +am_libEGL_common_la_OBJECTS = $(am__objects_1) $(am__objects_2) \ + $(am__objects_8) $(am__objects_10) +libEGL_common_la_OBJECTS = $(am_libEGL_common_la_OBJECTS) +@USE_LIBGLVND_TRUE@libEGL_mesa_la_DEPENDENCIES = libEGL_common.la +am__libEGL_mesa_la_SOURCES_DIST = main/eglglvnd.c \ + main/egldispatchstubs.h main/egldispatchstubs.c \ + g_egldispatchstubs.c g_egldispatchstubs.h +@USE_LIBGLVND_TRUE@am_libEGL_mesa_la_OBJECTS = main/eglglvnd.lo \ +@USE_LIBGLVND_TRUE@ main/egldispatchstubs.lo \ +@USE_LIBGLVND_TRUE@ g_egldispatchstubs.lo +libEGL_mesa_la_OBJECTS = $(am_libEGL_mesa_la_OBJECTS) +libEGL_mesa_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libEGL_mesa_la_LDFLAGS) $(LDFLAGS) -o \ + $@ +@USE_LIBGLVND_TRUE@am_libEGL_mesa_la_rpath = -rpath $(libdir) AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false @@ -260,15 +258,18 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = -SOURCES = $(libEGL_la_SOURCES) -DIST_SOURCES = $(am__libEGL_la_SOURCES_DIST) +SOURCES = $(libEGL_la_SOURCES) $(libEGL_common_la_SOURCES) \ + $(libEGL_mesa_la_SOURCES) +DIST_SOURCES = $(libEGL_la_SOURCES) \ + $(am__libEGL_common_la_SOURCES_DIST) \ + $(am__libEGL_mesa_la_SOURCES_DIST) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac -DATA = $(pkgconfig_DATA) -HEADERS = $(egl_HEADERS) $(khr_HEADERS) +DATA = $(pkgconfig_DATA) $(vendorjson_DATA) +HEADERS = $(egl_HEADERS) ETAGS = etags CTAGS = ctags am__tty_colors_dummy = \ @@ -281,6 +282,8 @@ AMDGPU_CFLAGS = @AMDGPU_CFLAGS@ AMDGPU_LIBS = @AMDGPU_LIBS@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +ANDROID_CFLAGS = @ANDROID_CFLAGS@ +ANDROID_LIBS = @ANDROID_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -311,8 +314,6 @@ DLLTOOL = @DLLTOOL@ DLOPEN_LIBS = @DLOPEN_LIBS@ DRI2PROTO_CFLAGS = @DRI2PROTO_CFLAGS@ DRI2PROTO_LIBS = @DRI2PROTO_LIBS@ -DRI3PROTO_CFLAGS = @DRI3PROTO_CFLAGS@ -DRI3PROTO_LIBS = @DRI3PROTO_LIBS@ DRIGL_CFLAGS = @DRIGL_CFLAGS@ DRIGL_LIBS = @DRIGL_LIBS@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@ @@ -325,10 +326,11 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGL_CFLAGS = @EGL_CFLAGS@ -EGL_CLIENT_APIS = @EGL_CLIENT_APIS@ EGL_LIB_DEPS = @EGL_LIB_DEPS@ EGL_NATIVE_PLATFORM = @EGL_NATIVE_PLATFORM@ EGREP = @EGREP@ +ETNAVIV_CFLAGS = @ETNAVIV_CFLAGS@ +ETNAVIV_LIBS = @ETNAVIV_LIBS@ EXEEXT = @EXEEXT@ EXPAT_CFLAGS = @EXPAT_CFLAGS@ EXPAT_LIBS = @EXPAT_LIBS@ @@ -376,31 +378,27 @@ LIBDRM_CFLAGS = @LIBDRM_CFLAGS@ LIBDRM_LIBS = @LIBDRM_LIBS@ LIBELF_CFLAGS = @LIBELF_CFLAGS@ LIBELF_LIBS = @LIBELF_LIBS@ +LIBGLVND_DATADIR = @LIBGLVND_DATADIR@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ -LIBSENSORS_LDFLAGS = @LIBSENSORS_LDFLAGS@ -LIBSHA1_CFLAGS = @LIBSHA1_CFLAGS@ -LIBSHA1_LIBS = @LIBSHA1_LIBS@ +LIBSENSORS_LIBS = @LIBSENSORS_LIBS@ LIBTOOL = @LIBTOOL@ +LIBUNWIND_CFLAGS = @LIBUNWIND_CFLAGS@ +LIBUNWIND_LIBS = @LIBUNWIND_LIBS@ LIB_DIR = @LIB_DIR@ LIB_EXT = @LIB_EXT@ LIPO = @LIPO@ -LLVM_BINDIR = @LLVM_BINDIR@ LLVM_CFLAGS = @LLVM_CFLAGS@ LLVM_CONFIG = @LLVM_CONFIG@ -LLVM_CPPFLAGS = @LLVM_CPPFLAGS@ LLVM_CXXFLAGS = @LLVM_CXXFLAGS@ LLVM_INCLUDEDIR = @LLVM_INCLUDEDIR@ LLVM_LDFLAGS = @LLVM_LDFLAGS@ -LLVM_LIBDIR = @LLVM_LIBDIR@ LLVM_LIBS = @LLVM_LIBS@ -LLVM_VERSION = @LLVM_VERSION@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ -MESA_LLVM = @MESA_LLVM@ MKDIR_P = @MKDIR_P@ MSVC2013_COMPAT_CFLAGS = @MSVC2013_COMPAT_CFLAGS@ MSVC2013_COMPAT_CXXFLAGS = @MSVC2013_COMPAT_CXXFLAGS@ @@ -421,8 +419,6 @@ OMX_LIBS = @OMX_LIBS@ OMX_LIB_INSTALL_DIR = @OMX_LIB_INSTALL_DIR@ OPENCL_LIBNAME = @OPENCL_LIBNAME@ OPENCL_VERSION = @OPENCL_VERSION@ -OPENSSL_CFLAGS = @OPENSSL_CFLAGS@ -OPENSSL_LIBS = @OPENSSL_LIBS@ OSMESA_LIB = @OSMESA_LIB@ OSMESA_LIB_DEPS = @OSMESA_LIB_DEPS@ OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@ @@ -442,8 +438,6 @@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSIX_SHELL = @POSIX_SHELL@ -PRESENTPROTO_CFLAGS = @PRESENTPROTO_CFLAGS@ -PRESENTPROTO_LIBS = @PRESENTPROTO_LIBS@ PTHREADSTUBS_CFLAGS = @PTHREADSTUBS_CFLAGS@ PTHREADSTUBS_LIBS = @PTHREADSTUBS_LIBS@ PTHREAD_CC = @PTHREAD_CC@ @@ -459,8 +453,6 @@ SED = @SED@ SELINUX_CFLAGS = @SELINUX_CFLAGS@ SELINUX_LIBS = @SELINUX_LIBS@ SET_MAKE = @SET_MAKE@ -SHA1_CFLAGS = @SHA1_CFLAGS@ -SHA1_LIBS = @SHA1_LIBS@ SHELL = @SHELL@ SIMPENROSE_CFLAGS = @SIMPENROSE_CFLAGS@ SIMPENROSE_LIBS = @SIMPENROSE_LIBS@ @@ -469,7 +461,6 @@ STRIP = @STRIP@ SWR_AVX2_CXXFLAGS = @SWR_AVX2_CXXFLAGS@ SWR_AVX_CXXFLAGS = @SWR_AVX_CXXFLAGS@ SWR_CXX11_CXXFLAGS = @SWR_CXX11_CXXFLAGS@ -TIMESTAMP_CMD = @TIMESTAMP_CMD@ VALGRIND_CFLAGS = @VALGRIND_CFLAGS@ VALGRIND_LIBS = @VALGRIND_LIBS@ VA_CFLAGS = @VA_CFLAGS@ @@ -485,7 +476,6 @@ VDPAU_LIB_INSTALL_DIR = @VDPAU_LIB_INSTALL_DIR@ VDPAU_MAJOR = @VDPAU_MAJOR@ VDPAU_MINOR = @VDPAU_MINOR@ VERSION = @VERSION@ -VG_LIB_DEPS = @VG_LIB_DEPS@ VISIBILITY_CFLAGS = @VISIBILITY_CFLAGS@ VISIBILITY_CXXFLAGS = @VISIBILITY_CXXFLAGS@ VL_CFLAGS = @VL_CFLAGS@ @@ -514,9 +504,10 @@ XVMC_LIBS = @XVMC_LIBS@ XVMC_LIB_INSTALL_DIR = @XVMC_LIB_INSTALL_DIR@ XVMC_MAJOR = @XVMC_MAJOR@ XVMC_MINOR = @XVMC_MINOR@ -XXD = @XXD@ YACC = @YACC@ YFLAGS = @YFLAGS@ +ZLIB_CFLAGS = @ZLIB_CFLAGS@ +ZLIB_LIBS = @ZLIB_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -605,6 +596,7 @@ LIBEGL_C_FILES := \ main/eglsurface.h \ main/eglsync.c \ main/eglsync.h \ + main/eglentrypoint.h \ main/egltypedefs.h dri2_backend_core_FILES := \ @@ -616,26 +608,67 @@ AM_CFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/src/egl/main \ -I$(top_srcdir)/src/gbm/main -I$(top_srcdir)/src $(DEFINES) \ $(VISIBILITY_CFLAGS) $(LIBDRM_CFLAGS) $(EGL_CFLAGS) \ -D_EGL_NATIVE_PLATFORM=$(EGL_NATIVE_PLATFORM) $(am__append_1) \ - $(am__append_6) $(am__append_9) $(am__append_12) \ - $(am__append_14) $(am__append_16) -lib_LTLIBRARIES = libEGL.la -libEGL_la_SOURCES = $(LIBEGL_C_FILES) $(am__append_17) -libEGL_la_LIBADD = $(EGL_LIB_DEPS) $(am__append_2) $(am__append_5) \ - $(am__append_7) $(am__append_10) $(am__append_18) -libEGL_la_LDFLAGS = \ - -no-undefined \ - -version-number 1:0 \ - $(BSYMBOLIC) \ - $(GC_SECTIONS) \ - $(LD_NO_UNDEFINED) - -dri2_backend_FILES = $(am__append_3) $(am__append_8) $(am__append_11) \ - $(am__append_13) $(am__append_15) + $(am__append_6) $(am__append_12) -I$(top_srcdir)/src/loader \ + -I$(top_srcdir)/src/egl/drivers/dri2 \ + -I$(top_srcdir)/src/gbm/backends/dri \ + -I$(top_srcdir)/src/egl/wayland/wayland-egl \ + -I$(top_builddir)/src/egl/wayland/wayland-drm \ + -I$(top_srcdir)/src/egl/wayland/wayland-drm \ + -DDEFAULT_DRIVER_DIR=\"$(DRI_DRIVER_SEARCH_DIR)\" \ + -D_EGL_BUILT_IN_DRIVER_DRI2 $(am__append_15) + +# Depending on whether libglvnd is enabled, we'll build the EGL library as +# either libEGL.so.1 or libEGL_mesa.so.0. Using an automake substitution +# in the variable names breaks "make dist" target, so use a conenience library +# instead. +noinst_LTLIBRARIES = libEGL_common.la +libEGL_common_la_SOURCES = $(LIBEGL_C_FILES) \ + $(dri2_backend_core_FILES) $(dri2_backend_FILES) \ + $(dri3_backend_FILES) +libEGL_common_la_LIBADD = $(EGL_LIB_DEPS) $(am__append_2) \ + $(am__append_5) $(am__append_7) $(am__append_9) \ + $(am__append_13) $(top_builddir)/src/loader/libloader.la \ + $(DLOPEN_LIBS) $(LIBDRM_LIBS) $(CLOCK_LIB) +dri2_backend_FILES = $(am__append_3) $(am__append_8) $(am__append_10) \ + $(am__append_11) $(am__append_14) dri3_backend_FILES = $(am__append_4) +GLVND_GEN_DEPS = generate/gen_egl_dispatch.py \ + generate/egl.xml generate/eglFunctionList.py generate/genCommon.py \ + generate/egl_other.xml + +PYTHON_GEN = $(AM_V_GEN)$(PYTHON2) $(PYTHON_FLAGS) +BUILT_SOURCES = g_egldispatchstubs.c g_egldispatchstubs.h +CLEANFILES = $(BUILT_SOURCES) +@USE_LIBGLVND_TRUE@vendorjsondir = @LIBGLVND_DATADIR@/glvnd/egl_vendor.d +@USE_LIBGLVND_TRUE@vendorjson_DATA = main/50_mesa.json +@USE_LIBGLVND_FALSE@lib_LTLIBRARIES = libEGL.la +@USE_LIBGLVND_TRUE@lib_LTLIBRARIES = libEGL_mesa.la +@USE_LIBGLVND_TRUE@libEGL_mesa_la_SOURCES = \ +@USE_LIBGLVND_TRUE@ main/eglglvnd.c \ +@USE_LIBGLVND_TRUE@ main/egldispatchstubs.h \ +@USE_LIBGLVND_TRUE@ main/egldispatchstubs.c \ +@USE_LIBGLVND_TRUE@ g_egldispatchstubs.c \ +@USE_LIBGLVND_TRUE@ g_egldispatchstubs.h + +@USE_LIBGLVND_TRUE@libEGL_mesa_la_LIBADD = libEGL_common.la +@USE_LIBGLVND_TRUE@libEGL_mesa_la_LDFLAGS = \ +@USE_LIBGLVND_TRUE@ -no-undefined \ +@USE_LIBGLVND_TRUE@ -version-number 0 \ +@USE_LIBGLVND_TRUE@ $(BSYMBOLIC) \ +@USE_LIBGLVND_TRUE@ $(GC_SECTIONS) \ +@USE_LIBGLVND_TRUE@ $(LD_NO_UNDEFINED) + +@USE_LIBGLVND_FALSE@libEGL_la_SOURCES = +@USE_LIBGLVND_FALSE@libEGL_la_LIBADD = libEGL_common.la +@USE_LIBGLVND_FALSE@libEGL_la_LDFLAGS = \ +@USE_LIBGLVND_FALSE@ -no-undefined \ +@USE_LIBGLVND_FALSE@ -version-number 1:0 \ +@USE_LIBGLVND_FALSE@ $(BSYMBOLIC) \ +@USE_LIBGLVND_FALSE@ $(GC_SECTIONS) \ +@USE_LIBGLVND_FALSE@ $(LD_NO_UNDEFINED) + pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = main/egl.pc -khrdir = $(includedir)/KHR -khr_HEADERS = $(top_srcdir)/include/KHR/khrplatform.h egldir = $(includedir)/EGL egl_HEADERS = \ $(top_srcdir)/include/EGL/eglext.h \ @@ -644,15 +677,20 @@ egl_HEADERS = \ $(top_srcdir)/include/EGL/eglmesaext.h \ $(top_srcdir)/include/EGL/eglplatform.h -TESTS = egl-symbols-check +TESTS = egl-symbols-check \ + egl-entrypoint-check + EXTRA_DIST = \ - egl-symbols-check \ + $(TESTS) \ SConscript \ drivers/haiku \ main/egl.def \ - main/README.txt + main/README.txt \ + $(GLVND_GEN_DEPS) \ + main/50_mesa.json -all: all-am +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj @@ -721,6 +759,19 @@ clean-libLTLIBRARIES: echo rm -f $${locs}; \ rm -f $${locs}; \ } + +clean-noinstLTLIBRARIES: + -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + @list='$(noinst_LTLIBRARIES)'; \ + locs=`for p in $$list; do echo $$p; done | \ + sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ + sort -u`; \ + test -z "$$locs" || { \ + echo rm -f $${locs}; \ + rm -f $${locs}; \ + } +libEGL.la: $(libEGL_la_OBJECTS) $(libEGL_la_DEPENDENCIES) $(EXTRA_libEGL_la_DEPENDENCIES) + $(AM_V_CCLD)$(libEGL_la_LINK) $(am_libEGL_la_rpath) $(libEGL_la_OBJECTS) $(libEGL_la_LIBADD) $(LIBS) main/$(am__dirstamp): @$(MKDIR_P) main @: > main/$(am__dirstamp) @@ -766,8 +817,13 @@ drivers/dri2/platform_android.lo: drivers/dri2/$(am__dirstamp) \ drivers/dri2/$(DEPDIR)/$(am__dirstamp) drivers/dri2/platform_x11_dri3.lo: drivers/dri2/$(am__dirstamp) \ drivers/dri2/$(DEPDIR)/$(am__dirstamp) -libEGL.la: $(libEGL_la_OBJECTS) $(libEGL_la_DEPENDENCIES) $(EXTRA_libEGL_la_DEPENDENCIES) - $(AM_V_CCLD)$(libEGL_la_LINK) -rpath $(libdir) $(libEGL_la_OBJECTS) $(libEGL_la_LIBADD) $(LIBS) +libEGL_common.la: $(libEGL_common_la_OBJECTS) $(libEGL_common_la_DEPENDENCIES) $(EXTRA_libEGL_common_la_DEPENDENCIES) + $(AM_V_CCLD)$(LINK) $(libEGL_common_la_OBJECTS) $(libEGL_common_la_LIBADD) $(LIBS) +main/eglglvnd.lo: main/$(am__dirstamp) main/$(DEPDIR)/$(am__dirstamp) +main/egldispatchstubs.lo: main/$(am__dirstamp) \ + main/$(DEPDIR)/$(am__dirstamp) +libEGL_mesa.la: $(libEGL_mesa_la_OBJECTS) $(libEGL_mesa_la_DEPENDENCIES) $(EXTRA_libEGL_mesa_la_DEPENDENCIES) + $(AM_V_CCLD)$(libEGL_mesa_la_LINK) $(am_libEGL_mesa_la_rpath) $(libEGL_mesa_la_OBJECTS) $(libEGL_mesa_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) @@ -779,6 +835,7 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_egldispatchstubs.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@drivers/dri2/$(DEPDIR)/egl_dri2.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@drivers/dri2/$(DEPDIR)/platform_android.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@drivers/dri2/$(DEPDIR)/platform_drm.Plo@am__quote@ @@ -791,10 +848,12 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglconfig.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglcontext.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglcurrent.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/egldispatchstubs.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/egldisplay.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/egldriver.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglfallbacks.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglglobals.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglglvnd.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglimage.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/egllog.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@main/$(DEPDIR)/eglsurface.Plo@am__quote@ @@ -852,48 +911,48 @@ uninstall-pkgconfigDATA: @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) -install-eglHEADERS: $(egl_HEADERS) +install-vendorjsonDATA: $(vendorjson_DATA) @$(NORMAL_INSTALL) - @list='$(egl_HEADERS)'; test -n "$(egldir)" || list=; \ + @list='$(vendorjson_DATA)'; test -n "$(vendorjsondir)" || list=; \ if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(egldir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(egldir)" || exit 1; \ + echo " $(MKDIR_P) '$(DESTDIR)$(vendorjsondir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(vendorjsondir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ - echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(egldir)'"; \ - $(INSTALL_HEADER) $$files "$(DESTDIR)$(egldir)" || exit $$?; \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(vendorjsondir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(vendorjsondir)" || exit $$?; \ done -uninstall-eglHEADERS: +uninstall-vendorjsonDATA: @$(NORMAL_UNINSTALL) - @list='$(egl_HEADERS)'; test -n "$(egldir)" || list=; \ + @list='$(vendorjson_DATA)'; test -n "$(vendorjsondir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ - dir='$(DESTDIR)$(egldir)'; $(am__uninstall_files_from_dir) -install-khrHEADERS: $(khr_HEADERS) + dir='$(DESTDIR)$(vendorjsondir)'; $(am__uninstall_files_from_dir) +install-eglHEADERS: $(egl_HEADERS) @$(NORMAL_INSTALL) - @list='$(khr_HEADERS)'; test -n "$(khrdir)" || list=; \ + @list='$(egl_HEADERS)'; test -n "$(egldir)" || list=; \ if test -n "$$list"; then \ - echo " $(MKDIR_P) '$(DESTDIR)$(khrdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(khrdir)" || exit 1; \ + echo " $(MKDIR_P) '$(DESTDIR)$(egldir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(egldir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ - echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(khrdir)'"; \ - $(INSTALL_HEADER) $$files "$(DESTDIR)$(khrdir)" || exit $$?; \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(egldir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(egldir)" || exit $$?; \ done -uninstall-khrHEADERS: +uninstall-eglHEADERS: @$(NORMAL_UNINSTALL) - @list='$(khr_HEADERS)'; test -n "$(khrdir)" || list=; \ + @list='$(egl_HEADERS)'; test -n "$(egldir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ - dir='$(DESTDIR)$(khrdir)'; $(am__uninstall_files_from_dir) + dir='$(DESTDIR)$(egldir)'; $(am__uninstall_files_from_dir) ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ @@ -1086,15 +1145,17 @@ distdir: $(DISTFILES) done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) check-TESTS -check: check-am +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-am @BUILD_SHARED_FALSE@all-local: @HAVE_COMPAT_SYMLINKS_FALSE@all-local: all-am: Makefile $(LTLIBRARIES) $(DATA) $(HEADERS) all-local installdirs: - for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(egldir)" "$(DESTDIR)$(khrdir)"; do \ + for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(vendorjsondir)" "$(DESTDIR)$(egldir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-am +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am @@ -1116,6 +1177,7 @@ install-strip: mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -1128,15 +1190,16 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) @BUILD_SHARED_FALSE@clean-local: @HAVE_COMPAT_SYMLINKS_FALSE@clean-local: clean: clean-am clean-am: clean-generic clean-libLTLIBRARIES clean-libtool clean-local \ - mostlyclean-am + clean-noinstLTLIBRARIES mostlyclean-am distclean: distclean-am - -rm -rf drivers/dri2/$(DEPDIR) main/$(DEPDIR) + -rm -rf ./$(DEPDIR) drivers/dri2/$(DEPDIR) main/$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags @@ -1153,8 +1216,8 @@ info: info-am info-am: -install-data-am: install-eglHEADERS install-khrHEADERS \ - install-pkgconfigDATA +install-data-am: install-eglHEADERS install-pkgconfigDATA \ + install-vendorjsonDATA install-dvi: install-dvi-am @@ -1183,7 +1246,7 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -rf drivers/dri2/$(DEPDIR) main/$(DEPDIR) + -rm -rf ./$(DEPDIR) drivers/dri2/$(DEPDIR) main/$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic @@ -1200,28 +1263,39 @@ ps: ps-am ps-am: -uninstall-am: uninstall-eglHEADERS uninstall-khrHEADERS \ - uninstall-libLTLIBRARIES uninstall-pkgconfigDATA +uninstall-am: uninstall-eglHEADERS uninstall-libLTLIBRARIES \ + uninstall-pkgconfigDATA uninstall-vendorjsonDATA -.MAKE: check-am install-am install-strip +.MAKE: all check check-am install install-am install-strip .PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \ clean clean-generic clean-libLTLIBRARIES clean-libtool \ - clean-local cscopelist ctags distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-eglHEADERS install-exec install-exec-am install-html \ - install-html-am install-info install-info-am \ - install-khrHEADERS install-libLTLIBRARIES install-man \ - install-pdf install-pdf-am install-pkgconfigDATA install-ps \ - install-ps-am install-strip installcheck installcheck-am \ + clean-local clean-noinstLTLIBRARIES cscopelist ctags distclean \ + distclean-compile distclean-generic distclean-libtool \ + distclean-tags distdir dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-dvi \ + install-dvi-am install-eglHEADERS install-exec install-exec-am \ + install-html install-html-am install-info install-info-am \ + install-libLTLIBRARIES install-man install-pdf install-pdf-am \ + install-pkgconfigDATA install-ps install-ps-am install-strip \ + install-vendorjsonDATA installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-eglHEADERS uninstall-khrHEADERS \ - uninstall-libLTLIBRARIES uninstall-pkgconfigDATA - + uninstall-am uninstall-eglHEADERS uninstall-libLTLIBRARIES \ + uninstall-pkgconfigDATA uninstall-vendorjsonDATA + +g_egldispatchstubs.c: $(GLVND_GEN_DEPS) + $(PYTHON_GEN) $(top_srcdir)/src/egl/generate/gen_egl_dispatch.py source \ + $(top_srcdir)/src/egl/generate/eglFunctionList.py \ + $(top_srcdir)/src/egl/generate/egl.xml \ + $(top_srcdir)/src/egl/generate/egl_other.xml > $@ + +g_egldispatchstubs.h: $(GLVND_GEN_DEPS) + $(PYTHON_GEN) $(top_srcdir)/src/egl/generate/gen_egl_dispatch.py header \ + $(top_srcdir)/src/egl/generate/eglFunctionList.py \ + $(top_srcdir)/src/egl/generate/egl.xml \ + $(top_srcdir)/src/egl/generate/egl_other.xml > $@ @BUILD_SHARED_TRUE@@HAVE_COMPAT_SYMLINKS_TRUE@all-local : .install-mesa-links diff --git a/lib/mesa/src/egl/drivers/dri2/egl_dri2.c b/lib/mesa/src/egl/drivers/dri2/egl_dri2.c index 196d3c776..e3acbe040 100644 --- a/lib/mesa/src/egl/drivers/dri2/egl_dri2.c +++ b/lib/mesa/src/egl/drivers/dri2/egl_dri2.c @@ -56,6 +56,7 @@ #endif #include "egl_dri2.h" +#include "loader/loader.h" #include "util/u_atomic.h" /* The kernel header drm_fourcc.h defines the DRM formats below. We duplicate @@ -74,6 +75,29 @@ #define DRM_FORMAT_GR88 fourcc_code('G', 'R', '8', '8') /* [15:0] G:R 8:8 little endian */ #endif +#ifndef DRM_FORMAT_R16 +#define DRM_FORMAT_R16 fourcc_code('R', '1', '6', ' ') /* [15:0] R 16 little endian */ +#endif + +#ifndef DRM_FORMAT_GR1616 +#define DRM_FORMAT_GR1616 fourcc_code('G', 'R', '3', '2') /* [31:0] R:G 16:16 little endian */ +#endif + +static void +dri_set_background_context(void *loaderPrivate) +{ + _EGLContext *ctx = _eglGetCurrentContext(); + _EGLThreadInfo *t = _eglGetCurrentThread(); + + _eglBindContextToThread(ctx, t); +} + +const __DRIbackgroundCallableExtension background_callable_extension = { + .base = { __DRI_BACKGROUND_CALLABLE, 1 }, + + .setBackgroundContext = dri_set_background_context, +}; + const __DRIuseInvalidateExtension use_invalidate = { .base = { __DRI_USE_INVALIDATE, 1 } }; @@ -514,8 +538,8 @@ dri2_open_driver(_EGLDisplay *disp) _eglLog(_EGL_DEBUG, "DRI2: dlopen(%s)", path); - if (asprintf(&get_extensions_name, "%s_%s", - __DRI_DRIVER_GET_EXTENSIONS, dri2_dpy->driver_name) != -1) { + get_extensions_name = loader_get_extensions_name(dri2_dpy->driver_name); + if (get_extensions_name) { get_extensions = dlsym(dri2_dpy->driver, get_extensions_name); if (get_extensions) { extensions = get_extensions(); @@ -657,6 +681,12 @@ dri2_setup_screen(_EGLDisplay *disp) disp->Extensions.KHR_wait_sync = EGL_TRUE; if (dri2_dpy->fence->get_fence_from_cl_event) disp->Extensions.KHR_cl_event2 = EGL_TRUE; + if (dri2_dpy->fence->base.version >= 2) { + unsigned capabilities = + dri2_dpy->fence->get_capabilities(dri2_dpy->dri_screen); + disp->Extensions.ANDROID_native_fence_sync = + (capabilities & __DRI_FENCE_CAP_NATIVE_FD) != 0; + } } disp->Extensions.KHR_reusable_sync = EGL_TRUE; @@ -907,6 +937,7 @@ dri2_display_release(_EGLDisplay *disp) wl_shm_destroy(dri2_dpy->wl_shm); wl_registry_destroy(dri2_dpy->wl_registry); wl_event_queue_destroy(dri2_dpy->wl_queue); + wl_proxy_wrapper_destroy(dri2_dpy->wl_dpy_wrapper); if (dri2_dpy->own_device) { wl_display_disconnect(dri2_dpy->wl_dpy); } @@ -1555,9 +1586,9 @@ dri2_bind_tex_image(_EGLDriver *drv, assert(!"Unexpected texture target in dri2_bind_tex_image()"); } - (*dri2_dpy->tex_buffer->setTexBuffer2)(dri2_ctx->dri_context, - target, format, - dri_drawable); + dri2_dpy->tex_buffer->setTexBuffer2(dri2_ctx->dri_context, + target, format, + dri_drawable); return EGL_TRUE; } @@ -1588,9 +1619,8 @@ dri2_release_tex_image(_EGLDriver *drv, if (dri2_dpy->tex_buffer->base.version >= 3 && dri2_dpy->tex_buffer->releaseTexBuffer != NULL) { - (*dri2_dpy->tex_buffer->releaseTexBuffer)(dri2_ctx->dri_context, - target, - dri_drawable); + dri2_dpy->tex_buffer->releaseTexBuffer(dri2_ctx->dri_context, + target, dri_drawable); } return EGL_TRUE; @@ -1964,6 +1994,8 @@ dri2_check_dma_buf_format(const _EGLImageAttribs *attrs) case DRM_FORMAT_R8: case DRM_FORMAT_RG88: case DRM_FORMAT_GR88: + case DRM_FORMAT_R16: + case DRM_FORMAT_GR1616: case DRM_FORMAT_RGB332: case DRM_FORMAT_BGR233: case DRM_FORMAT_XRGB4444: @@ -2524,8 +2556,17 @@ dri2_egl_unref_sync(struct dri2_egl_display *dri2_dpy, struct dri2_egl_sync *dri2_sync) { if (p_atomic_dec_zero(&dri2_sync->refcount)) { - if (dri2_sync->base.Type == EGL_SYNC_REUSABLE_KHR) + switch (dri2_sync->base.Type) { + case EGL_SYNC_REUSABLE_KHR: cnd_destroy(&dri2_sync->cond); + break; + case EGL_SYNC_NATIVE_FENCE_ANDROID: + if (dri2_sync->base.SyncFd != EGL_NO_NATIVE_FENCE_FD_ANDROID) + close(dri2_sync->base.SyncFd); + break; + default: + break; + } if (dri2_sync->fence) dri2_dpy->fence->destroy_fence(dri2_dpy->dri_screen, dri2_sync->fence); @@ -2616,6 +2657,19 @@ dri2_create_sync(_EGLDriver *drv, _EGLDisplay *dpy, /* initial status of reusable sync must be "unsignaled" */ dri2_sync->base.SyncStatus = EGL_UNSIGNALED_KHR; break; + + case EGL_SYNC_NATIVE_FENCE_ANDROID: + if (dri2_dpy->fence->create_fence_fd) { + dri2_sync->fence = dri2_dpy->fence->create_fence_fd( + dri2_ctx->dri_context, + dri2_sync->base.SyncFd); + } + if (!dri2_sync->fence) { + _eglError(EGL_BAD_ATTRIBUTE, "eglCreateSyncKHR"); + free(dri2_sync); + return NULL; + } + break; } p_atomic_set(&dri2_sync->refcount, 1); @@ -2645,12 +2699,38 @@ dri2_destroy_sync(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync) ret = EGL_FALSE; } } + dri2_egl_unref_sync(dri2_dpy, dri2_sync); return ret; } static EGLint +dri2_dup_native_fence_fd(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync) +{ + struct dri2_egl_display *dri2_dpy = dri2_egl_display(dpy); + struct dri2_egl_sync *dri2_sync = dri2_egl_sync(sync); + + assert(sync->Type == EGL_SYNC_NATIVE_FENCE_ANDROID); + + if (sync->SyncFd == EGL_NO_NATIVE_FENCE_FD_ANDROID) { + /* try to retrieve the actual native fence fd.. if rendering is + * not flushed this will just return -1, aka NO_NATIVE_FENCE_FD: + */ + sync->SyncFd = dri2_dpy->fence->get_fence_fd(dri2_dpy->dri_screen, + dri2_sync->fence); + } + + if (sync->SyncFd == EGL_NO_NATIVE_FENCE_FD_ANDROID) { + /* if native fence fd still not created, return an error: */ + _eglError(EGL_BAD_PARAMETER, "eglDupNativeFenceFDANDROID"); + return EGL_NO_NATIVE_FENCE_FD_ANDROID; + } + + return dup(sync->SyncFd); +} + +static EGLint dri2_client_wait_sync(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync, EGLint flags, EGLTime timeout) { @@ -2680,6 +2760,7 @@ dri2_client_wait_sync(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync, switch (sync->Type) { case EGL_SYNC_FENCE_KHR: + case EGL_SYNC_NATIVE_FENCE_ANDROID: case EGL_SYNC_CL_EVENT_KHR: if (dri2_dpy->fence->client_wait_sync(dri2_ctx ? dri2_ctx->dri_context : NULL, dri2_sync->fence, wait_flags, @@ -2935,6 +3016,7 @@ _eglBuiltInDriverDRI2(const char *args) dri2_drv->base.API.DestroySyncKHR = dri2_destroy_sync; dri2_drv->base.API.GLInteropQueryDeviceInfo = dri2_interop_query_device_info; dri2_drv->base.API.GLInteropExportObject = dri2_interop_export_object; + dri2_drv->base.API.DupNativeFenceFDANDROID = dri2_dup_native_fence_fd; dri2_drv->base.Name = "DRI2"; dri2_drv->base.Unload = dri2_unload; diff --git a/lib/mesa/src/egl/drivers/dri2/platform_x11.c b/lib/mesa/src/egl/drivers/dri2/platform_x11.c index cf2ce3f89..ea21355a1 100644 --- a/lib/mesa/src/egl/drivers/dri2/platform_x11.c +++ b/lib/mesa/src/egl/drivers/dri2/platform_x11.c @@ -110,7 +110,7 @@ swrastGetDrawableInfo(__DRIdrawable * draw, xcb_get_geometry_reply_t *reply; xcb_generic_error_t *error; - *w = *h = 0; + *x = *y = *w = *h = 0; cookie = xcb_get_geometry (dri2_dpy->conn, dri2_surf->drawable); reply = xcb_get_geometry_reply (dri2_dpy->conn, cookie, &error); if (reply == NULL) @@ -120,6 +120,8 @@ swrastGetDrawableInfo(__DRIdrawable * draw, _eglLog(_EGL_WARNING, "error in xcb_get_geometry"); free(error); } else { + *x = reply->x; + *y = reply->y; *w = reply->width; *h = reply->height; } @@ -206,10 +208,8 @@ dri2_x11_create_surface(_EGLDriver *drv, _EGLDisplay *disp, EGLint type, struct dri2_egl_surface *dri2_surf; xcb_get_geometry_cookie_t cookie; xcb_get_geometry_reply_t *reply; - xcb_screen_iterator_t s; xcb_generic_error_t *error; xcb_drawable_t drawable; - xcb_screen_t *screen; const __DRIconfig *config; STATIC_ASSERT(sizeof(uintptr_t) == sizeof(native_surface)); @@ -228,16 +228,9 @@ dri2_x11_create_surface(_EGLDriver *drv, _EGLDisplay *disp, EGLint type, dri2_surf->region = XCB_NONE; if (type == EGL_PBUFFER_BIT) { - s = xcb_setup_roots_iterator(xcb_get_setup(dri2_dpy->conn)); - screen = get_xcb_screen(s, dri2_dpy->screen); - if (!screen) { - _eglError(EGL_BAD_ALLOC, "failed to get xcb screen"); - goto cleanup_surf; - } - dri2_surf->drawable = xcb_generate_id(dri2_dpy->conn); xcb_create_pixmap(dri2_dpy->conn, conf->BufferSize, - dri2_surf->drawable, screen->root, + dri2_surf->drawable, dri2_dpy->screen->root, dri2_surf->base.Width, dri2_surf->base.Height); } else { if (!drawable) { @@ -255,13 +248,13 @@ dri2_x11_create_surface(_EGLDriver *drv, _EGLDisplay *disp, EGLint type, if (dri2_dpy->dri2) { dri2_surf->dri_drawable = - (*dri2_dpy->dri2->createNewDrawable)(dri2_dpy->dri_screen, config, - dri2_surf); + dri2_dpy->dri2->createNewDrawable(dri2_dpy->dri_screen, config, + dri2_surf); } else { assert(dri2_dpy->swrast); dri2_surf->dri_drawable = - (*dri2_dpy->swrast->createNewDrawable)(dri2_dpy->dri_screen, config, - dri2_surf); + dri2_dpy->swrast->createNewDrawable(dri2_dpy->dri_screen, config, + dri2_surf); } if (dri2_surf->dri_drawable == NULL) { @@ -386,7 +379,7 @@ dri2_x11_destroy_surface(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf) (void) drv; - (*dri2_dpy->core->destroyDrawable)(dri2_surf->dri_drawable); + dri2_dpy->core->destroyDrawable(dri2_surf->dri_drawable); if (dri2_dpy->dri2) { xcb_dri2_destroy_drawable (dri2_dpy->conn, dri2_surf->drawable); @@ -404,6 +397,40 @@ dri2_x11_destroy_surface(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf) } /** + * Function utilizes swrastGetDrawableInfo to get surface + * geometry from x server and calls default query surface + * implementation that returns the updated values. + * + * In case of errors we still return values that we currently + * have. + */ +static EGLBoolean +dri2_query_surface(_EGLDriver *drv, _EGLDisplay *dpy, + _EGLSurface *surf, EGLint attribute, + EGLint *value) +{ + struct dri2_egl_display *dri2_dpy = dri2_egl_display(dpy); + struct dri2_egl_surface *dri2_surf = dri2_egl_surface(surf); + int x, y, w = -1, h = -1; + + __DRIdrawable *drawable = dri2_dpy->vtbl->get_dri_drawable(surf); + + switch (attribute) { + case EGL_WIDTH: + case EGL_HEIGHT: + swrastGetDrawableInfo(drawable, &x, &y, &w, &h, dri2_surf); + if (w != -1 && h != -1) { + surf->Width = w; + surf->Height = h; + } + break; + default: + break; + } + return _eglQuerySurface(drv, dpy, surf, attribute, value); +} + +/** * Process list of buffer received from the server * * Processes the list of buffers received in a reply from the server to either @@ -544,20 +571,10 @@ dri2_x11_do_authenticate(struct dri2_egl_display *dri2_dpy, uint32_t id) { xcb_dri2_authenticate_reply_t *authenticate; xcb_dri2_authenticate_cookie_t authenticate_cookie; - xcb_screen_iterator_t s; - xcb_screen_t *screen; int ret = 0; - s = xcb_setup_roots_iterator(xcb_get_setup(dri2_dpy->conn)); - - screen = get_xcb_screen(s, dri2_dpy->screen); - if (!screen) { - _eglLog(_EGL_WARNING, "DRI2: failed to get xcb screen"); - return -1; - } - authenticate_cookie = - xcb_dri2_authenticate_unchecked(dri2_dpy->conn, screen->root, id); + xcb_dri2_authenticate_unchecked(dri2_dpy->conn, dri2_dpy->screen->root, id); authenticate = xcb_dri2_authenticate_reply(dri2_dpy->conn, authenticate_cookie, NULL); @@ -598,8 +615,6 @@ dri2_x11_connect(struct dri2_egl_display *dri2_dpy) xcb_dri2_connect_reply_t *connect; xcb_dri2_connect_cookie_t connect_cookie; xcb_generic_error_t *error; - xcb_screen_iterator_t s; - xcb_screen_t *screen; char *driver_name, *loader_driver_name, *device_name; const xcb_query_extension_reply_t *extension; @@ -622,13 +637,7 @@ dri2_x11_connect(struct dri2_egl_display *dri2_dpy) XCB_DRI2_MAJOR_VERSION, XCB_DRI2_MINOR_VERSION); - s = xcb_setup_roots_iterator(xcb_get_setup(dri2_dpy->conn)); - screen = get_xcb_screen(s, dri2_dpy->screen); - if (!screen) { - _eglLog(_EGL_WARNING, "DRI2: failed to get xcb screen"); - return EGL_FALSE; - } - connect_cookie = xcb_dri2_connect_unchecked(dri2_dpy->conn, screen->root, + connect_cookie = xcb_dri2_connect_unchecked(dri2_dpy->conn, dri2_dpy->screen->root, XCB_DRI2_DRIVER_TYPE_DRI); xfixes_query = @@ -720,7 +729,6 @@ static EGLBoolean dri2_x11_add_configs_for_visuals(struct dri2_egl_display *dri2_dpy, _EGLDisplay *disp, bool supports_preserved) { - xcb_screen_iterator_t s; xcb_depth_iterator_t d; xcb_visualtype_t *visuals; int i, j, count; @@ -732,8 +740,7 @@ dri2_x11_add_configs_for_visuals(struct dri2_egl_display *dri2_dpy, EGL_NONE }; - s = xcb_setup_roots_iterator(xcb_get_setup(dri2_dpy->conn)); - d = xcb_screen_allowed_depths_iterator(get_xcb_screen(s, dri2_dpy->screen)); + d = xcb_screen_allowed_depths_iterator(dri2_dpy->screen); count = 0; surface_type = @@ -767,7 +774,8 @@ dri2_x11_add_configs_for_visuals(struct dri2_egl_display *dri2_dpy, dri2_conf = dri2_add_config(disp, config, count + 1, surface_type, config_attrs, rgba_masks); if (dri2_conf) - count++; + if (dri2_conf->base.ConfigID == count + 1) + count++; /* Allow a 24-bit RGB visual to match a 32-bit RGBA EGLConfig. * Otherwise it will only match a 32-bit RGBA visual. On a @@ -782,7 +790,8 @@ dri2_x11_add_configs_for_visuals(struct dri2_egl_display *dri2_dpy, dri2_conf = dri2_add_config(disp, config, count + 1, surface_type, config_attrs, rgba_masks); if (dri2_conf) - count++; + if (dri2_conf->base.ConfigID == count + 1) + count++; } } } @@ -812,7 +821,7 @@ dri2_copy_region(_EGLDriver *drv, _EGLDisplay *disp, return EGL_TRUE; if (dri2_dpy->flush) - (*dri2_dpy->flush->flush)(dri2_surf->dri_drawable); + dri2_dpy->flush->flush(dri2_surf->dri_drawable); if (dri2_surf->have_fake_front) render_attachment = XCB_DRI2_ATTACHMENT_BUFFER_FAKE_FRONT_LEFT; @@ -876,7 +885,7 @@ dri2_x11_swap_buffers_msc(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *draw, */ if (dri2_dpy->flush && dri2_dpy->flush->base.version >= 3 && dri2_dpy->flush->invalidate) - (*dri2_dpy->flush->invalidate)(dri2_surf->dri_drawable); + dri2_dpy->flush->invalidate(dri2_surf->dri_drawable); return swap_count; } @@ -892,7 +901,7 @@ dri2_x11_swap_buffers(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *draw) return EGL_TRUE; } /* Swap failed with a window drawable. */ - _eglError(EGL_BAD_NATIVE_WINDOW, __FUNCTION__); + _eglError(EGL_BAD_NATIVE_WINDOW, __func__); return EGL_FALSE; } else { assert(dri2_dpy->swrast); @@ -978,7 +987,7 @@ dri2_x11_copy_buffers(_EGLDriver *drv, _EGLDisplay *disp, _EGLSurface *surf, (void) drv; - (*dri2_dpy->flush->flush)(dri2_surf->dri_drawable); + dri2_dpy->flush->flush(dri2_surf->dri_drawable); gc = xcb_generate_id(dri2_dpy->conn); xcb_create_gc(dri2_dpy->conn, gc, target, 0, NULL); @@ -1142,6 +1151,7 @@ static struct dri2_egl_display_vtbl dri2_x11_swrast_display_vtbl = { .post_sub_buffer = dri2_fallback_post_sub_buffer, .copy_buffers = dri2_x11_copy_buffers, .query_buffer_age = dri2_fallback_query_buffer_age, + .query_surface = dri2_query_surface, .create_wayland_buffer_from_image = dri2_fallback_create_wayland_buffer_from_image, .get_sync_values = dri2_fallback_get_sync_values, .get_dri_drawable = dri2_surface_get_dri_drawable, @@ -1161,6 +1171,7 @@ static struct dri2_egl_display_vtbl dri2_x11_display_vtbl = { .post_sub_buffer = dri2_x11_post_sub_buffer, .copy_buffers = dri2_x11_copy_buffers, .query_buffer_age = dri2_fallback_query_buffer_age, + .query_surface = dri2_query_surface, .create_wayland_buffer_from_image = dri2_fallback_create_wayland_buffer_from_image, .get_sync_values = dri2_x11_get_sync_values, .get_dri_drawable = dri2_surface_get_dri_drawable, @@ -1180,30 +1191,56 @@ static const __DRIextension *swrast_loader_extensions[] = { }; static EGLBoolean -dri2_initialize_x11_swrast(_EGLDriver *drv, _EGLDisplay *disp) +dri2_get_xcb_connection(_EGLDriver *drv, _EGLDisplay *disp, + struct dri2_egl_display *dri2_dpy) { - struct dri2_egl_display *dri2_dpy; - - dri2_dpy = calloc(1, sizeof *dri2_dpy); - if (!dri2_dpy) - return _eglError(EGL_BAD_ALLOC, "eglInitialize"); + xcb_screen_iterator_t s; + int screen = 0; + const char *msg; disp->DriverData = (void *) dri2_dpy; if (disp->PlatformDisplay == NULL) { - dri2_dpy->conn = xcb_connect(0, &dri2_dpy->screen); + dri2_dpy->conn = xcb_connect(NULL, &screen); dri2_dpy->own_device = true; } else { Display *dpy = disp->PlatformDisplay; dri2_dpy->conn = XGetXCBConnection(dpy); - dri2_dpy->screen = DefaultScreen(dpy); + screen = DefaultScreen(dpy); } if (!dri2_dpy->conn || xcb_connection_has_error(dri2_dpy->conn)) { - _eglLog(_EGL_WARNING, "DRI2: xcb_connect failed"); - goto cleanup_dpy; + msg = "xcb_connect failed"; + goto disconnect; } + s = xcb_setup_roots_iterator(xcb_get_setup(dri2_dpy->conn)); + dri2_dpy->screen = get_xcb_screen(s, screen); + if (!dri2_dpy->screen) { + msg = "failed to get xcb screen"; + goto disconnect; + } + + return EGL_TRUE; +disconnect: + if (disp->PlatformDisplay == NULL) + xcb_disconnect(dri2_dpy->conn); + + return _eglError(EGL_BAD_ALLOC, msg); +} + +static EGLBoolean +dri2_initialize_x11_swrast(_EGLDriver *drv, _EGLDisplay *disp) +{ + struct dri2_egl_display *dri2_dpy; + + dri2_dpy = calloc(1, sizeof *dri2_dpy); + if (!dri2_dpy) + return _eglError(EGL_BAD_ALLOC, "eglInitialize"); + + if (!dri2_get_xcb_connection(drv, disp, dri2_dpy)) + goto cleanup_dpy; + /* * Every hardware driver_name is set using strdup. Doing the same in * here will allow is to simply free the memory at dri2_terminate(). @@ -1308,21 +1345,8 @@ dri2_initialize_x11_dri3(_EGLDriver *drv, _EGLDisplay *disp) if (!dri2_dpy) return _eglError(EGL_BAD_ALLOC, "eglInitialize"); - disp->DriverData = (void *) dri2_dpy; - if (disp->PlatformDisplay == NULL) { - dri2_dpy->conn = xcb_connect(0, &dri2_dpy->screen); - dri2_dpy->own_device = true; - } else { - Display *dpy = disp->PlatformDisplay; - - dri2_dpy->conn = XGetXCBConnection(dpy); - dri2_dpy->screen = DefaultScreen(dpy); - } - - if (!dri2_dpy->conn || xcb_connection_has_error(dri2_dpy->conn)) { - _eglLog(_EGL_WARNING, "DRI3: xcb_connect failed"); + if (!dri2_get_xcb_connection(drv, disp, dri2_dpy)) goto cleanup_dpy; - } if (!dri3_x11_connect(dri2_dpy)) goto cleanup_conn; @@ -1403,12 +1427,14 @@ static const __DRIdri2LoaderExtension dri2_loader_extension = { static const __DRIextension *dri2_loader_extensions_old[] = { &dri2_loader_extension_old.base, &image_lookup_extension.base, + &background_callable_extension.base, NULL, }; static const __DRIextension *dri2_loader_extensions[] = { &dri2_loader_extension.base, &image_lookup_extension.base, + &background_callable_extension.base, NULL, }; @@ -1421,21 +1447,8 @@ dri2_initialize_x11_dri2(_EGLDriver *drv, _EGLDisplay *disp) if (!dri2_dpy) return _eglError(EGL_BAD_ALLOC, "eglInitialize"); - disp->DriverData = (void *) dri2_dpy; - if (disp->PlatformDisplay == NULL) { - dri2_dpy->conn = xcb_connect(0, &dri2_dpy->screen); - dri2_dpy->own_device = true; - } else { - Display *dpy = disp->PlatformDisplay; - - dri2_dpy->conn = XGetXCBConnection(dpy); - dri2_dpy->screen = DefaultScreen(dpy); - } - - if (!dri2_dpy->conn || xcb_connection_has_error(dri2_dpy->conn)) { - _eglLog(_EGL_WARNING, "DRI2: xcb_connect failed"); + if (!dri2_get_xcb_connection(drv, disp, dri2_dpy)) goto cleanup_dpy; - } if (!dri2_x11_connect(dri2_dpy)) goto cleanup_conn; @@ -1496,25 +1509,21 @@ dri2_initialize_x11_dri2(_EGLDriver *drv, _EGLDisplay *disp) EGLBoolean dri2_initialize_x11(_EGLDriver *drv, _EGLDisplay *disp) { - EGLBoolean initialized = EGL_TRUE; - - int x11_dri2_accel = (getenv("LIBGL_ALWAYS_SOFTWARE") == NULL); + EGLBoolean initialized = EGL_FALSE; - if (x11_dri2_accel) { + if (!getenv("LIBGL_ALWAYS_SOFTWARE")) { #ifdef HAVE_DRI3 - if (getenv("LIBGL_DRI3_DISABLE") != NULL || - !dri2_initialize_x11_dri3(drv, disp)) { -#endif - if (!dri2_initialize_x11_dri2(drv, disp)) { - initialized = dri2_initialize_x11_swrast(drv, disp); - } -#ifdef HAVE_DRI3 - } + if (!getenv("LIBGL_DRI3_DISABLE")) + initialized = dri2_initialize_x11_dri3(drv, disp); #endif - } else { - initialized = dri2_initialize_x11_swrast(drv, disp); + + if (!initialized) + initialized = dri2_initialize_x11_dri2(drv, disp); } + if (!initialized) + initialized = dri2_initialize_x11_swrast(drv, disp); + return initialized; } diff --git a/lib/mesa/src/egl/wayland/wayland-drm/Makefile.in b/lib/mesa/src/egl/wayland/wayland-drm/Makefile.in index 8a28a8d77..b365a1471 100644 --- a/lib/mesa/src/egl/wayland/wayland-drm/Makefile.in +++ b/lib/mesa/src/egl/wayland/wayland-drm/Makefile.in @@ -129,6 +129,8 @@ AMDGPU_CFLAGS = @AMDGPU_CFLAGS@ AMDGPU_LIBS = @AMDGPU_LIBS@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +ANDROID_CFLAGS = @ANDROID_CFLAGS@ +ANDROID_LIBS = @ANDROID_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -159,8 +161,6 @@ DLLTOOL = @DLLTOOL@ DLOPEN_LIBS = @DLOPEN_LIBS@ DRI2PROTO_CFLAGS = @DRI2PROTO_CFLAGS@ DRI2PROTO_LIBS = @DRI2PROTO_LIBS@ -DRI3PROTO_CFLAGS = @DRI3PROTO_CFLAGS@ -DRI3PROTO_LIBS = @DRI3PROTO_LIBS@ DRIGL_CFLAGS = @DRIGL_CFLAGS@ DRIGL_LIBS = @DRIGL_LIBS@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@ @@ -173,10 +173,11 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGL_CFLAGS = @EGL_CFLAGS@ -EGL_CLIENT_APIS = @EGL_CLIENT_APIS@ EGL_LIB_DEPS = @EGL_LIB_DEPS@ EGL_NATIVE_PLATFORM = @EGL_NATIVE_PLATFORM@ EGREP = @EGREP@ +ETNAVIV_CFLAGS = @ETNAVIV_CFLAGS@ +ETNAVIV_LIBS = @ETNAVIV_LIBS@ EXEEXT = @EXEEXT@ EXPAT_CFLAGS = @EXPAT_CFLAGS@ EXPAT_LIBS = @EXPAT_LIBS@ @@ -224,31 +225,27 @@ LIBDRM_CFLAGS = @LIBDRM_CFLAGS@ LIBDRM_LIBS = @LIBDRM_LIBS@ LIBELF_CFLAGS = @LIBELF_CFLAGS@ LIBELF_LIBS = @LIBELF_LIBS@ +LIBGLVND_DATADIR = @LIBGLVND_DATADIR@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ -LIBSENSORS_LDFLAGS = @LIBSENSORS_LDFLAGS@ -LIBSHA1_CFLAGS = @LIBSHA1_CFLAGS@ -LIBSHA1_LIBS = @LIBSHA1_LIBS@ +LIBSENSORS_LIBS = @LIBSENSORS_LIBS@ LIBTOOL = @LIBTOOL@ +LIBUNWIND_CFLAGS = @LIBUNWIND_CFLAGS@ +LIBUNWIND_LIBS = @LIBUNWIND_LIBS@ LIB_DIR = @LIB_DIR@ LIB_EXT = @LIB_EXT@ LIPO = @LIPO@ -LLVM_BINDIR = @LLVM_BINDIR@ LLVM_CFLAGS = @LLVM_CFLAGS@ LLVM_CONFIG = @LLVM_CONFIG@ -LLVM_CPPFLAGS = @LLVM_CPPFLAGS@ LLVM_CXXFLAGS = @LLVM_CXXFLAGS@ LLVM_INCLUDEDIR = @LLVM_INCLUDEDIR@ LLVM_LDFLAGS = @LLVM_LDFLAGS@ -LLVM_LIBDIR = @LLVM_LIBDIR@ LLVM_LIBS = @LLVM_LIBS@ -LLVM_VERSION = @LLVM_VERSION@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ -MESA_LLVM = @MESA_LLVM@ MKDIR_P = @MKDIR_P@ MSVC2013_COMPAT_CFLAGS = @MSVC2013_COMPAT_CFLAGS@ MSVC2013_COMPAT_CXXFLAGS = @MSVC2013_COMPAT_CXXFLAGS@ @@ -269,8 +266,6 @@ OMX_LIBS = @OMX_LIBS@ OMX_LIB_INSTALL_DIR = @OMX_LIB_INSTALL_DIR@ OPENCL_LIBNAME = @OPENCL_LIBNAME@ OPENCL_VERSION = @OPENCL_VERSION@ -OPENSSL_CFLAGS = @OPENSSL_CFLAGS@ -OPENSSL_LIBS = @OPENSSL_LIBS@ OSMESA_LIB = @OSMESA_LIB@ OSMESA_LIB_DEPS = @OSMESA_LIB_DEPS@ OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@ @@ -290,8 +285,6 @@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSIX_SHELL = @POSIX_SHELL@ -PRESENTPROTO_CFLAGS = @PRESENTPROTO_CFLAGS@ -PRESENTPROTO_LIBS = @PRESENTPROTO_LIBS@ PTHREADSTUBS_CFLAGS = @PTHREADSTUBS_CFLAGS@ PTHREADSTUBS_LIBS = @PTHREADSTUBS_LIBS@ PTHREAD_CC = @PTHREAD_CC@ @@ -307,8 +300,6 @@ SED = @SED@ SELINUX_CFLAGS = @SELINUX_CFLAGS@ SELINUX_LIBS = @SELINUX_LIBS@ SET_MAKE = @SET_MAKE@ -SHA1_CFLAGS = @SHA1_CFLAGS@ -SHA1_LIBS = @SHA1_LIBS@ SHELL = @SHELL@ SIMPENROSE_CFLAGS = @SIMPENROSE_CFLAGS@ SIMPENROSE_LIBS = @SIMPENROSE_LIBS@ @@ -317,7 +308,6 @@ STRIP = @STRIP@ SWR_AVX2_CXXFLAGS = @SWR_AVX2_CXXFLAGS@ SWR_AVX_CXXFLAGS = @SWR_AVX_CXXFLAGS@ SWR_CXX11_CXXFLAGS = @SWR_CXX11_CXXFLAGS@ -TIMESTAMP_CMD = @TIMESTAMP_CMD@ VALGRIND_CFLAGS = @VALGRIND_CFLAGS@ VALGRIND_LIBS = @VALGRIND_LIBS@ VA_CFLAGS = @VA_CFLAGS@ @@ -333,7 +323,6 @@ VDPAU_LIB_INSTALL_DIR = @VDPAU_LIB_INSTALL_DIR@ VDPAU_MAJOR = @VDPAU_MAJOR@ VDPAU_MINOR = @VDPAU_MINOR@ VERSION = @VERSION@ -VG_LIB_DEPS = @VG_LIB_DEPS@ VISIBILITY_CFLAGS = @VISIBILITY_CFLAGS@ VISIBILITY_CXXFLAGS = @VISIBILITY_CXXFLAGS@ VL_CFLAGS = @VL_CFLAGS@ @@ -362,9 +351,10 @@ XVMC_LIBS = @XVMC_LIBS@ XVMC_LIB_INSTALL_DIR = @XVMC_LIB_INSTALL_DIR@ XVMC_MAJOR = @XVMC_MAJOR@ XVMC_MINOR = @XVMC_MINOR@ -XXD = @XXD@ YACC = @YACC@ YFLAGS = @YFLAGS@ +ZLIB_CFLAGS = @ZLIB_CFLAGS@ +ZLIB_LIBS = @ZLIB_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ diff --git a/lib/mesa/src/egl/wayland/wayland-egl/Makefile.in b/lib/mesa/src/egl/wayland/wayland-egl/Makefile.in index 1ba116e35..82994039e 100644 --- a/lib/mesa/src/egl/wayland/wayland-egl/Makefile.in +++ b/lib/mesa/src/egl/wayland/wayland-egl/Makefile.in @@ -171,6 +171,8 @@ AMDGPU_CFLAGS = @AMDGPU_CFLAGS@ AMDGPU_LIBS = @AMDGPU_LIBS@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +ANDROID_CFLAGS = @ANDROID_CFLAGS@ +ANDROID_LIBS = @ANDROID_LIBS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ @@ -201,8 +203,6 @@ DLLTOOL = @DLLTOOL@ DLOPEN_LIBS = @DLOPEN_LIBS@ DRI2PROTO_CFLAGS = @DRI2PROTO_CFLAGS@ DRI2PROTO_LIBS = @DRI2PROTO_LIBS@ -DRI3PROTO_CFLAGS = @DRI3PROTO_CFLAGS@ -DRI3PROTO_LIBS = @DRI3PROTO_LIBS@ DRIGL_CFLAGS = @DRIGL_CFLAGS@ DRIGL_LIBS = @DRIGL_LIBS@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@ @@ -215,10 +215,11 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGL_CFLAGS = @EGL_CFLAGS@ -EGL_CLIENT_APIS = @EGL_CLIENT_APIS@ EGL_LIB_DEPS = @EGL_LIB_DEPS@ EGL_NATIVE_PLATFORM = @EGL_NATIVE_PLATFORM@ EGREP = @EGREP@ +ETNAVIV_CFLAGS = @ETNAVIV_CFLAGS@ +ETNAVIV_LIBS = @ETNAVIV_LIBS@ EXEEXT = @EXEEXT@ EXPAT_CFLAGS = @EXPAT_CFLAGS@ EXPAT_LIBS = @EXPAT_LIBS@ @@ -266,31 +267,27 @@ LIBDRM_CFLAGS = @LIBDRM_CFLAGS@ LIBDRM_LIBS = @LIBDRM_LIBS@ LIBELF_CFLAGS = @LIBELF_CFLAGS@ LIBELF_LIBS = @LIBELF_LIBS@ +LIBGLVND_DATADIR = @LIBGLVND_DATADIR@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ -LIBSENSORS_LDFLAGS = @LIBSENSORS_LDFLAGS@ -LIBSHA1_CFLAGS = @LIBSHA1_CFLAGS@ -LIBSHA1_LIBS = @LIBSHA1_LIBS@ +LIBSENSORS_LIBS = @LIBSENSORS_LIBS@ LIBTOOL = @LIBTOOL@ +LIBUNWIND_CFLAGS = @LIBUNWIND_CFLAGS@ +LIBUNWIND_LIBS = @LIBUNWIND_LIBS@ LIB_DIR = @LIB_DIR@ LIB_EXT = @LIB_EXT@ LIPO = @LIPO@ -LLVM_BINDIR = @LLVM_BINDIR@ LLVM_CFLAGS = @LLVM_CFLAGS@ LLVM_CONFIG = @LLVM_CONFIG@ -LLVM_CPPFLAGS = @LLVM_CPPFLAGS@ LLVM_CXXFLAGS = @LLVM_CXXFLAGS@ LLVM_INCLUDEDIR = @LLVM_INCLUDEDIR@ LLVM_LDFLAGS = @LLVM_LDFLAGS@ -LLVM_LIBDIR = @LLVM_LIBDIR@ LLVM_LIBS = @LLVM_LIBS@ -LLVM_VERSION = @LLVM_VERSION@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ -MESA_LLVM = @MESA_LLVM@ MKDIR_P = @MKDIR_P@ MSVC2013_COMPAT_CFLAGS = @MSVC2013_COMPAT_CFLAGS@ MSVC2013_COMPAT_CXXFLAGS = @MSVC2013_COMPAT_CXXFLAGS@ @@ -311,8 +308,6 @@ OMX_LIBS = @OMX_LIBS@ OMX_LIB_INSTALL_DIR = @OMX_LIB_INSTALL_DIR@ OPENCL_LIBNAME = @OPENCL_LIBNAME@ OPENCL_VERSION = @OPENCL_VERSION@ -OPENSSL_CFLAGS = @OPENSSL_CFLAGS@ -OPENSSL_LIBS = @OPENSSL_LIBS@ OSMESA_LIB = @OSMESA_LIB@ OSMESA_LIB_DEPS = @OSMESA_LIB_DEPS@ OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@ @@ -332,8 +327,6 @@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSIX_SHELL = @POSIX_SHELL@ -PRESENTPROTO_CFLAGS = @PRESENTPROTO_CFLAGS@ -PRESENTPROTO_LIBS = @PRESENTPROTO_LIBS@ PTHREADSTUBS_CFLAGS = @PTHREADSTUBS_CFLAGS@ PTHREADSTUBS_LIBS = @PTHREADSTUBS_LIBS@ PTHREAD_CC = @PTHREAD_CC@ @@ -349,8 +342,6 @@ SED = @SED@ SELINUX_CFLAGS = @SELINUX_CFLAGS@ SELINUX_LIBS = @SELINUX_LIBS@ SET_MAKE = @SET_MAKE@ -SHA1_CFLAGS = @SHA1_CFLAGS@ -SHA1_LIBS = @SHA1_LIBS@ SHELL = @SHELL@ SIMPENROSE_CFLAGS = @SIMPENROSE_CFLAGS@ SIMPENROSE_LIBS = @SIMPENROSE_LIBS@ @@ -359,7 +350,6 @@ STRIP = @STRIP@ SWR_AVX2_CXXFLAGS = @SWR_AVX2_CXXFLAGS@ SWR_AVX_CXXFLAGS = @SWR_AVX_CXXFLAGS@ SWR_CXX11_CXXFLAGS = @SWR_CXX11_CXXFLAGS@ -TIMESTAMP_CMD = @TIMESTAMP_CMD@ VALGRIND_CFLAGS = @VALGRIND_CFLAGS@ VALGRIND_LIBS = @VALGRIND_LIBS@ VA_CFLAGS = @VA_CFLAGS@ @@ -375,7 +365,6 @@ VDPAU_LIB_INSTALL_DIR = @VDPAU_LIB_INSTALL_DIR@ VDPAU_MAJOR = @VDPAU_MAJOR@ VDPAU_MINOR = @VDPAU_MINOR@ VERSION = @VERSION@ -VG_LIB_DEPS = @VG_LIB_DEPS@ VISIBILITY_CFLAGS = @VISIBILITY_CFLAGS@ VISIBILITY_CXXFLAGS = @VISIBILITY_CXXFLAGS@ VL_CFLAGS = @VL_CFLAGS@ @@ -404,9 +393,10 @@ XVMC_LIBS = @XVMC_LIBS@ XVMC_LIB_INSTALL_DIR = @XVMC_LIB_INSTALL_DIR@ XVMC_MAJOR = @XVMC_MAJOR@ XVMC_MINOR = @XVMC_MINOR@ -XXD = @XXD@ YACC = @YACC@ YFLAGS = @YFLAGS@ +ZLIB_CFLAGS = @ZLIB_CFLAGS@ +ZLIB_LIBS = @ZLIB_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ |