1)
xterm -e gdb drizzle
2)
xterm -e bash -c 'gdb drizzled <<EOF
heredoc ...
EOF'
The -e
option to xterm
doesn't run a shell, so you need to invoke bash
explicitly if you want to use shell features like here-doc.
If you want the xterm to stick around after a command executes, use:
xterm -e bash -c 'command; echo Press return to exit; read x'