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 TAA22779; Fri, 16 Apr 2004 19:28:24 +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 TAA21737 for ; Fri, 16 Apr 2004 19:28:23 +0200 (MET DST) Received: from calmail-cl.berkeley.edu (mailfarm.Berkeley.EDU [128.32.61.106]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i3GHTPjq027211 for ; Fri, 16 Apr 2004 19:29:26 +0200 Received: from [64.162.212.212] (HELO tallman.kefka.frap.net) by calmail-cl.berkeley.edu (CommuniGate Pro SMTP 4.1.8) with SMTP id 17573675; Fri, 16 Apr 2004 10:28:21 -0700 Received: by tallman.kefka.frap.net (sSMTP sendmail emulation); Fri, 16 Apr 2004 10:27:26 -0700 Date: Fri, 16 Apr 2004 10:27:26 -0700 From: Kenneth Knowles To: Richard Jones Cc: caml-list@pauillac.inria.fr Subject: [Caml-list] Conditional Compilation (was mod_caml Makefile) Message-ID: <20040416172726.GC27407@tallman.kefka.frap.net> References: <20040415224657.GB4352@swordfish> <20040416081117.GA21063@redhat.com> <20040416164903.GE4352@swordfish> <20040416171206.GF4352@swordfish> <20040416171708.GA29995@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040416171708.GA29995@redhat.com> User-Agent: Mutt/1.5.6i X-Miltered: at nez-perce by Joe's j-chkmail ("http://j-chkmail.ensmp.fr")! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; knowles:99 2004:99 metaocaml:01 compile-time:01 caml:01 makefile:02 config:02 module:03 wrote:03 layout:04 compilation:04 compilation:04 ugly:05 seems:05 untested:06 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk On Fri, Apr 16, 2004 at 06:17:08PM +0100, Richard Jones wrote: > Another reason why having #ifdef's would be useful ... > > Rich. Conditional compilation... I've mulled this over a bit, anyone want to chat about it? I've seen using the C pre-processor, but that seems pretty crufty. My approach has been to conditionally include different source files with just the code that has to change, but that sometimes makes a weird module layout. Also, OCamlConf has an untested ability to generate really short "config.ml", but this is pretty ugly too. Could MetaOCaml help? (I don't know exactly how much compile-time computation it can do; never used it) Any other ideas? Kenn ------------------- 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