From owner-freebsd-hackers@FreeBSD.ORG Fri Aug 15 23:13:27 2003 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A80637B401 for ; Fri, 15 Aug 2003 23:13:27 -0700 (PDT) Received: from rhaaw.rdsnet.ro (rhaaw.rdsnet.ro [212.93.133.32]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9EFC943FB1 for ; Fri, 15 Aug 2003 23:13:26 -0700 (PDT) (envelope-from xoanon@rhaaw.rdsnet.ro) Received: from [192.168.0.3] (helo=rhaaw.rdsnet.ro) by rhaaw.rdsnet.ro with esmtp (Exim 4.20) id 19nuL0-0002mE-PA for freebsd-hackers@freebsd.org; Sat, 16 Aug 2003 09:14:54 +0300 Message-ID: <3F3DCBC6.10805@rhaaw.rdsnet.ro> Date: Sat, 16 Aug 2003 09:14:30 +0300 From: Vladimir Ciobanu User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.3.1) Gecko/20030524 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Debugging symbols with nasm X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Aug 2003 06:13:27 -0000 I'm not sure whether this is the best list to post to, but it's my first guess. I'm using nasm to compile some code I wrote. The developer-handbook suggests I use "-f elf", so that's what I did. Then I linked it with ld. The program works as expected, but I can't debug it with gdb; it reports "no debugging symbols found". I've tried to get the possible debugging formats nasm can output, and I get "null" for both elf and aoutb ( ld can't even link aoutb .o files ). Is there a way I could debug my nasm-compiled assembler sources, preferably with gdb ? I don't mind any binary format that can run on FreeBSD, nor any other linker. Any suggestions are welcome. For completeness, here's the versions of the tools I used, and FreeBSD: FreeBSD 5.1-RELEASE --- GNU ld version 2.13.2 [FreeBSD] 2002-11-27 Supported emulations: elf_i386_fbsd --- NASM version 0.98.35 compiled on Aug 13 2003 --- GNU gdb 5.2.1 (FreeBSD)