2
« on: February 04, 2017, 06:25:41 am »
So, I compiled gtk2, libx11, and sfml with debug symbols, and here is what I get for a back trace when breaking on gdk_x_error.
Versions used are:
libx11-1.6.4
gtk2-2.24.31
sfml-2.4.1
wxgtk-3.0.2
[dmartins@sirschmoopy tmp]$ g++ -g `wx-config --cxxflags` `pkg-config --cflags sfml-graphics` `pkg-config --cflags gtk+-2.0` -o test main.cpp `wx-config --libs` `pkg-config --libs sfml-graphics` `pkg-config --libs gtk+-2.0`
[dmartins@sirschmoopy tmp]$ gdb ./test
GNU gdb (GDB) 7.12.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./test...done.
(gdb) break main
Breakpoint 1 at 0x409b1b: file main.cpp, line 78.
(gdb) run --sync
Starting program: /home/dmartins/tmp/test --sync
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
Breakpoint 1, main (argc=2, argv=0x7fffffffe8a8) at main.cpp:78
78 wxIMPLEMENT_APP(MyApp);
(gdb) break gdk_x_error
Breakpoint 2 at 0x7ffff4ec7770: file gdkmain-x11.c, line 458.
(gdb) continue
Continuing.
[New Thread 0x7fffdbfba700 (LWP 6734)]
[New Thread 0x7fffdb5b4700 (LWP 6735)]
[New Thread 0x7fffdadb3700 (LWP 6736)]
[New Thread 0x7fffda5b2700 (LWP 6737)]
[New Thread 0x7fffd9db1700 (LWP 6738)]
Thread 1 "test" hit Breakpoint 2, gdk_x_error (display=0x75d000, error=0x7fffffffdec0) at gdkmain-x11.c:458
458 {
(gdb) bt
#0 0x00007ffff4ec7770 in gdk_x_error (display=0x75d000, error=0x7fffffffdec0) at gdkmain-x11.c:458
#1 0x00007fffeff476fd in _XError (dpy=dpy@entry=0x75d000, rep=rep@entry=0x9c3db0) at XlibInt.c:1434
#2 0x00007fffeff44627 in handle_error (dpy=0x75d000, err=0x9c3db0, in_XReply=<optimized out>) at xcb_io.c:199
#3 0x00007fffeff446e5 in handle_response (dpy=0x75d000, response=0x9c3db0, in_XReply=<optimized out>)
at xcb_io.c:311
#4 0x00007fffeff455f8 in _XReply (dpy=dpy@entry=0x75d000, rep=rep@entry=0x7fffffffe0a0, extra=extra@entry=0, discard=discard@entry=1) at xcb_io.c:621
#5 0x00007fffeff302ff in XInternAtom (dpy=dpy@entry=0x75d000, name=0x7fffffffe1c0 "WM_PROTOCOLS", onlyIfExists=onlyIfExists@entry=0) at IntAtom.c:181
#6 0x00007ffff5974a4e in sf::priv::getAtom(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, bool) (name="WM_PROTOCOLS", onlyIfExists=onlyIfExists@entry=false)
at /home/dmartins/abs/sfml/src/SFML/src/SFML/Window/Unix/Display.cpp:99
#7 0x00007ffff597a5dd in sf::priv::WindowImplX11::setProtocols() (this=this@entry=0x983cd0)
at /home/dmartins/abs/sfml/src/SFML/src/SFML/Window/Unix/WindowImplX11.cpp:1198
#8 0x00007ffff597af67 in sf::priv::WindowImplX11::WindowImplX11(unsigned long) (this=0x983cd0, handle=62914604)
at /home/dmartins/abs/sfml/src/SFML/src/SFML/Window/Unix/WindowImplX11.cpp:420
#9 0x00007ffff5973311 in sf::priv::WindowImpl::create(unsigned long) (handle=handle@entry=62914604)
at /home/dmartins/abs/sfml/src/SFML/src/SFML/Window/WindowImpl.cpp:78
#10 0x00007ffff5972f5e in sf::Window::create(unsigned long, sf::ContextSettings const&) (this=0x7fffffffe3f0, handle=62914604, settings=...) at /home/dmartins/abs/sfml/src/SFML/src/SFML/Window/Window.cpp:141
#11 0x00007ffff5bc1ba8 in sf::RenderWindow::RenderWindow(unsigned long, sf::ContextSettings const&) (this=0x7fffffffe3f0, handle=62914604, settings=...) at /home/dmartins/abs/sfml/src/SFML/src/SFML/Graphics/RenderWindow.cpp:53
#12 0x0000000000409abe in MyControl::MyControl(wxWindow*, int, wxPoint const&, wxSize const&, long, wxValidator const&, wxString const&) (this=0x75c000, parent=0x755370, id=-1, pos=..., size=..., style=0, validator=..., name=...)
at main.cpp:75
#13 0x00000000004098c1 in MyFrame::MyFrame() (this=0x755370) at main.cpp:50
#14 0x000000000040976a in MyApp::OnInit() (this=0x69ffa0) at main.cpp:39
#15 0x000000000040a32b in wxAppConsoleBase::CallOnInit() (this=0x69ffa0) at /usr/include/wx-3.0/wx/app.h:93
#16 0x00007ffff5edac42 in wxEntry(int&, wchar_t**) () at /usr/lib/libwx_baseu-3.0.so.0
#17 0x0000000000409b2e in main(int, char**) (argc=2, argv=0x7fffffffe8a8) at main.cpp:78