diff options
author | Max Krummenacher <max.krummenacher@toradex.com> | 2023-10-31 11:10:56 -0300 |
---|---|---|
committer | Max Krummenacher <max.krummenacher@toradex.com> | 2023-11-29 17:09:09 +0100 |
commit | 9dc0951458a115a268f57a3bfd85b71256c12d4d (patch) | |
tree | 6e40acaf22a37c57fb101853404fb0c982947f90 /recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch | |
parent | 5d57838ef15bcd0b9497c57eeda7f40ca7bfaf59 (diff) |
gpicview: allow building without xwayland
The recipe already patches the code tree to no longer call into gdk
(remove-gdk-x11.patch) which does not work in wayland/xwayland.
Thus the dependency on X11 headers is gone.
Remove additionally checking for them in the configure script.
This allows to build gpicview for weston without having xwayland
enabled.
Squash the changes into the existing remove-gdk-x11.patch and change
the file name and commit description accordingly.
Add missing upstream status to patch
Related-to: ELB-5451
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
(cherry picked from commit 6b65323381ffd8d25d040b658dac26e7e781c967)
Diffstat (limited to 'recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch')
-rw-r--r-- | recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch | 136 |
1 files changed, 0 insertions, 136 deletions
diff --git a/recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch b/recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch deleted file mode 100644 index a1f97b3..0000000 --- a/recipes-graphics/gpicview/gpicview/remove-gdk-x11.patch +++ /dev/null @@ -1,136 +0,0 @@ -For xwayland gdk/gdkx.h does not work. -Remove the more elaborate gf_display_get_workarea function and use only -the fallback. ---- ./src/working-area.c.orig 2016-02-20 22:38:31.000000000 +0000 -+++ ./src/working-area.c 2020-01-07 13:37:47.023817524 +0000 -@@ -23,126 +23,11 @@ - */ - - # include <gdk/gdk.h> --# include <gdk/gdkx.h> --# include <X11/Xlib.h> --# include <X11/Xutil.h> --# include <X11/Xatom.h> -- --void get_working_area(GdkScreen* screen, GdkRectangle *rect); -- --static gboolean gf_display_get_workarea(GdkScreen* g_screen, GdkRectangle *rect) { -- Atom xa_desktops, xa_current, xa_workarea, xa_type; -- Display *x_display; -- Window x_root; -- guint32 desktops = 0, current = 0; -- gulong *workareas, len, fill; -- guchar *data; -- gint format; -- -- GdkDisplay *g_display; -- Screen *x_screen; -- -- /* get the gdk display */ -- g_display = gdk_display_get_default(); -- if(!g_display) -- return FALSE; -- -- /* get the x display from the gdk display */ -- x_display = gdk_x11_display_get_xdisplay(g_display); -- if(!x_display) -- return FALSE; -- -- /* get the x screen from the gdk screen */ -- x_screen = gdk_x11_screen_get_xscreen(g_screen); -- if(!x_screen) -- return FALSE; -- -- /* get the root window from the screen */ -- x_root = XRootWindowOfScreen(x_screen); -- -- /* find the _NET_NUMBER_OF_DESKTOPS atom */ -- xa_desktops = XInternAtom(x_display, "_NET_NUMBER_OF_DESKTOPS", True); -- if(xa_desktops == None) -- return FALSE; -- -- /* get the number of desktops */ -- if(XGetWindowProperty(x_display, x_root, xa_desktops, 0, 1, False, -- XA_CARDINAL, &xa_type, &format, &len, &fill, -- &data) != Success) -- { -- return FALSE; -- } -- -- if(!data) -- return FALSE; -- -- desktops = *(guint32 *)data; -- XFree(data); -- -- /* find the _NET_CURRENT_DESKTOP atom */ -- xa_current = XInternAtom(x_display, "_NET_CURRENT_DESKTOP", True); -- if(xa_current == None) -- return FALSE; -- -- /* get the current desktop */ -- if(XGetWindowProperty(x_display, x_root, xa_current, 0, 1, False, -- XA_CARDINAL, &xa_type, &format, &len, &fill, -- &data) != Success) -- { -- return FALSE; -- } -- -- if(!data) -- return FALSE; -- -- current = *(guint32 *)data; -- XFree(data); -- -- /* find the _NET_WORKAREA atom */ -- xa_workarea = XInternAtom(x_display, "_NET_WORKAREA", True); -- if(xa_workarea == None) -- return FALSE; -- -- if(XGetWindowProperty(x_display, x_root, xa_workarea, 0, (glong)(4 * 32), -- False, AnyPropertyType, &xa_type, &format, &len, -- &fill, &data) != Success) -- { -- return FALSE; -- } -- -- /* make sure the type and format are good */ -- if(xa_type == None || format == 0) -- return FALSE; -- -- /* make sure we don't have any leftovers */ -- if(fill) -- return FALSE; -- -- /* make sure len divides evenly by 4 */ -- if(len % 4) -- return FALSE; -- -- /* it's good, lets use it */ -- workareas = (gulong *)(guint32 *)data; -- -- rect->x = (guint32)workareas[current * 4]; -- rect->y = (guint32)workareas[current * 4 + 1]; -- rect->width = (guint32)workareas[current * 4 + 2]; -- rect->height = (guint32)workareas[current * 4 + 3]; -- -- /* clean up our memory */ -- XFree(data); -- -- return TRUE; --} - - void get_working_area(GdkScreen* screen, GdkRectangle *rect) - { -- if( !gf_display_get_workarea(screen, rect) ) -- { -- rect->x = 0; -- rect->y = 0; -- rect->width = gdk_screen_width(); -- rect->height = gdk_screen_height(); -- } -+ rect->x = 0; -+ rect->y = 0; -+ rect->width = gdk_screen_width(); -+ rect->height = gdk_screen_height(); - } |