[petsc-users] Attaching to gdb within screen

John Fettig john.fettig at gmail.com
Wed Jun 22 09:40:29 CDT 2011


On Wed, Jun 22, 2011 at 10:12 AM, Jed Brown <jed at 59a2.org> wrote:
> On Wed, Jun 22, 2011 at 16:05, John Fettig <john.fettig at gmail.com> wrote:
>>
>> This makes no difference, because the script isn't executing. If it
>> makes any difference, I'm setting the options through the environment
>> variable "PETSC_OPTIONS"
>
> Hmm, only in that the arguments would need to be doubly escaped. I would
> expect that is working if you are getting one screen terminal to come up,
> but could you try using the command line with a PETSc example, e.g.
> src/ksp/ksp/examples/tutorials/ex2.c.

This is how I set PETSC_OPTIONS:

 export PETSC_OPTIONS="-start_in_debugger -debug_terminal \"screen -X
-S debug screen\""

I did try using the command line options only (unset $PETSC_OPTIONS
and used a petsc example), and that has the same problem.  If I only
run the command

screen -X -S debug screen redirect.sh gdb

It loads a new window in screen without issue.  So something funky is
happening inside petsc.

John


More information about the petsc-users mailing list