were the segfaults because of -ggdb? I added back -g (so the options are -Og -g) and stuff seems to be working with gdb 7.8