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=unavailable 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!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: Victor Porton Newsgroups: comp.lang.ada Subject: Re: How to find the type of operating system. Date: Sat, 25 Jun 2016 00:12:55 +0300 Organization: Aioe.org NNTP Server Message-ID: References: <57053167$0$4216$e4fe514c@news.kpn.nl> <1be0537a-7ab3-416f-80e6-fc6ee4dfcdc6@googlegroups.com> NNTP-Posting-Host: gIixYTDYPXEsxkLTZ/4cyA.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: abuse@aioe.org User-Agent: KNode/4.14.10 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:30901 Date: 2016-06-25T00:12:55+03:00 List-Id: Lucretia wrote: > On Wednesday, 6 April 2016 16:55:51 UTC+1, ldries46 wrote: >> How can I fin in which operating system a program runs and other details >> of that operating system. > > You know what OS you're compiling on, so define a variable in GPR OS and > set it on compile. During compile, set the source dirs to include an os > specific one and in there put a package which defines the OS: > > package OS is > type OSes is (Linux, Windows, MacOS, iOS, etc.); > > This : OSes := Linux; -- For the linux/os.ads file. > end OS; You've forgotten to add "constant" keyword for "This" object. -- Victor Porton - http://portonvictor.org