From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,bdf7f4217c51ec2f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-08-28 12:31:07 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!kibo.news.demon.net!news.demon.co.uk!demon!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: Gnat's "Missing Subunits" Date: 28 Aug 2003 20:29:31 +0100 Organization: Pushface Sender: simon@smaug.pushface.org Message-ID: References: <1b585154.0308281025.28fd1e8a@posting.google.com> NNTP-Posting-Host: pogner.demon.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: news.demon.co.uk 1062099066 28895 62.49.19.209 (28 Aug 2003 19:31:06 GMT) X-Complaints-To: abuse@demon.net NNTP-Posting-Date: Thu, 28 Aug 2003 19:31:06 +0000 (UTC) User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1 Xref: archiver1.google.com comp.lang.ada:41925 Date: 2003-08-28T20:29:31+01:00 List-Id: prichtmyer@yahoo.com (Peter Richtmyer) writes: > I am trying to compile a very old, large VAX Ada system using Gnat > 3.15p > (Win2000) on a PC, hoping to modify the old system enough to do a > little debugging on the PC. > > Sometimes when compiling a large Generic Package body, I get no errors > except "missing subunits". I have found no easy way to identify > the problem(s). It seems like the problem is sometimes actually in > a "with'd" package a couple levels deeper. I don't know why you don't get the file name of the missing subunit. When I compile this (which was gnatchopped from a file lg.ada) generic package Lg is procedure Foo; end Lg; package body Lg is procedure Foo is separate; end Lg; I get (Linux 3.15p): tiamat[3]$ GNAT_PREFIX=/opt/3.15p gnatmake lg.adb gcc -c lg.adb No code generated for file lg.adb (missing subunits) lg.ada:6:04: warning: subunit "Lg.Foo" in file "lg-foo.adb" not found gnatmake: "lg.adb" compilation error You might also get some help from -gnatl: tiamat[6]$ GNAT_PREFIX=/opt/3.15p gnatmake lg.adb -gnatl gcc -c -gnatl lg.adb GNAT 3.15p (20020523) Copyright 1992-2002 Free Software Foundation, Inc. Compiling: lg.adb (source file time stamp: 2003-08-28 19:19:03) No code generated for file lg.adb (missing subunits) ==============Error messages for source file: lg.adb --------------Line numbers from file: /home/simon/tmp/lg.ada (starting at line 5) pragma Source_Reference (000005, "/home/simon/tmp/lg.ada"); 5. package body Lg is 6. procedure Foo is separate; | >>> warning: subunit "Lg.Foo" in file "lg-foo.adb" not found 7. end Lg; 4 lines: No errors, 1 warning gnatmake: "lg.adb" compilation error