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=-2.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Thread: 103376,c35edbbda4c7f58f X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!news1.google.com!proxad.net!freenix!enst.fr!melchior!cuivre.fr.eu.org!melchior.frmug.org!not-for-mail From: =?iso-8859-1?q?Bj=F6rn_Lundin?= Newsgroups: comp.lang.ada Subject: Re: Conditional compilation in Ada? Date: Tue, 16 Nov 2004 20:41:47 +0100 Organization: Cuivre, Argent, Or Message-ID: References: <1100632383.66582@master.nyc.kbcfp.com> NNTP-Posting-Host: lovelace.ada-france.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: melchior.cuivre.fr.eu.org 1100634140 17102 212.85.156.195 (16 Nov 2004 19:42:20 GMT) X-Complaints-To: usenet@melchior.cuivre.fr.eu.org NNTP-Posting-Date: Tue, 16 Nov 2004 19:42:20 +0000 (UTC) To: comp.lang.ada@ada-france.org Return-Path: User-Agent: KMail/1.7 In-Reply-To: <1100632383.66582@master.nyc.kbcfp.com> Content-Disposition: inline X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at ada-france.org X-BeenThere: comp.lang.ada@ada-france.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Gateway to the comp.lang.ada Usenet newsgroup" List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Xref: g2news1.google.com comp.lang.ada:6229 Date: 2004-11-16T20:41:47+01:00 tisdag 16 november 2004 20:13 skrev Hyman Rosen: > The OP is running two separate programs. There should be a > better solution than forcing him to make runtime tests for > something which is static. > > A description of the data structure and its varieties is > needed before we can offer really sage advice. It all depends on _what_ differs. I work with a system running on Aix and=20 Windows. We have internal process communication, which is done with shared= =20 memory + semphores on Aix and with memory mapped files on windows. Doesn't help with smart data structrues when you do a pragma Import. What we usually do when we can't solve the platform differences, is to writ= e=20 that in (yack) C, and export the same function names and arguments, and have one c-file per platform. This could be solved in one file with #ifdefs but we prefer a c-file or more _per_ platform We then have the same Ada files, which imports the functions from respectiv= e=20 platform's c-file /Bj=F6rn > _______________________________________________ > comp.lang.ada mailing list > comp.lang.ada@ada-france.org > http://www.ada-france.org/mailman/listinfo/comp.lang.ada