Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] CMA depend
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Warp <warplayer@f...>
Subject: [Caml-list] CMA depend
Usually, dependencies are between cmo / cmi, but you can also build a cma by
using :
> ocamlc -a file.ml -o file.cma
What about dependencies between this cma file and others ?
The problems here are that :
- a cma can be obtained from more than one ml
- target dependencies can be either cmo cmi OR other cma's ( when using
dynlink ).

I'm actually running a project where I have lots of modules - all dynlinked
and built with a single ML file. Thus are called 'plugins'.
I could have first compile ml to cmo and then cmo to cma , but that does not
sound very reasonable.
So I patched the ocamldep tool, adding :
+    print_dependencies (basename ^ ".cma") byt_deps;
on line 405.
Now it works fine, but I'm not sure that's the best way to do it.
Any other idea ?

BTW, the "-native" ocamldep flag can have some use, but what about a
"-bytecode" flag ?

Warp



-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr