xlib集成调试(Tracing)
Xlib (libX11.so) 中是否内置了任何调试选项?我可以获得 X11 lib 调用的列表吗?
我想从重型多线程、闭源程序中获取 xlib 函数调用的完整跟踪。它是一个非公开的嵌入式平台,因此我无法使用gdb进行多线程调试,并且该平台上没有ltrace。 另外,该程序无法通过 tcp/ip 连接到 x 服务器,只能通过 unix-socket 连接。我想跟踪 xlib 本身的 xlib 调用。
附: Xlib 来自相当现代的 xfree 甚至 xorg。来自 gnu linux
Is there any debugging options built-in in the Xlib (libX11.so)? Can I get list of X11 lib calls?
I want to get full trace of xlib function calls from heavy-multithreaded, closed-source program. It is one not-public embedded platform, so I can't use gdb for multithreaded debugging and there is no ltrace on the platform.
Also, this program can't connect to x server over tcp/ip, only unix-socket. I want to do tracing of xlib calls from xlib itself.
ps. Xlib from rather modern xfree or even xorg. from gnu linux
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您也许可以使用 xscope< /a> 监视通过 Unix 套接字发送的请求,即使您无法通过 TCP 发送 X 协议也能够使用网络监视工具,例如 Wireshark。
You may be able to use xscope to monitor the requests sent over a Unix socket, even when you can't send the X protocol over TCP to be able to use network monitoring tools like Wireshark.
您可以查看 xlibtrace,它跟踪 Xlib 和您的代码之间的接口,而不是 X Windows 有线协议。我已经执行了几个示例,它似乎有效。
源代码可在 http://kev.pulo.com.au/xlibtrace
我必须修改它以使其编译:
You might look into xlibtrace, which traces at the interface between Xlib and your code, rather than the X Windows wire protocol. I've executed a couple of the examples, and it seems to work.
The source is available at http://kev.pulo.com.au/xlibtrace
I had to modify it to get it to compile: