I need to write some gdb macros that need to different between 32 and 64 bit architectures. I'm looking for a way to determine in gdb whether the debugged executable is 32 or 64 bit.
info target includes info about file type
e.g. file type elf32-i386
but this is embedded in a longer output.
Being new to gdb macros, I don't know how to process that output, or find another way to get this.
Please, no python gdb for the time being.