GDB - Dwarf Error: wrong version in compilation unit header (is 3, should be 2)

3,268 views
Skip to first unread message

Joseph Poirier

unread,
Oct 29, 2010, 11:35:31 AM10/29/10
to golang-nuts
I'm running OS 10.6.4. GDB gives the error for a simple hello world
program. Any thoughts (GDB bug, sections need to be reordered,...)?

-joe

Ian Lance Taylor

unread,
Oct 29, 2010, 11:55:50 AM10/29/10
to Joseph Poirier, golang-nuts
Joseph Poirier <jdpo...@gmail.com> writes:

> I'm running OS 10.6.4. GDB gives the error for a simple hello world
> program. Any thoughts (GDB bug, sections need to be reordered,...)?

Sounds like your version of gdb only supports DWARF2, not DWARF3. I
recommend building a newer version. http://sourceware.org/gdb/download/

Ian

Joseph Poirier

unread,
Oct 29, 2010, 12:33:23 PM10/29/10
to Ian Lance Taylor, golang-nuts
Will do...thanks!

-joe

Reply all
Reply to author
Forward
0 new messages