Version française
Home     About     Download     Resources     Contact us    
Browse thread
nonresolved .cma files and errors
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Nicolas Pouillard <nicolas.pouillard@g...>
Subject: Re: [Caml-list] nonresolved .cma files and errors
On 4/11/07, Jeff Henrikson <jehenrik@yahoo.com> wrote:
> Hello caml-list,
>
> I recently had a shocking realization about why some of my experiments
> with camlp4 weren't compiling.  I had been linking camlp4.cma, which was
> the old name of the library.  Now camlp4.cma doesn't exist and there are
> multiple flavors Camlp4xxx.cma where the xxx is the same flavor notation
> of the the preprocessor binaries.  So the trouble is, why was linking
> such a library not a fatal?  Apparently all missing .cma and .cmo files
> passed on the command line are considered non-errors.  It seems intutive
> to me that both should be fatals!
>
> ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.cma
> camlp4orf.cma -c dynamic_functor_example3.ml
> ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.cmo
> camlp4orf.cma -c dynamic_functor_example3.ml
> ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.ml
> camlp4orf.cma -c dynamic_functor_example3.ml
> I/O error: "junk.ml: No such file or directory"
> Preprocessor error
>

Good answers are already here, I just takes the lasts bits...

There is a list of libraries provided with camlp4:

camlp4{o,of,orf,r,rf}.cma are toplevel libs there are only made to be
loaded in the ocaml toplevel

camlp4lib.cma contains the Camlp4 module which holds the camlp4 kernel.

camlp4fullilb.cma contains modules of camlp4lib.cma plus all parsers
and filters.

-- 
Nicolas Pouillard