Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Building large and portable projects
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: skaller <skaller@o...>
Subject: Re: [Caml-list] Building large and portable projects
On Sat, 2003-11-22 at 06:04, sylvain.le-gall@polytechnique.org wrote:

> I don't want to reproduce make bugs... I just want to do something
> simple where you can type :
> 
> let my_prog = {
> 	name : "my_prog";
> 	compile_target : [Opt;Byte];
> 	toplevel_files : [ "my_prog.ml" ;
> 	"something_ocamldep_dont_recognize_as_toplevel.ml" ];
> 	package : "all_my_life" ;
> 	target_tag : Binary; ( or Documentation or Custom of string )
> 	}
> 
> let _ =
> 	add_target my_prog
> 
> Ie, it is not makefile syntax.

My guess is that the 'object oriented design
paradigm' has something to say here -- 
do it bottom up. The first step is to define
things like

	compare_time_stamp(f1, f2)

a module for 'dependency graph', and
other tools that may be useful.

Then just write plain Ocaml code using these tools.

This may be a bit long winded, so check out camlp4
to sweeten it up.

The advantage of this approach is that a make script
is an arbitrary caml script.

Which means: it can do anything easily (since caml
is so expressive), it is also type checked (hey,
why shouldn't build scripts be type checked?)

etc etc etc ...

Finally after all that if you still think a language
translator is needed to express the build conditions
above and beyond caml with camlp4 ... then one
can be written, plugged into the front, invoked
by the caml build script, compiled and executed ..
all without requiring ME or anyone else
to use your language (you can just embed the
translator in your package).

This is basically what interscript does only
its hooks Python and it's aimed at packaging
software components (meaning source codes and
documentation) in a more general fashion
than merely building them would require.
It actually has a language translator,
but it's a pretty brain dead one that basically
allows code, doco, and executable script to be
mixed together in a single source file.


-------------------
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