Summary: | [GTK] [2.28.0] The Yelp build crashes if DISPLAY is not set | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Alberto Garcia <berto> | ||||||
Component: | WebKitGTK | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | bugs-noreply, cgarcia, clopez | ||||||
Priority: | P2 | ||||||||
Version: | Other | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
Alberto Garcia
2020-03-23 11:39:00 PDT
Ok, so we're hitting the RELEASE_ASSERT_NOT_REACHED() in AcceleratedBackingStore::checkRequirements(), and the reason is that the PlatformDisplay type is neither Wayland nor X11, but WPE. (In reply to Alberto Garcia from comment #1) > Ok, so we're hitting the RELEASE_ASSERT_NOT_REACHED() in > AcceleratedBackingStore::checkRequirements(), and the reason is that > the PlatformDisplay type is neither Wayland nor X11, but WPE. I think we can just remove that assert Created attachment 395152 [details]
Patch
Committed r259380: <https://trac.webkit.org/changeset/259380> It looks like the Yelp build still crashes, different backtrace this time: (process:35799): Gtk-CRITICAL **: 13:40:20.270: gtk_icon_theme_get_for_screen: assertion 'GDK_IS_SCREEN (screen)' failed ** (process:35799): WARNING **: 13:40:20.271: Unable to connect to dbus: Cannot autolaunch D-Bus without X11 $DISPLAY Unable to init server: Could not connect: Connection refused Segmentation fault Thread 1 "libyelp-scan" received signal SIGSEGV, Segmentation fault. 0x00007ffff335cbd4 in wpe_renderer_backend_egl_destroy (backend=0x0) at ./src/renderer-backend-egl.c:54 54 backend->base.interface->destroy(backend->base.interface_data); (gdb) bt #0 0x00007ffff335cbd4 in wpe_renderer_backend_egl_destroy (backend=0x0) at ./src/renderer-backend-egl.c:54 #1 0x00007ffff63bc8bb in WebCore::PlatformDisplayLibWPE::~PlatformDisplayLibWPE() () at ../Source/WebCore/platform/graphics/libwpe/PlatformDisplayLibWPE.cpp:66 #2 0x00007ffff63bc8d9 in WebCore::PlatformDisplayLibWPE::~PlatformDisplayLibWPE() () at ../Source/WebCore/platform/graphics/libwpe/PlatformDisplayLibWPE.cpp:67 #3 0x00007ffff7c59e27 in __run_exit_handlers (status=0, listp=0x7ffff7dd8718 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true, run_dtors=run_dtors@entry=true) at exit.c:108 #4 0x00007ffff7c59fda in __GI_exit (status=<optimized out>) at exit.c:139 #5 0x00007ffff7c42e12 in __libc_start_main (main= 0x555555556480 <main>, argc=1, argv=0x7fffffffdd78, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffffffdd68) at ../csu/libc-start.c:342 #6 0x0000555555557b7a in _start () at libyelp-scan.c:1025 So it seems that m_backend is null in the PlatformDisplayLibWPE destructor. I confirm that checking for null in wpe_renderer_backend_egl_destroy() is enough to avoid the crash and fix the Yelp build, but perhaps the change should be in WebKit ? I don't think we should create a PlatformDisplayLibWPE as fallback. We could fix it in PlatformDisplay::createPlatformDisplay() either: #if USE(WPE_RENDERER) -> #if USE(LIBWPE) or just move the block: #if USE(WPE_RENDERER) return PlatformDisplayLibWPE::create(); #elif PLATFORM(WIN) return PlatformDisplayWin::create(); #endif at the end of the function, right before the RELEASE_ASSERT_NOT_REACHED() Could you try any of these solutions, please? (In reply to Carlos Garcia Campos from comment #7) > or just move the block: > > #if USE(WPE_RENDERER) > return PlatformDisplayLibWPE::create(); > #elif PLATFORM(WIN) > return PlatformDisplayWin::create(); > #endif > > at the end of the function, right before the RELEASE_ASSERT_NOT_REACHED() I confirm that this one works and fixes the problem. Do you want me to try the other one, or to prepare a patch with this one, or what? Yes, please, just submit a patch with any of the solutions if you don't mind :-) Created attachment 397668 [details]
Patch
Committed r260750: <https://trac.webkit.org/changeset/260750> |