From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eli Zaretskii To: tromey@redhat.com Cc: deephan@erols.com, gdb-patches@sources.redhat.com Subject: Re: [PATCH] specify arguments to debugee from commandline (second try) Date: Fri, 06 Apr 2001 01:32:00 -0000 Message-id: <200104060832.EAA17613@indy.delorie.com> References: <20010330005457.A21793@llamedos.org> <20010330163603.A27435@llamedos.org> <20010403013600.B7630@llamedos.org> <87n19uirbk.fsf@creche.redhat.com> X-SW-Source: 2001-04/msg00052.html > From: Tom Tromey > Date: 05 Apr 2001 22:29:35 -0600 > > I'd like to modify gcc so I can invoke: `gcj --debug jc1 ...' and have > gcc automatically insert `gdb --run' before the jc1 invocation. Then > gdb will come up with the arguments magically set. > > Likewise I'd like to be able to simply insert `gdb --run' into shell > scripts or any other program-launching code to get the debugger to do > the tedious work for me. Wouldn't such use get you in trouble in some cases anyway? The arguments you put after "gdb --run" are evaluated by the shell, so what GDB sees is not exactly what you typed. I'd imagine that in some cases this would produce subtle differences between "gdb --run" and issuing the `run' command inside GDB.