Skip to content

xwayland: Detect gbm_bo_get_fd_for_plane at runtime

Daniel van Vugt requested to merge vanvugt/xserver:dynamic-gbm into master

gbm_bo_get_fd_for_plane was introduced in Mesa 21 but some proprietary GBM implementations (Xilinx) still haven't been updated to support it:

/usr/bin/Xwayland: symbol lookup error: /usr/bin/Xwayland: undefined symbol: gbm_bo_get_fd_for_plane

Since distros would like to build a single Xwayland binary for all OEMs of the same architecture, we now make the function always available.

If a real implementation of gbm_bo_get_fd_for_plane exists at runtime then it will be used, otherwise fall back to gbm_bo_get_fd or fail.

Edited by Daniel van Vugt

Merge request reports