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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,80155a886d197693 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII Path: g2news2.google.com!postnews.google.com!37g2000yqp.googlegroups.com!not-for-mail From: sjw Newsgroups: comp.lang.ada Subject: Re: Conditional Compilation in Ada Date: Tue, 30 Jun 2009 13:15:22 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <5618a901-6b05-4a60-8362-7821261da50b@f19g2000yqo.googlegroups.com> NNTP-Posting-Host: 82.20.239.89 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1246392922 10968 127.0.0.1 (30 Jun 2009 20:15:22 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 30 Jun 2009 20:15:22 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: 37g2000yqp.googlegroups.com; posting-host=82.20.239.89; posting-account=_RXWmAoAAADQS3ojtLFDmTNJCT0N2R4U User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_5_7; en-us) AppleWebKit/530.18 (KHTML, like Gecko) Version/4.0.1 Safari/530.18,gzip(gfe),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:6770 Date: 2009-06-30T13:15:22-07:00 List-Id: On Jun 30, 4:39=A0pm, Per Sandberg wrote: > After all discussions her are a solution for conditinal compilation > using GNAT: > /Ugly but it works One thing I noticed is that GNAT doesn't see a change to the environment variables as triggering a recompilation (well, there may be more flags): $ gnatmake -Pfools fools-main gcc -c -gnateDDUMB=3D"Fool" -I- -gnatA /Users/simon/tmp/target/fools- main.adb gcc -c -gnateDDUMB=3D"Fool" -I- -gnatA /Users/simon/tmp/target/fools.ads gnatbind -I- -x /Users/simon/tmp/target/fools-main.ali gnatlink /Users/simon/tmp/target/fools-main.ali -o /Users/simon/tmp/ target/fools-main $ $ gnatmake -Pfools -XDUMB=3D"\"Idiot\"" fools-main gnatmake: "/Users/simon/tmp/target/fools-main" up to date.