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=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: =?UTF-8?B?QmrDtnJuIEx1bmRpbg==?= Newsgroups: comp.lang.ada Subject: Re: GNAT GPL is not shareware Date: Wed, 07 Jan 2015 18:39:26 +0100 Organization: A noiseless patient Spider Message-ID: References: <87bnmetex4.fsf@ludovic-brenta.org> <4ae7f0d5-d681-4be9-95bc-b5e789b3ad40@googlegroups.com> <87tx06rve6.fsf@ludovic-brenta.org> <87lhlirpk0.fsf@ludovic-brenta.org> <79f3eff7-2b45-40ae-af94-fa9a17426d82@googlegroups.com> <87bnmd8mg2.fsf@ixod.org> <19cf9bc2-f8b9-4735-b427-7b070dda59da@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Wed, 7 Jan 2015 17:39:13 +0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="edcd57aa7b7d0a640de5f364a7af93e6"; logging-data="18571"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19wJIKLbNZVKV37Hy+TEWMN" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.2.0 In-Reply-To: Cancel-Lock: sha1:r6xOeoq/w7fjHnYFbGz2JaWqeGI= Xref: news.eternal-september.org comp.lang.ada:24454 Date: 2015-01-07T18:39:26+01:00 List-Id: On 2015-01-07 18:33, Björn Lundin wrote: > On 2015-01-07 17:32, Shark8 wrote: >>> >>> and exactly _how_ is this more preventable with a db solution? >> >> Because with a DB-system you can guarantee that the "system" is not >> inconsistent or out-of date; and you can associate generated objects >> with exactly the state that generates them. >> > > see also gnatbind > > > > " > The gnatbind program performs four separate functions: > > Checks that a program is consistent, in accordance with the rules in > Chapter 10 of the Ada Reference Manual. In particular, error messages > are generated if a program uses inconsistent versions of a given unit. > > " reading further, we get to the section 4.1 that states The effect of this consistency checking, which includes source files, is that the binder ensures that the program is consistent with the latest version of the source files that can be located at bind time. Editing a source file without compiling files that depend on the source file cause error messages to be generated by the binder. For example, suppose you have a main program `hello.adb' and a package P, from file `p.ads' and you perform the following steps: Enter gcc -c hello.adb to compile the main program. Enter gcc -c p.ads to compile package P. Edit file `p.ads'. Enter gnatbind hello. At this point, the file `p.ali' contains an out-of-date time stamp because the file `p.ads' has been edited. The attempt at binding fails, and the binder generates the following error messages: error: "hello.adb" must be recompiled ("p.ads" has been modified) error: "p.ads" has been modified and must be recompiled Now both files must be recompiled as indicated, and then the bind can succeed, generating a main program. As I said, never heard of linking the wrong object file with gnat -- Björn