Re: How to debug xfree86 successfully

Marc Aurele La France <[email protected]>
Newsgroups gmane.comp.xfree86.devel
Message-ID <[email protected]>
On Fri, 4 Nov 2005, cckuo wrote:

>  I want to trace the behaviors of my video driver under Xfree86 and
> have done the following steps which were collected from this mailing list.

> 1. prepare two machines; one is called host, and another is called target.
> 2. type "makeg World" under "xc" folder
> 3. telnet the target from host and run "gdb /usr/X11R6/bin/XFree86"
> 4. under the gdb command mode type "run :0"

> Here my question comes from. I type "list" under gdb command mode.

> I saw the source code of XFree86, main.c, but if I set the breakpoint
> about the driver functions such as Probe, ScreenInit and EnterVT, which are
> assigned to pScrn. The gdb told me that he cannot find the symbol file.

> Are there some steps between 1-4 I made wrong or in fact I didn't build the
> symbol file correctly?

The most straight-forward way of debugging an X server is to build it with 
...

 	#define DoLoadableServer NO

... in your xc/config/cf/host.def.  After a `make World`, this'll build 
everything into one binary.

Marc.

+----------------------------------+-----------------------------------+
|  Marc Aurele La France           |  work:   1-780-492-9310           |
|  Academic Information and        |  fax:    1-780-492-1729           |
|    Communications Technologies   |  email:  [email protected]          |
|  352 General Services Building   +-----------------------------------+
|  University of Alberta           |                                   |
|  Edmonton, Alberta               |     Standard disclaimers apply    |
|  T6G 2H1                         |                                   |
|  CANADA                          |                                   |
+----------------------------------+-----------------------------------+
XFree86 developer and VP.  ATI driver and X server internals.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.