comp.lang.ada
 help / color / mirror / Atom feed
From: Stephen Leake <Stephen.Leake@gsfc.nasa.gov>
Subject: Re: Is there a "makedepend" equivalent that works with GNAT?
Date: 1998/12/18
Date: 1998-12-18T00:00:00+00:00	[thread overview]
Message-ID: <uempx8krp.fsf@gsfc.nasa.gov> (raw)
In-Reply-To: 36795A95.1C98@ssd.fsi.com

Michael Bates <mikeb@ssd.fsi.com> writes:

> > Have you tried gnatmake -M <main-unit-name> on an up-to-date library?
> 
> Yes -- I should have mentioned that in my initial message -- and it
> won't 
> work for two reasons: 
> 
> 1.  I need to know the dependencies so that I can make the library 
> -- specifically so that I can check spec and subunit files out of 
> RCS when they are needed to compile a body.

So use gnatmake to build the library once, run gnatmake -M, and save
the results.

> 2.  The main procedure of the program I'm building is not written in 
> Ada.  The Ada I'm compiling is a library of modules to be called from
> legacy software.  gnatmake -M won't work unless you have a main program.

Write a dummy main to force gnatmake to do what you need, then
manually delete it from the final makefile. You could probably
automate this process in your favorite scripting language.
 
> So the question remains: Is there something that does for GNAT what
> makedepend does for C?

It might be possible to modify gnatmake to not require a main; try
reading the sources. It clearly does most of what you need!

-- Stephe




  reply	other threads:[~1998-12-18  0:00 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-12-16  0:00 Is there a "makedepend" equivalent that works with GNAT? Michael Bates
1998-12-16  0:00 ` Simon Wright
1998-12-16  0:00 ` David C. Hoos
1998-12-17  0:00   ` Michael Bates
1998-12-18  0:00     ` Stephen Leake [this message]
1998-12-19  0:00 ` maegaard
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox