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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,15e9725ee4ac8322 X-Google-Attributes: gid103376,public From: Andi Kleen Subject: Re: [Q] Operating System Command Interface Date: 1998/05/05 Message-ID: #1/1 X-Deja-AN: 350484802 Distribution: world Sender: andi@fred.muc.de References: <6ims5j$1vo@gcsin3.geccs.gecm.com> <354F2EF4.41C6@hso.link.com> Organization: [posted via] Leibniz-Rechenzentrum, Muenchen (Germany) Newsgroups: comp.lang.ada Date: 1998-05-05T00:00:00+00:00 List-Id: "Stanley R. Allen" writes: > John McCabe wrote: > > > > Am I right in thinking that, as standard, Ada has no direct perating > > system command interface akin to the C "System" call? > > > > My understanding is that the "system" call you are making > in C is actually a call to the Unix operating system; it's > not part of the C language. The same kind of call can be made > from Ada using pragma Interface (Ada 83) or pragma Import > (Ada 95). system() is part of the c library and not a system call on Unix. It is implemented with fork() and exec(). It is part of the libc on Unix systems and indeed part of the ISO Standard C library definition - so if you assume that the Ada C interface interfaces you to a full(1) ISO C it should be there. Of course that doesn't mean that it is portable. What is done with the string is implementation specified - just returning an error is legal. -Andi (1) Full - not subsetted. ISO C allows C without library for embedded implementations.