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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,bab3a898ff9c3e0 X-Google-Attributes: gid103376,public From: Stephen Leake Subject: Re: Is there a "makedepend" equivalent that works with GNAT? Date: 1998/12/18 Message-ID: #1/1 X-Deja-AN: 423656787 References: <3677F5DF.4D8F@ssd.fsi.com> <759gj9$rma@hobbes.crc.com> <36795A95.1C98@ssd.fsi.com> Organization: NASA Goddard Space Flight Center -- Greenbelt, Maryland USA Newsgroups: comp.lang.ada Date: 1998-12-18T00:00:00+00:00 List-Id: Michael Bates writes: > > Have you tried gnatmake -M 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