Gdb and g95

Mannucci, Anthony J (335G) anthony.j.mannucci at jpl.nasa.gov
Mon May 24 22:27:44 PDT 2010


No, I did not use -ggdb. However I tried it and that does not seem to work.

Here is the resolution: the -g3 option. The set up that works is the Apple build of gdb (6.5.3) and the -g3 compiler option with either gfortran or g95. Debugging then works with the apple gdb but not the macports gdb (7.1). This appears to be a very complex issue. I am thinking that machoread.c is specifically for Darwin (see the error message below). Something is broken in it, however. Apple's build seems to fix this.

I consider the matter resolved: use the -g3 option and the Apple-supplied gdb. The wizards at macports might address the macports version of gdb at some point. By the way, this sort of problem appears to affect fortran. C, C++, etc. appears to have much less problem (my experience).

Much thanks.

-Tony

Message: 6
Date: Sun, 23 May 2010 19:47:50 -0400
From: Jean-Francois Gobin <jf at gobinjf.be>
To: "Mannucci, Anthony J (335G)" <anthony.j.mannucci at jpl.nasa.gov>
Cc: "macports-users at lists.macosforge.org"
        <macports-users at lists.macosforge.org>
Subject: Re: Gdb and g95
Message-ID: <1274658470.2502.29.camel at Ubuntu01>
Content-Type: text/plain; charset="utf-8"

Could you try using "-ggdb" instead?

J.



On Sun, 2010-05-23 at 16:09 -0700, Mannucci, Anthony J (335G) wrote:
> I have installed gdb and fortran compiler g95 using macports. The debugger
> does not function with the fortran compiler. It does function with gcc
> compiling c programs.
>
> Nor does the standard gdb that ships with Apple developer tools work. The
> Apple gdb cannot set breakpoints in the fortran code. I have tried both the
> gfortran and g95 (Macports) compilers, and neither works with gdb.
>
> This is OS X leopard 10.5.x.
>
> Compiling as follows:
> g95 -g -c test4.f
> g95 -g test4.o -o test4.e
>
> Macintosh-10:382:tests $ which gdb
> /opt/local/bin/gdb
>
> Invoking gdb on the file test4.e yields the following error message.
>
> Macintosh-10:383:tests $ gdb test4.e
> GNU gdb (GDB) 7.1
> Copyright (C) 2010 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later
> <http://gnu.org/licenses/gpl.html>
> 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 "i386-apple-darwin9.8.0".
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>...
> Reading symbols from
> /Users/mannucci/timegcm/tests/test4.e...machoread.c:169: internal-error:
> macho_symtab_read: Assertion `oso_file != NULL' failed.
> A problem internal to GDB has been detected,
> further debugging may prove unreliable.
>
> ================================
> This is the error I received trying to build gdb on my own. Debugging
> fortran code on Darwin has proved to be a challenge.
>
> -Tony
>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <http://lists.macosforge.org/pipermail/macports-users/attachments/20100523/d090972e/attachment-0001.bin>

------------------------------

Message: 7
Date: Mon, 24 May 2010 09:34:11 +0300
From: Panayotis Katsaloulis <panayotis at panayotis.com>
To: MacPorts Users <macports-users at lists.macosforge.org>
Subject: Re: xmlto fails to build with macports 1.90 beta
Message-ID: <F6074BD6-9058-47AE-8992-EA3E593E03E6 at panayotis.com>
Content-Type: text/plain; charset=iso-8859-7


On 23 ??? 2010, at 10:15 ?.?., Panayotis Katsaloulis wrote:

> Hello!
>
> I decided to have a go with 1.90 and I tried to compile a couple of things, being xmlto one of them.
> With this package I didn't have any luck.

As a follow up, I tried to download the source code from the developer's site and compile it myself.
I had the same problems as with my previous email.

Any help?

------------------------------

_______________________________________________
macports-users mailing list
macports-users at lists.macosforge.org
http://lists.macosforge.org/mailman/listinfo.cgi/macports-users


End of macports-users Digest, Vol 45, Issue 24
**********************************************


--
Tony Mannucci
Supervisor, Ionospheric and Atmospheric Remote Sensing Group
 Mail-Stop 138-308,                     Tel > (818) 354-1699
 Jet Propulsion Laboratory,              Fax > (818) 393-5115
 California Institute of Technology,     Email > Tony.Mannucci at jpl.nasa.gov
 4800 Oak Grove Drive,                   http://genesis.jpl.nasa.gov
 Pasadena, CA 91109

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-users/attachments/20100524/b1d9aafd/attachment.html>


More information about the macports-users mailing list