From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Zhongwei Yao Newsgroups: gmane.emacs.help Subject: Running M-x gdb hangs emacs Date: Thu, 22 Jan 2015 19:52:07 +0800 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1421927553 17650 80.91.229.3 (22 Jan 2015 11:52:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 22 Jan 2015 11:52:33 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Jan 22 12:52:32 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YEGJM-0003FC-2I for geh-help-gnu-emacs@m.gmane.org; Thu, 22 Jan 2015 12:52:32 +0100 Original-Received: from localhost ([::1]:52555 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEGJF-0006zu-M8 for geh-help-gnu-emacs@m.gmane.org; Thu, 22 Jan 2015 06:52:25 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51681) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEGJ2-0006zn-2m for help-gnu-emacs@gnu.org; Thu, 22 Jan 2015 06:52:13 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YEGIz-0004SR-11 for help-gnu-emacs@gnu.org; Thu, 22 Jan 2015 06:52:12 -0500 Original-Received: from mail-la0-x232.google.com ([2a00:1450:4010:c03::232]:62576) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YEGIy-0004SJ-Kc for help-gnu-emacs@gnu.org; Thu, 22 Jan 2015 06:52:08 -0500 Original-Received: by mail-la0-f50.google.com with SMTP id pn19so1109114lab.9 for ; Thu, 22 Jan 2015 03:52:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=7gEzszU9zDJitl/rCCa+dOJqJY9WtA8jm4sI2m8iCTA=; b=rY2118vB/5YX6UDIDKa0ppX12kqRQui8cQTokQFTF0e7QPwW8CqPvDVHW3gfQgc7FH g+D7nsw9j0wR3jKLUCgP/LamFzvYZSq5UR7/DjvSfxWJbCYdH6VVUA/ORs8B/6Xg2RYL UkqQE7dKnMXUefknJ4ZH59WjPCUTSUd7s/LQKg1U3j6ODTRrmRQ11grmZ8Vx1EUegYu3 68yEaj+pHnSr5Y65WgDimtAn4X22Big76Yn5Yen0yV9kjG/HwVeHRhk2RCO4xIq3lzMt p/87BCWmCD10oUqoMQlmdEa/vrRRTf8/TRyv0uyFC7fd16KgZUG6+a9m062DHc/cShyc HsKQ== X-Received: by 10.152.120.97 with SMTP id lb1mr1077583lab.76.1421927527078; Thu, 22 Jan 2015 03:52:07 -0800 (PST) Original-Received: by 10.114.59.17 with HTTP; Thu, 22 Jan 2015 03:52:07 -0800 (PST) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::232 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102212 Archived-At: Hi, all, When run M-x gdb with following command: gdb -i=mi -x ~/.gdb/config and the .gdb/config file are: ==config== set non-stop off file /my/path/to/exe-file target remote 192.168.1.2:5049 break func_foo ==config== emacs returns me a buffer *gud-config* with following content: ==*gud-config* buffer== Current directory is ~/.gdb/ GNU gdb (GDB) 7.6 Copyright (C) 2013 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "--host=x86_64-linux-gnu --target=arm-linux-android". For bug reporting instructions, please see: . warning: Unable to find dynamic linker breakpoint function. GDB will be unable to debug shared library initializers and track explicitly loaded dynamic code.Cannot access memory at address 0x0 ==*gud-config* buffer== Then emacs will hang there. However, I can get gdb work by running: gdb -x ~/.gdb/config in bash. It returns: ==*gdb in bash*== GNU gdb (GDB) 7.6 Copyright (C) 2013 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "--host=x86_64-linux-gnu --target=arm-linux-android". For bug reporting instructions, please see: . warning: Unable to find dynamic linker breakpoint function. GDB will be unable to debug shared library initializers and track explicitly loaded dynamic code. 0xf77b6254 in ?? () Cannot access memory at address 0x0 Breakpoint 1 at 0xab0cd2e4: file ../../test_foo.c, line 29. (gdb) ==*gdb in bash*== How can get gdb also work in emacs? Thanks a lot! -- Zhongwei