From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 826ABBC69 for ; Mon, 5 Mar 2007 22:47:23 +0100 (CET) Received: from out5.smtp.messagingengine.com (out5.smtp.messagingengine.com [66.111.4.29]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l25LlMWu031927 for ; Mon, 5 Mar 2007 22:47:23 +0100 Received: from out1.internal (unknown [10.202.2.149]) by out1.messagingengine.com (Postfix) with ESMTP id AE9A71F58B7; Mon, 5 Mar 2007 16:47:20 -0500 (EST) Received: from heartbeat2.messagingengine.com ([10.202.2.161]) by out1.internal (MEProxy); Mon, 05 Mar 2007 16:47:20 -0500 X-Sasl-enc: nKv5GiVLajXSRctbE0jyccGwKyubmK7f+KOMV/UgVXCg 1173131240 Received: from [172.16.112.115] (burnham.ljcrf.edu [192.231.106.2]) by mail.messagingengine.com (Postfix) with ESMTP id 8727E1B759; Mon, 5 Mar 2007 16:47:20 -0500 (EST) Date: Mon, 5 Mar 2007 13:46:11 -0800 (PST) From: Martin Jambon X-X-Sender: martin@localhost To: caml-list@inria.fr Cc: David MENTRE Subject: ocamlscript 2.0.0 Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Miltered: at discorde with ID 45EC8FEA.002 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; ens-lyon:01 findlib:01 camlp:01 syntax:01 ocamllex:01 stdin:01 command-line:01 compilation:01 ocaml:01 recompiled:01 compilation:01 ocaml:01 netclient:01 findlib:01 usr:01 ocamlscript version 2.0.0 was just released. It is considered stable, and there is no big change since the previous release 1.99.5 except for the packaging and the web page: http://martin.jambon.free.fr/ocamlscript.html Ocamlscript 2 derives from David Mentre's original implementation and adds support for findlib packages, camlp4 syntax extensions, ocamllex, ocamllyacc, input from stdin, script on the command-line, and some support for compilation and linking with other source files. In theory it can also be configured to support any compiled programming language other than OCaml. Description: =========== ocamlscript compiles scripts, i.e. one-file programs, into natively-compiled binaries, and executes them. Basically, a script named alpha is compiled into alpha.exe. If alpha.exe is more recent than alpha, then alpha.exe is executed directly, otherwise alpha is recompiled first. Compilation commands reside in the first section of the script. They are written in OCaml and consist normally in setting one or two variables. Example: ======== The following "getpage" script fetches a web page using the HTTP client provided by the netclient library/findlib package: #! /usr/bin/env ocamlscript Ocaml.packs := [ "netclient" ] -- match Sys.argv with [| _; url |] -> print_string (Http_client.Convenience.http_get url) | _ -> prerr_string "Usage: getpage URL\n"; exit 1 For instance, executing "getpage http://caml.inria.fr" creates a getpage.exe file in the same directory as "getpage", runs it and prints the web page that was requested. Martin -- Martin Jambon http://martin.jambon.free.fr