Ticket #4710: debug-mythfrontend.cmd_debug-mythbackend.cmd.patch
File debug-mythfrontend.cmd_debug-mythbackend.cmd.patch, 4.6 KB (added by , 18 years ago) |
---|
-
contrib/Win32/debug-mythbackend.cmd
1 @Echo off 2 :: 3 :: Script to run mythbackend through gdb (easily?) 4 :: There is likely a more efficient way of doing this, 5 :: but we have to start somewhere. 6 :: 7 Echo COMMENTS: -------------------------------------- 8 Echo COMMENTS: This script is used for gathering backtraces using gdb 9 Echo COMMENTS: See: http://www.mythtv.org/docs/mythtv-HOWTO-22.html#ss22.2 10 Echo COMMENTS: See: http://www.mythtv.org/wiki/index.php/Windows_Port 11 Echo COMMENTS: -------------------------------------- 12 Echo. 13 :: 14 :gdbcommands 15 :: 16 :: Check for and Create if needed the .\gdbcommands.txt 17 :: 18 :: syntax taken from [ http://www.mythtv.org/docs/mythtv-HOWTO.html#toc22.2 ] 19 :: 20 if not exist ./gdbcommands.txt ( 21 echo handle SIGPIPE nostop noprint > .\gdbcommands.txt 22 echo handle SIG33 nostop noprint >> .\gdbcommands.txt 23 echo set logging on >> .\gdbcommands.txt 24 echo set pagination off >> .\gdbcommands.txt 25 echo set args -l myth.log --noupnp --nosched --nojobqueue --nohousekeeper --noautoexpire -v all >> .\gdbcommands.txt 26 echo run >> .\gdbcommands.txt 27 echo thread apply all bt full >> .\gdbcommands.txt 28 echo set logging off >> .\gdbcommands.txt ) 29 @Echo off 30 31 Echo COMMENTS: -------------------------------------- 32 Echo COMMENTS: Clearing old gdb.txt before running gdb again. 33 Echo COMMENTS: -------------------------------------- 34 Echo. 35 :: 36 :: add current data/time to gdb.txt 37 :: will this be a bad idea? who knows? =) 38 :: 39 date /t > .\gdb.txt 40 time /t >> .\gdb.txt 41 42 :gdb 43 :: 44 :: gdb should be in the path. 45 :: 46 Echo COMMENTS: -------------------------------------- 47 Echo COMMENTS: If you need to add any switches to mythbackend edit gdbcommands.txt 48 Echo COMMENTS: see: "mythbackend.exe --help" for options 49 Echo COMMENTS: -------------------------------------- 50 Echo. 51 Echo COMMENTS: -------------------------------------- 52 Echo COMMENTS: Starting: gdb 53 Echo COMMENTS: -------------------------------------- 54 gdb .\mythbackend.exe -x .\gdbcommands.txt 55 56 Echo. 57 Echo The backtrace can be found in .\gdb.txt 58 Echo. 59 No newline at end of file -
contrib/Win32/debug-mythfrontend.cmd
1 @Echo off 2 :: 3 :: Script to run mythfrontend through gdb (easily?) 4 :: There is likely a more efficient way of doing this, 5 :: but we have to start somewhere. 6 :: 7 Echo COMMENTS: -------------------------------------- 8 Echo COMMENTS: This script is used for gathering backtraces using gdb 9 Echo COMMENTS: See: http://www.mythtv.org/docs/mythtv-HOWTO-22.html#ss22.2 10 Echo COMMENTS: See: http://www.mythtv.org/wiki/index.php/Windows_Port 11 Echo COMMENTS: -------------------------------------- 12 Echo. 13 :: 14 :gdbcommands 15 :: 16 :: Check for and Create if needed the .\gdbcommands.txt 17 :: 18 :: syntax taken from [ http://www.mythtv.org/docs/mythtv-HOWTO.html#toc22.2 ] 19 :: 20 if not exist ./gdbcommands.txt ( 21 echo handle SIGPIPE nostop noprint > .\gdbcommands.txt 22 echo handle SIG33 nostop noprint >> .\gdbcommands.txt 23 echo set logging on >> .\gdbcommands.txt 24 echo set pagination off >> .\gdbcommands.txt 25 echo set args -l myth.log --noupnp --nosched --nojobqueue --nohousekeeper --noautoexpire -v all >> .\gdbcommands.txt 26 echo run >> .\gdbcommands.txt 27 echo thread apply all bt full >> .\gdbcommands.txt 28 echo set logging off >> .\gdbcommands.txt ) 29 @Echo off 30 31 Echo COMMENTS: -------------------------------------- 32 Echo COMMENTS: Clearing old gdb.txt before running gdb again. 33 Echo COMMENTS: -------------------------------------- 34 Echo. 35 :: 36 :: add current data/time to gdb.txt 37 :: will this be a bad idea? who knows? =) 38 :: 39 date /t > .\gdb.txt 40 time /t >> .\gdb.txt 41 42 :gdb 43 :: 44 :: gdb should be in the path. 45 :: 46 Echo COMMENTS: -------------------------------------- 47 Echo COMMENTS: If you need to add any switches to mythfrontend edit gdbcommands.txt 48 Echo COMMENTS: see: "mythbackend.exe --help" for options 49 Echo COMMENTS: -------------------------------------- 50 Echo. 51 Echo COMMENTS: -------------------------------------- 52 Echo COMMENTS: Starting: gdb 53 Echo COMMENTS: -------------------------------------- 54 gdb .\mythfrontend.exe -x .\gdbcommands.txt 55 Echo. 56 Echo The backtrace can be found in .\gdb.txt 57 Echo. 58