Useful Makefile for Ocaml

From: Markus Mottl (mottl@miss.wu-wien.ac.at)
Date: Wed Aug 12 1998 - 12:36:52 MET DST


From: Markus Mottl <mottl@miss.wu-wien.ac.at>
Message-Id: <199808120936.LAA26586@miss.wu-wien.ac.at>
Subject: Useful Makefile for Ocaml
To: caml-list@inria.fr (OCAML)
Date: Wed, 12 Aug 1998 11:36:52 +0100 (MET DST)

Bonjour - Hello!

English version:

To make development of complex Ocaml-projects in a UNIX-environment a bit
easier, I have written a "Makefile" which automates a lot of processes:

  * generation of dependencies
  * code-generation from "ocamllex"- and "ocamlyacc"-files
  * creation of libraries or executables
  * output in byte- or native code

In general, the user only has to put the sources he wants to compile
into a variable, name the result and call "make" with the appropriate
action name.

E.g.:
  put "foo.ml my_scanner.mll my_parser.mly" into variable "SOURCES"
  put "my_executable" into "RESULT"
  call (e.g.): "make lib" to have a native code library...
               "make bc" to have a byte code executable...
               "make bclib" -> byte code library...
               "make" -> native code executable...

All dependencies will be correctly computed, so if you have to remake
your project, only the necessary parts will be rebuilt (which is also
true for the dependencies themselves!)

For further information consult the "README" that comes with the
distribution.

Look at:

   http://miss.wu-wien.ac.at/~mottl/ocaml_sources/intro.html

and grab the file: "ocaml_make.tar.gz" - at the moment the only one ;-)

Don't hesitate to write me if you have questions or suggestions...

Best regards,
Markus Mottl

---------------------------------------------------------------------------

Version francaise(?):

Pour faire le développement des projets complexes en "Ocaml" un peu plus
facile, j'ai ecrit un "Makefile", qui automatise quelques procédés:

  * la génération des dépendances
  * la génération de code des fichiers en "ocamllex" et "ocamlyacc"
  * la compilation des librairies ou des exécutables
  * la sortie peut être en byte- ou native code

En général, il faut seulement placer les sources á compiler dans une
variable, donner un nom au résultat et exécuter "make" avec l'action
approprié.

Par example:

  "foo.ml my_scanner.mll my_parser.mly" sont dans la variable "SOURCES"
  "my_executable" et dans "RESULT"
  Exécutez "make lib" pour avoir un librairie en "native code"
           "make bc" -> byte code exécutable...
           "make bclib" -> librairie en "byte code"
           "make" -> "native code" exécutable...

Tous les dépendances seront correctement calculées, donc si Vous duvez
refaire Vos projets, seulement les composants nécéssaires seront refaits
(c'est aussi vrai pour les dépendances eux-mêmes).

Pour plus d'information consultez le "README" de la distribution.

Regardez:

   http://miss.wu-wien.ac.at/~mottl/ocaml_sources/intro.html

et prennez le fichier: "ocaml_make.tar.gz" - le seule en ce moment ;-)

N'hésitez pas de m'écrire si Vous avez des questions ou des suggestions...

Cordialement,
Markus Mottl

-- 
*  Markus Mottl              |  University of Economics and       *
*  Department of Applied     |  Business Administration           *
*  Computer Science          |  Vienna, Austria                   *
*  mottl@miss.wu-wien.ac.at  |  http://miss.wu-wien.ac.at/~mottl  *



This archive was generated by hypermail 2b29 : Sun Jan 02 2000 - 11:58:15 MET