emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#44151: closed (trmap: remote gdb with ssh doesn't work)


From: GNU bug Tracking System
Subject: bug#44151: closed (trmap: remote gdb with ssh doesn't work)
Date: Sat, 01 May 2021 10:14:03 +0000

Your message dated Sat, 01 May 2021 12:13:22 +0200
with message-id <87pmyaahj1.fsf@gmx.de>
and subject line Re: bug#28392: 26.0.50; gdb-mi runs into error with tramp
has caused the debbugs.gnu.org bug report #28392,
regarding trmap: remote gdb with ssh doesn't work
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
28392: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=28392
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: trmap: remote gdb with ssh doesn't work Date: Thu, 22 Oct 2020 21:01:26 +0200 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (darwin)
Hi,

I tried to run the debug remote program with gdb via ssh. I followed the
instructions from the [[info:tramp#Remote processes][info:tramp#Remote 
processes]]:

,----
| 5.5.5 Running a debugger on a remote host
| -----------------------------------------
| 
| ‘gud.el’ provides a unified interface to symbolic debuggers (*note
| (emacs)Debuggers::).  TRAMP can run debug on remote hosts by calling
| ‘gdb’ with a remote file name:
| 
|      M-x gdb <RET>
|      Run gdb (like this): gdb -i=mi /ssh:host:~/myprog <RET>
`----

However, after the program to debug is read, it looks like there is some
error setting up gdb's inferior tty?

---------------------------------8<------------------------------------- 
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /home/wx/tmp/a.out...

Debugger entered--Lisp error: (wrong-type-argument "consp nil")
  signal(wrong-type-argument ("consp nil"))
  tramp-signal-hook-function(wrong-type-argument (consp nil))
  signal(wrong-type-argument (consp nil))
  tramp-sh-handle-make-process(:name "gdb-inferior" :buffer #<buffer limbo<3>> 
:command nil :stderr nil :noquery nil :file-handler t)
  apply(tramp-sh-handle-make-process (:name "gdb-inferior" :buffer #<buffer 
limbo<3>> :command nil :stderr nil :noquery nil :file-handler t))
  tramp-sh-file-name-handler(make-process :name "gdb-inferior" :buffer #<buffer 
limbo<3>> :command nil :stderr nil :noquery nil :file-handler t)
  apply(tramp-sh-file-name-handler make-process (:name "gdb-inferior" :buffer 
#<buffer limbo<3>> :command nil :stderr nil :noquery nil :file-handler t))
  tramp-file-name-handler(make-process :name "gdb-inferior" :buffer #<buffer 
limbo<3>> :command nil :stderr nil :noquery nil :file-handler t)
  tramp-handle-start-file-process("gdb-inferior" #<buffer limbo<3>> nil)
  apply(tramp-handle-start-file-process ("gdb-inferior" #<buffer limbo<3>> nil))
  tramp-sh-file-name-handler(start-file-process "gdb-inferior" #<buffer 
limbo<3>> nil)
  apply(tramp-sh-file-name-handler start-file-process ("gdb-inferior" #<buffer 
limbo<3>> nil))
  tramp-file-name-handler(start-file-process "gdb-inferior" #<buffer limbo<3>> 
nil)
  apply(tramp-file-name-handler start-file-process "gdb-inferior" #<buffer 
limbo<3>> nil nil)
  start-file-process("gdb-inferior" #<buffer limbo<3>> nil)
  apply(start-file-process "gdb-inferior" #<buffer limbo<3>> nil nil)
  comint-exec-1("gdb-inferior" #<buffer limbo<3>> nil nil)
  comint-exec(#<buffer limbo<3>> "gdb-inferior" nil nil nil)
  make-comint-in-buffer("gdb-inferior" #<buffer limbo<3>> nil)
  gdb-inferior-io-mode()
  gdb-get-buffer-create(gdb-inferior-io)
  gdb-init-1()
  gdb-update()
  gdb("gdb -i=mi /ssh:wx@SERVER:/home/wx/tmp...")
  funcall-interactively(gdb "gdb -i=mi /ssh:wx@SERVER:/home/wx/tmp...")
  call-interactively(gdb record nil)
  command-execute(gdb record)
  execute-extended-command(nil "gdb" nil)
  funcall-interactively(execute-extended-command nil "gdb" nil)
  call-interactively(execute-extended-command nil nil)
  command-execute(execute-extended-command)
---------------------------------8<------------------------------------- 

I tested it with `-Q' by building the latest emacs in the git:

GNU Emacs 28.0.50 (build 1, x86_64-apple-darwin18.7.0, NS appkit-1671.60 
Version 10.14.6 (Build 18G6032)) of 2020-10-22

-- 
William





--- End Message ---
--- Begin Message --- Subject: Re: bug#28392: 26.0.50; gdb-mi runs into error with tramp Date: Sat, 01 May 2021 12:13:22 +0200 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)
Version: 27.3

Jim Porter <jporterbugs@gmail.com> writes:

> Attached are patches to fix this in Emacs 27 and 28; they're
> essentially the same, but with slightly different contexts around the
> diff. I'm not sure if this is wanted for Emacs 27, but it's a small
> bugfix, and combined with my patch in bug#39408 (and the GNU ELPA
> version of Tramp to fix bug#44151), M-x gdb should work correctly for
> Tramp. For Emacs 28, this is the only outstanding issue (that I know
> of) preventing M-x gdb from working with Tramp.
>
> The problem here was that `gud-last-frame', set in
> `gdb-frame-handler', expects a local file path, so the full Tramp path
> was confusing it.

Pushed to both the emacs-27 and master branch. Closing the bug.

I don't know whether there will be an Emacs 27.3, but it doesn't hurt to
push the fix, I believe.

Best regards, Michael.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]