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-Thread: 103376,3e5cb326bf672965 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!news3.google.com!news.glorb.com!peer1.news.newnet.co.uk!194.159.246.34.MISMATCH!peer-uk.news.demon.net!kibo.news.demon.net!news.demon.co.uk!demon!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: GNAT, shared libraries, building in different directories...madness! Date: Sun, 15 Oct 2006 12:00:43 +0100 Organization: Pushface Message-ID: References: <1159469642.836410.101620@i42g2000cwa.googlegroups.com> <87lko19qjw.fsf@ludovic-brenta.org> <1160853194.025616.271150@b28g2000cwb.googlegroups.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 1160910045 3758 62.49.19.209 (15 Oct 2006 11:00:45 GMT) X-Complaints-To: abuse@demon.net NNTP-Posting-Date: Sun, 15 Oct 2006 11:00:45 +0000 (UTC) Cancel-Lock: sha1:ri/pngpWCHUYQWK625gAO3vws60= User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (darwin) Xref: g2news2.google.com comp.lang.ada:6980 Date: 2006-10-15T12:00:43+01:00 List-Id: "Lucretia" writes: > And there is a major problem with this source directory > directive. The generic directory should contain all source for a gui > toolkit neutral UI, in a way that wxWidgets does currently. We build several executables, each with its own set of supporting application-, intermediate- and device-level packages plus a fair bunch of common stuff. We have a main GPR for each executable (which can be extended by anyone who needs to build test programs), which calls up a machine-generated GPR (one for the whole project) which has no associated source code but instead defines lots of names for various sets of paths. These names are what are used by the main GPRs. Each executable can be built in various contexts; variant A or B, runs on the host or on the target, etc. This is managed using case statements in the machine-generated GPR. Host_Network_Path = ("a/b/c", "a/b/d"); Target_Network_Path = ("w/x/y", "w/x/z"); case Platform is when "host" => Network_Path = Host_Network_Path; when "target" => Network_Path = Target_Network_Path; end case; and the main GPR says for Source_Dirs use Network_Path & ....