diff --git a/toolkit/moz.configure b/toolkit/moz.configure index 82b5a59acf42..82203d26a873 100644 --- a/toolkit/moz.configure +++ b/toolkit/moz.configure @@ -250,7 +250,7 @@ add_old_configure_assignment('MOZ_X11', True, when=toolkit_gtk) # Wayland support # ============================================================== wayland_headers = pkg_check_modules( - 'MOZ_WAYLAND', 'gtk+-wayland-3.0 >= 3.10 xkbcommon >= 0.4.1', + 'MOZ_WAYLAND', 'gtk+-wayland-3.0 >= 3.10 xkbcommon >= 0.4.1 libdrm > 2.4', allow_missing=depends(full_toolkit)(lambda t: t == 'cairo-gtk3'), when=depends(full_toolkit)(lambda t: t in ('cairo-gtk3', 'cairo-gtk3-wayland'))) diff --git a/widget/gtk/WaylandDMABufSurface.cpp b/widget/gtk/WaylandDMABufSurface.cpp index 7345e0cfce55..020ea473d009 100644 --- a/widget/gtk/WaylandDMABufSurface.cpp +++ b/widget/gtk/WaylandDMABufSurface.cpp @@ -122,7 +122,6 @@ bool WaylandDMABufSurface::Create(int aWidth, int aHeight, bool aHasAlpha) { return false; } -#ifdef HAVE_GBM_MODIFIERS if (nsGbmLib::IsModifierAvailable() && mGmbFormat->mModifiersCount > 0) { mGbmBufferObject = nsGbmLib::CreateWithModifiers( display->GetGbmDevice(), mWidth, mHeight, mGmbFormat->mFormat, @@ -131,7 +130,6 @@ bool WaylandDMABufSurface::Create(int aWidth, int aHeight, bool aHasAlpha) { mBufferModifier = nsGbmLib::GetModifier(mGbmBufferObject); } } -#endif if (!mGbmBufferObject) { mGbmBufferObject = @@ -143,7 +141,6 @@ bool WaylandDMABufSurface::Create(int aWidth, int aHeight, bool aHasAlpha) { return false; } -#ifdef HAVE_GBM_MODIFIERS if (nsGbmLib::IsModifierAvailable() && display->GetGbmDeviceFd() != -1) { mBufferPlaneCount = nsGbmLib::GetPlaneCount(mGbmBufferObject); for (int i = 0; i < mBufferPlaneCount; i++) { @@ -157,9 +154,7 @@ bool WaylandDMABufSurface::Create(int aWidth, int aHeight, bool aHasAlpha) { mStrides[i] = nsGbmLib::GetStrideForPlane(mGbmBufferObject, i); mOffsets[i] = nsGbmLib::GetOffset(mGbmBufferObject, i); } - } else -#endif - { + } else { mBufferPlaneCount = 1; mStrides[0] = nsGbmLib::GetStride(mGbmBufferObject); mDmabufFds[0] = nsGbmLib::GetFd(mGbmBufferObject); diff --git a/widget/gtk/nsGtkKeyUtils.cpp b/widget/gtk/nsGtkKeyUtils.cpp index 8b448692de0c..9e5ad11181f5 100644 --- a/widget/gtk/nsGtkKeyUtils.cpp +++ b/widget/gtk/nsGtkKeyUtils.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #ifdef MOZ_WIDGET_GTK # include #endif