Changeset 36596


Ignore:
Timestamp:
2013-05-09T22:50:58+02:00 (5 years ago)
Author:
nbd
Message:

scripts/remote-gdb: add support for debugging core files

Signed-off-by: Felix Fietkau <nbd@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/scripts/remote-gdb

    r36595 r36596  
    77 
    88@ARGV == 2 || do { 
    9         die "Usage: $0 <host:port> <executable>\n"; 
     9        die "Usage: $0 <corefile|host:port> <executable>\n"; 
    1010        exit 1; 
    1111}; 
     
    6262 
    6363                print $fh "set sysroot $sysroot\n" if $sysroot; 
    64                 print $fh "target remote $ARGV[0]\n"; 
     64                my $cmd = "target remote"; 
     65                -f $ARGV[0] and $cmd = "core-file"; 
     66                print $fh "$cmd $ARGV[0]\n"; 
    6567 
    6668                my $file = -f "$sysroot/$ARGV[1]" ? "$sysroot/$ARGV[1]" : $ARGV[1]; 
Note: See TracChangeset for help on using the changeset viewer.