caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* System interface
@ 1994-09-27 13:29 John Harrison
  1994-09-28 17:02 ` Xavier Leroy
  0 siblings, 1 reply; 2+ messages in thread
From: John Harrison @ 1994-09-27 13:29 UTC (permalink / raw)
  To: caml-list; +Cc: John.Harrison


Is there a straightforward way (under Unix) of executing
arbitrary system commands from inside CAML Light? 

For example:

  system "ls -al | sort +3 >/tmp/.listing"

John.




^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: System interface
  1994-09-27 13:29 System interface John Harrison
@ 1994-09-28 17:02 ` Xavier Leroy
  0 siblings, 0 replies; 2+ messages in thread
From: Xavier Leroy @ 1994-09-28 17:02 UTC (permalink / raw)
  To: caml-list

> Is there a straightforward way (under Unix) of executing
> arbitrary system commands from inside CAML Light? 

The unix__system function does just that. The "unix" library is in
contrib/libunix in the distribution. Once installed, it can be linked
with a standalone application as follows:

        camlc -custom -o <applname> unix.zo <appl .zo files> -lunix

For interactive use of the functions provided by this library, first
build a "custom toplevel":

        camlmktop -custom -o camlunix unix.zo -lunix

then launch it with:

        camllight camlunix

- Xavier Leroy





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1994-09-28 18:13 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1994-09-27 13:29 System interface John Harrison
1994-09-28 17:02 ` Xavier Leroy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).