运行 Ubuntu 16.04。来自https://tutorials.ubuntu.com/tutorial/wayland-kiosk#0 制作 Wayland 原生 Kiosk snap
在https://tutorials.ubuntu.com/tutorial/wayland-kiosk#4,则会出现以下错误:
user@machine:~$miral-app -kiosk -launcher 'glmark2-wayland
产生错误:eglGetDisplay() 失败,错误原因:0x3000
下面是终端输出。
user@machine:~$miral-app
生成一个橙色的 Mir On X 窗口,随后出现一个黑色的终端窗口。
user@machine:~$miral-app -kiosk
在 X 窗口上产生一个黑色的 Mir,文件、编辑等无响应。
user@machine:~$miral-app -kiosk -launcher
产生一个黑色窗口,然后立即关闭。
您对如何完成本教程有什么建议吗?
user@machine:~$ miral-app -kiosk -launcher 'glmark2-wayland'
waiting for /run/user/1000/miral_socket
[2019-07-30 11:56:59.964833] <information> mirserver: Starting
[2019-07-30 11:56:59.965756] < - debug - > mirserver: Not trying logind: "DISPLAY" is set and X need not have claimed the VT
[2019-07-30 11:56:59.966590] < - debug - > mirserver: Not using Linux VT subsystem for session management: Failed to find the current VT
[2019-07-30 11:56:59.966626] < - debug - > mirserver: No session management supported
[2019-07-30 11:56:59.967042] <information> VT switch key handler: No VT switching support available: MinimalConsoleServices does not support VT switching
[2019-07-30 11:56:59.967707] <information> mircommon: Loading modules from: /usr/lib/x86_64-linux-gnu/mir/server-platform
[2019-07-30 11:56:59.967767] <information> mircommon: Loading module: /usr/lib/x86_64-linux-gnu/mir/server-platform/server-mesa-x11.so.16
[2019-07-30 11:56:59.967804] <information> mircommon: Loading module: /usr/lib/x86_64-linux-gnu/mir/server-platform/graphics-mesa-kms.so.16
[2019-07-30 11:56:59.967823] <information> mircommon: Loading module: /usr/lib/x86_64-linux-gnu/mir/server-platform/input-evdev.so.7
[2019-07-30 11:56:59.973179] <information> mirplatform: Found graphics driver: mir:mesa-x11 (version 1.3.0) Support priority: 128
[2019-07-30 11:56:59.973479] <information> mesa-kms: EGL platform does not support EGL_KHR_platform_gbm extension
[2019-07-30 11:56:59.973496] <information> mesa-kms: Unsupported: EGL platform supports neither EGL_KHR_platform_gbm nor EGL_MESA_platform_gbm
[2019-07-30 11:56:59.973510] <information> mirplatform: Found graphics driver: mir:mesa-kms (version 1.3.0) Support priority: 0
[2019-07-30 11:56:59.973747] <information> mirserver: Selected driver: mir:mesa-x11 (version 1.3.0)
[2019-07-30 11:57:00.223551] <information> display: Screen resolution = 1920x1080
[2019-07-30 11:57:00.223580] <information> display: ... is smaller than the requested size (1280x1024) plus border (150). Clipping to (1280x930).
[2019-07-30 11:57:00.223600] <information> display: 1 visual(s) found
[2019-07-30 11:57:00.223607] <information> display: Using the first one :
[2019-07-30 11:57:00.223614] <information> display: ID : 44
[2019-07-30 11:57:00.223621] <information> display: screen : 0
[2019-07-30 11:57:00.223629] <information> display: depth : 24
[2019-07-30 11:57:00.223636] <information> display: red_mask : 0xFF0000
[2019-07-30 11:57:00.223644] <information> display: green_mask : 0xFF00
[2019-07-30 11:57:00.223652] <information> display: blue_mask : 0xFF
[2019-07-30 11:57:00.223660] <information> display: colormap_size : 256
[2019-07-30 11:57:00.223667] <information> display: bits_per_rgb : 11
[2019-07-30 11:57:00.297508] <information> mirserver: Using software cursor
[2019-07-30 11:57:00.333119] <information> mirserver: Selected input driver: mir:x11-input (version: 1.3.0)
[2019-07-30 11:57:00.334962] < -warning- > Wayland: Failed to bind Wayland EGL display. Accelerated EGL will be unavailable.: /build/mir-zqFSab/mir-1.3.0/src/platforms/mesa/server/buffer_allocator.cpp(604): Throw in function virtual void mir::graphics::mesa::BufferAllocator::bind_display(wl_display*, std::shared_ptr<mir::Executor>)
Dynamic exception type: boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::system_error> >
std::exception::what: Failed to bind Wayland EGL display: EGL_SUCCESS (0x3000)
[2019-07-30 11:57:00.335015] < -warning- > mirserver: Cannot set Wayland protocol filter: wl_display_set_global_filter() is unavailable in libwayland-dev 1.12.0
[2019-07-30 11:57:00.335245] <information> mirserver: Mir version 1.3.0
[2019-07-30 11:57:00.365286] <information> GLRenderer: EGL vendor: NVIDIA
[2019-07-30 11:57:00.365313] <information> GLRenderer: EGL version: 1.4
[2019-07-30 11:57:00.365325] <information> GLRenderer: EGL client APIs: OpenGL_ES OpenGL
[2019-07-30 11:57:00.365334] <information> GLRenderer: GL vendor: NVIDIA Corporation
[2019-07-30 11:57:00.365340] <information> GLRenderer: GL renderer: Quadro M1000M/PCIe/SSE2
[2019-07-30 11:57:00.365345] <information> GLRenderer: GL version: OpenGL ES 3.2 NVIDIA 384.130
[2019-07-30 11:57:00.365351] <information> GLRenderer: GLSL version: OpenGL ES GLSL ES 3.20
[2019-07-30 11:57:00.365751] <information> GLRenderer: GL max texture size = 16384
[2019-07-30 11:57:00.365767] <information> GLRenderer: GL framebuffer bits: RGBA=8888, depth=0, stencil=0
[2019-07-30 11:57:00.369455] <information> mirserver: Initial display configuration:
[2019-07-30 11:57:00.369481] <information> mirserver: * Output 1: unknown connected, used
[2019-07-30 11:57:00.369496] <information> mirserver: . |_ Physical size 16.5" 338x246mm
[2019-07-30 11:57:00.369506] <information> mirserver: . |_ Power is on
[2019-07-30 11:57:00.369517] <information> mirserver: . |_ Current mode 1280x930 60.00Hz
[2019-07-30 11:57:00.369527] <information> mirserver: . |_ Preferred mode 1280x930 60.00Hz
[2019-07-30 11:57:00.369536] <information> mirserver: . |_ Orientation normal
[2019-07-30 11:57:00.369549] <information> mirserver: . |_ Logical size 1280x930
[2019-07-30 11:57:00.369559] <information> mirserver: . |_ Logical position +0+0
[2019-07-30 11:57:00.369569] <information> mirserver: . |_ Scaling factor: 1.00
Error: eglGetDisplay() failed with error: 0x3000
Error: eglGetDisplay() failed with error: 0x3000
Error: main: Could not initialize canvas
user@machine:~$ [2019-07-30 11:57:02.451237] < -warning- > mirserver: Attempt to read from WlShmBuffer after the wl_buffer has been destroyed
答案1
我可以解释一下您看到的一些情况。以下消息很不寻常(但对 Mir 来说并不致命),表明您的图形硬件与我所访问的任何硬件都不同:
[2019-07-30 11:57:00.334962] < -warning- > Wayland: Failed to bind Wayland EGL display. Accelerated EGL will be unavailable.: /build/mir-zqFSab/mir-1.3.0/src/platforms/mesa/server/buffer_allocator.cpp(604): Throw in function virtual void mir::graphics::mesa::BufferAllocator::bind_display(wl_display*, std::shared_ptr<mir::Executor>)
Dynamic exception type: boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::system_error> >
std::exception::what: Failed to bind Wayland EGL display: EGL_SUCCESS (0x3000)
虽然 Mir 可以继续工作,但是 glmark2-wayland 在遇到同样的事情时很可能会失败。
您可能会在 Ubuntu 18.04 上看到更好的结果,因为 Wayland 堆栈中的很多内容在 16.04 和 18.04 之间得到了改进。
miral-app
您在使用其他咒语(和)时看到的问题miral-app -kiosk
是由于 16.04 对 Wayland 的支持不佳造成的。它们与本教程无关,因此不值得在这里解释。