Nothing in wayand-drm is EGL specific, parts of the directory are used by EGL, parts by GBM, and parts by vulkan wsi, so it makes sense to move that into it's own directory. src/wsi was chosen because there's a lot of wsi code in mesa that could be moved here, vulkan/wsi, EGL, GBM, and GLX could all get moved here, as could some wsi bits in loader.
Signed-off-by: Dylan Baker <[email protected]> --- configure.ac | 4 ++-- src/Makefile.am | 3 +-- src/egl/Makefile.am | 6 +++--- src/egl/meson.build | 4 +--- src/gbm/Makefile.am | 2 +- src/gbm/meson.build | 2 +- src/meson.build | 2 +- src/vulkan/Makefile.am | 13 +++---------- src/vulkan/Makefile.sources | 4 ---- src/{egl/wayland => wsi}/wayland-drm/.gitignore | 0 src/{egl/wayland => wsi}/wayland-drm/Makefile.am | 0 src/{egl/wayland => wsi}/wayland-drm/meson.build | 2 ++ src/{egl/wayland => wsi}/wayland-drm/wayland-drm.c | 0 src/{egl/wayland => wsi}/wayland-drm/wayland-drm.h | 0 src/{egl/wayland => wsi}/wayland-drm/wayland-drm.xml | 0 15 files changed, 15 insertions(+), 27 deletions(-) rename src/{egl/wayland => wsi}/wayland-drm/.gitignore (100%) rename src/{egl/wayland => wsi}/wayland-drm/Makefile.am (100%) rename src/{egl/wayland => wsi}/wayland-drm/meson.build (97%) rename src/{egl/wayland => wsi}/wayland-drm/wayland-drm.c (100%) rename src/{egl/wayland => wsi}/wayland-drm/wayland-drm.h (100%) rename src/{egl/wayland => wsi}/wayland-drm/wayland-drm.xml (100%) diff --git a/configure.ac b/configure.ac index add3830f233..42f1d50da85 100644 --- a/configure.ac +++ b/configure.ac @@ -2861,7 +2861,6 @@ AC_CONFIG_FILES([Makefile src/compiler/Makefile src/egl/Makefile src/egl/main/egl.pc - src/egl/wayland/wayland-drm/Makefile src/egl/wayland/wayland-egl/Makefile src/egl/wayland/wayland-egl/wayland-egl.pc src/gallium/Makefile @@ -2967,7 +2966,8 @@ AC_CONFIG_FILES([Makefile src/util/tests/hash_table/Makefile src/util/tests/string_buffer/Makefile src/util/xmlpool/Makefile - src/vulkan/Makefile]) + src/vulkan/Makefile + src/wsi/wayland-drm/Makefile]) AC_OUTPUT diff --git a/src/Makefile.am b/src/Makefile.am index 5ef2d4f55ea..b3129b40163 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -66,7 +66,7 @@ SUBDIRS += compiler ## Optionally required by GBM, EGL if HAVE_PLATFORM_WAYLAND -SUBDIRS += egl/wayland/wayland-drm +SUBDIRS += wsi/wayland-drm endif if HAVE_VULKAN_COMMON @@ -112,7 +112,6 @@ if HAVE_EGL SUBDIRS += egl endif -# Requires wayland-drm if HAVE_RADEON_VULKAN SUBDIRS += amd/vulkan endif diff --git a/src/egl/Makefile.am b/src/egl/Makefile.am index eeb745f973a..4c196fdb659 100644 --- a/src/egl/Makefile.am +++ b/src/egl/Makefile.am @@ -85,7 +85,7 @@ AM_CFLAGS += $(WAYLAND_CLIENT_CFLAGS) libEGL_common_la_LIBADD += $(WAYLAND_CLIENT_LIBS) libEGL_common_la_LIBADD += $(LIBDRM_LIBS) AM_CFLAGS += $(WAYLAND_SERVER_CFLAGS) -libEGL_common_la_LIBADD += $(top_builddir)/src/egl/wayland/wayland-drm/libwayland-drm.la +libEGL_common_la_LIBADD += $(top_builddir)/src/wsi/wayland-drm/libwayland-drm.la libEGL_common_la_LIBADD += $(WAYLAND_SERVER_LIBS) dri2_backend_FILES += \ drivers/dri2/platform_wayland.c \ @@ -114,8 +114,8 @@ AM_CFLAGS += \ -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 \ + -I$(top_builddir)/src/wsi/wayland-drm \ + -I$(top_srcdir)/src/wsi/wayland-drm \ -DDEFAULT_DRIVER_DIR=\"$(DRI_DRIVER_SEARCH_DIR)\" \ -D_EGL_BUILT_IN_DRIVER_DRI2 diff --git a/src/egl/meson.build b/src/egl/meson.build index 8ea8a5bbb69..7449b521fc1 100644 --- a/src/egl/meson.build +++ b/src/egl/meson.build @@ -123,9 +123,7 @@ if with_platform_wayland linux_dmabuf_unstable_v1_client_protocol_h, wayland_drm_client_protocol_h, ] - incs_for_egl += include_directories( - 'wayland/wayland-egl', 'wayland/wayland-drm', - ) + incs_for_egl += [include_directories('wayland/wayland-egl'), inc_wayland_drm] endif # TODO: android diff --git a/src/gbm/Makefile.am b/src/gbm/Makefile.am index 05d861ff999..897be431c56 100644 --- a/src/gbm/Makefile.am +++ b/src/gbm/Makefile.am @@ -34,7 +34,7 @@ if HAVE_PLATFORM_WAYLAND AM_CFLAGS += \ $(WAYLAND_SERVER_CFLAGS) \ -I$(top_srcdir)/src/egl/wayland/wayland-drm/ -libgbm_la_LIBADD += $(top_builddir)/src/egl/wayland/wayland-drm/libwayland-drm.la $(WAYLAND_SERVER_LIBS) +libgbm_la_LIBADD += $(top_builddir)/src/wsi/wayland-drm/libwayland-drm.la $(WAYLAND_SERVER_LIBS) endif if HAVE_DRI2 diff --git a/src/gbm/meson.build b/src/gbm/meson.build index 2910fa2390c..aff252d36ca 100644 --- a/src/gbm/meson.build +++ b/src/gbm/meson.build @@ -41,7 +41,7 @@ endif if with_platform_wayland deps_gbm += dep_wayland_server links_gbm += libwayland_drm - incs_gbm += include_directories('../egl/wayland/wayland-drm') + incs_gbm += inc_wayland_drm endif # TODO: wayland support (requires egl) diff --git a/src/meson.build b/src/meson.build index 9b1b0ae594d..868e35daa03 100644 --- a/src/meson.build +++ b/src/meson.build @@ -46,7 +46,7 @@ subdir('mapi') # TODO: opengl # TODO: osmesa subdir('compiler') -subdir('egl/wayland/wayland-drm') +subdir('wsi/wayland-drm') subdir('vulkan') subdir('amd') if with_gallium_vc4 diff --git a/src/vulkan/Makefile.am b/src/vulkan/Makefile.am index 8766952eafb..0853f83d324 100644 --- a/src/vulkan/Makefile.am +++ b/src/vulkan/Makefile.am @@ -57,15 +57,7 @@ endif BUILT_SOURCES += $(VULKAN_WSI_WAYLAND_GENERATED_FILES) CLEANFILES = $(BUILT_SOURCES) -WL_DRM_XML = $(top_srcdir)/src/egl/wayland/wayland-drm/wayland-drm.xml - -wsi/wayland-drm-protocol.c : $(WL_DRM_XML) - $(MKDIR_GEN) - $(AM_V_GEN)$(WAYLAND_SCANNER) code < $< > $@ - -wsi/wayland-drm-client-protocol.h : $(WL_DRM_XML) - $(MKDIR_GEN) - $(AM_V_GEN)$(WAYLAND_SCANNER) client-header < $< > $@ +WL_DRM_XML = $(top_srcdir)/src/wsi/wayland-drm/wayland-drm.xml if HAVE_PLATFORM_WAYLAND AM_CPPFLAGS += \ @@ -75,7 +67,8 @@ AM_CPPFLAGS += \ VULKAN_WSI_SOURCES += \ $(VULKAN_WSI_WAYLAND_FILES) \ - $(VULKAN_WSI_WAYLAND_GENERATED_FILES) + $(top_builddir)/src/wsi/wayland-drm/wayland-drm-protocol.c \ + $(top_builddir)/src/wsi/wayland-drm/wayland-drm-client-protocol.h endif diff --git a/src/vulkan/Makefile.sources b/src/vulkan/Makefile.sources index 2cf7218e926..a7cfa49fa9d 100644 --- a/src/vulkan/Makefile.sources +++ b/src/vulkan/Makefile.sources @@ -7,10 +7,6 @@ VULKAN_WSI_WAYLAND_FILES := \ wsi/wsi_common_wayland.c \ wsi/wsi_common_wayland.h -VULKAN_WSI_WAYLAND_GENERATED_FILES := \ - wsi/wayland-drm-protocol.c \ - wsi/wayland-drm-client-protocol.h - VULKAN_WSI_X11_FILES := \ wsi/wsi_common_x11.c \ wsi/wsi_common_x11.h diff --git a/src/egl/wayland/wayland-drm/.gitignore b/src/wsi/wayland-drm/.gitignore similarity index 100% rename from src/egl/wayland/wayland-drm/.gitignore rename to src/wsi/wayland-drm/.gitignore diff --git a/src/egl/wayland/wayland-drm/Makefile.am b/src/wsi/wayland-drm/Makefile.am similarity index 100% rename from src/egl/wayland/wayland-drm/Makefile.am rename to src/wsi/wayland-drm/Makefile.am diff --git a/src/egl/wayland/wayland-drm/meson.build b/src/wsi/wayland-drm/meson.build similarity index 97% rename from src/egl/wayland/wayland-drm/meson.build rename to src/wsi/wayland-drm/meson.build index 12b49ca4f06..17ac2ddf74e 100644 --- a/src/egl/wayland/wayland-drm/meson.build +++ b/src/wsi/wayland-drm/meson.build @@ -18,6 +18,8 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. +inc_wayland_drm = include_directories('.') + wayland_drm_protocol_c = custom_target( 'wayland-drm-protocol.c', input : 'wayland-drm.xml', diff --git a/src/egl/wayland/wayland-drm/wayland-drm.c b/src/wsi/wayland-drm/wayland-drm.c similarity index 100% rename from src/egl/wayland/wayland-drm/wayland-drm.c rename to src/wsi/wayland-drm/wayland-drm.c diff --git a/src/egl/wayland/wayland-drm/wayland-drm.h b/src/wsi/wayland-drm/wayland-drm.h similarity index 100% rename from src/egl/wayland/wayland-drm/wayland-drm.h rename to src/wsi/wayland-drm/wayland-drm.h diff --git a/src/egl/wayland/wayland-drm/wayland-drm.xml b/src/wsi/wayland-drm/wayland-drm.xml similarity index 100% rename from src/egl/wayland/wayland-drm/wayland-drm.xml rename to src/wsi/wayland-drm/wayland-drm.xml -- 2.14.2 _______________________________________________ mesa-dev mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-dev
