From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id JAA02837; Wed, 8 Oct 2003 09:58:27 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id JAA29258 for ; Wed, 8 Oct 2003 09:58:26 +0200 (MET DST) Received: from bourg.inria.fr (bourg.inria.fr [128.93.11.100]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id h987wP111768; Wed, 8 Oct 2003 09:58:25 +0200 (MET DST) Received: from starynke by bourg.inria.fr with local (Exim 4.22) id 1A79DF-0004OD-D9; Wed, 08 Oct 2003 09:58:25 +0200 Date: Wed, 8 Oct 2003 09:58:25 +0200 To: Benjamin Geer , caml-list@inria.fr Subject: Re: [Caml-list] syslog interface? Message-ID: <20031008075825.GA16836@bourg.inria.fr> References: <3F837FF9.9030306@socialtools.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3F837FF9.9030306@socialtools.net> User-Agent: Mutt/1.5.4i From: Basile Starynkevitch X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 syslog:01 basile:01 basile:01 syslog:01 poesia:01 poesia:01 opensource:01 gpl:01 util:01 util:01 mli:01 sourceforge:01 poesiasoft:01 camlp:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Wed, Oct 08, 2003 at 04:09:45AM +0100, Benjamin Geer wrote: > Does anyone know of an ocaml interface to the Unix syslog daemon ? In my previous job, I coded such an interface. It is in the POESIA monitor (Poesia is a content filter - see www.poesia-filter.org for details, and its monitor is coded in Ocaml) which is opensource, under GPL license. The relevant files are util.ml, util.mli, util_ml.c available under http://cvs.sourceforge.net/viewcvs.py/poesia/PoesiaSoft/PoesiaMonIcap/ (to compile the whole util.ml file, you also need the pa_trace.ml camlp4 preprocessor; but if you look for syslog only, you can copy&paste the relevant functions and use util_ml.c). The code was coded for ocaml 3.06; in practical terms, you'll better write ignore (esyslogprintf ...). Using the format4 type of ocaml 3.06 for kprintf would make it easier in ocaml 3.07. However the code does compile and run correctly under 3.07 Regards -- Basile STARYNKEVITCH -- basile dot starynkevitch at inria dot fr Project cristal.inria.fr - phone +33 1 3963 5197 - mobile 6 8501 2359 http://cristal.inria.fr/~starynke --- all opinions are only mine ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners