From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nick Roberts Newsgroups: gmane.emacs.help Subject: Re: getting gdb init work on emacs Date: Thu, 3 Apr 2008 15:01:11 +1200 Message-ID: <18420.18551.534227.789959@kahikatea.snap.net.nz> References: <18384.25918.2128.237860@kahikatea.snap.net.nz> <179478.4948.qm@web57711.mail.re3.yahoo.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1207191720 17599 80.91.229.12 (3 Apr 2008 03:02:00 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 3 Apr 2008 03:02:00 +0000 (UTC) Cc: gnu-emacs-help@gnu.org To: "Sanjeev Kumar.S" Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Apr 03 05:02:31 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JhFig-0005m0-Mz for geh-help-gnu-emacs@m.gmane.org; Thu, 03 Apr 2008 05:02:30 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JhFi4-0006ZX-Ed for geh-help-gnu-emacs@m.gmane.org; Wed, 02 Apr 2008 23:01:52 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JhFhp-0006ZI-T8 for help-gnu-emacs@gnu.org; Wed, 02 Apr 2008 23:01:37 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JhFho-0006Z6-6j for help-gnu-emacs@gnu.org; Wed, 02 Apr 2008 23:01:37 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JhFhn-0006Z3-Uk for help-gnu-emacs@gnu.org; Wed, 02 Apr 2008 23:01:35 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JhFhn-00006F-Jt for help-gnu-emacs@gnu.org; Wed, 02 Apr 2008 23:01:35 -0400 Original-Received: from mx10.gnu.org ([199.232.76.166]) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1JhFhn-0007Cr-9G for gnu-emacs-help@gnu.org; Wed, 02 Apr 2008 23:01:35 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1JhFhj-00005v-FA for gnu-emacs-help@gnu.org; Wed, 02 Apr 2008 23:01:34 -0400 Original-Received: from mx2.snap.net.nz ([202.37.101.25] helo=viper.snap.net.nz) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JhFhi-00005U-VK for gnu-emacs-help@gnu.org; Wed, 02 Apr 2008 23:01:31 -0400 Original-Received: from kahikatea.snap.net.nz (2.60.255.123.dynamic.snap.net.nz [123.255.60.2]) by viper.snap.net.nz (Postfix) with ESMTP id 1C3143D9FD1; Thu, 3 Apr 2008 16:01:25 +1300 (NZDT) Original-Received: by kahikatea.snap.net.nz (Postfix, from userid 1000) id 5D76A8FC6D; Thu, 3 Apr 2008 15:01:15 +1200 (NZST) In-Reply-To: <179478.4948.qm@web57711.mail.re3.yahoo.com> X-Mailer: VM 7.19 under Emacs 22.1.92.3 X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:52996 Archived-At: > define lwlan > set $kld = linker_files.tqh_first > while ($kld != 0) > if [$kld->filename=="wlan.ko"] \ > printf "0x%08x %s\n", $kld->address, $kld->filename > end > set $kld = $kld->link.tqe_next > end > end > > running it gives me this : > > (kgdb) lwlan > A syntax error in expression, near `[$kld->filename=="wlan.ko"] printf "0x%08x %s\n", $kld->address, $kld->filename'. > > by the way does it follow the shell syntax or No. Which is why square brackets don't work. > is there any other syntax ? See the Sequences node of the Gdb manual. The syntax is quite restricted and expressions like $kld->filename won't work. There is currently work being done on Python scripting. This is being reported on the gdb mailing list (gdb@sourceware.org) which is where this question should really go as it's about Gdb. -- Nick http://www.inet.net.nz/~nickrob