English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
RE: [Caml-list] beta-test of OCaml 3.10.0: compiling on Windows,trying the new Camlp4
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2007-03-23 (17:44)
Subject: RE: [Caml-list] beta-test of OCaml 3.10.0: compiling on Windows,trying the new Camlp4
Just a comment concerning the microsoft build.

There is a batch called vcvars32.bat which handles setting correctly the VC2005 environment.

Calling it (in cygwin.bat) should handle all your problems for compilation.


For the rest of your questions, I can't be of any assistance.






De : caml-list-bounces@yquem.inria.fr [mailto:caml-list-bounces@yquem.inria.fr] De la part de Matthieu Wipliez
Envoyé : vendredi 23 mars 2007 18:28
À : Caml List
Objet : [Caml-list] beta-test of OCaml 3.10.0: compiling on Windows,trying the new Camlp4



I compiled OCaml 3.10.0 on Windows XP SP2 using Cygwin and Microsoft Visual Studio 2005.
Surprisingly, this did not go as smoothly as I thought. Hence I would like to share my experience:

1) the directory where the MSVC compiler, linker, and other tools are installed must be in the path : C:\Program Files\Microsoft Visual Studio 8\VC\bin
2) some tools (at least the compiler and linker) apparently need a DLL (mspdb80.dll), so one has to add "C:\Program Files\Microsoft Visual Studio 8\Common7\IDE" to the path
3) under Cygwin, I had a clash between the linker (link) and the link command (link (GNU coreutils) 5.97). For everything to work, I had to remove the link command from Cygwin (renamed the link.exe file).
4) the compiler needs the INCLUDE variable to be defined with the MSVC include path (as well as Tcl's, but this is specified in the doc)
C:\Program Files\Microsoft Visual Studio 8\VC\include;C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\Include;C:\Tcl\include
5) for the linker, the variable is called LIB, and must contain:
C:\Program Files\Microsoft Visual Studio 8\VC\lib;C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\Lib;C:\Tcl\lib

I would suggest to update the documentation (README.win32 file) by adding precisions concerning the INCLUDE, LIB and PATH variables, as well as the "link" command problem.

In addition, it seems that compilation can fail if OCAMLLIB is defined (complains about a .cmi in $OCAMLLIB not being up to date).

After compilation/installation, I tested this new version, compiling with "ocamlc.opt -pp camlp4o.opt". Is it still the right way to preprocess with Camlp4 ? Anyway, here's what I obtain:
  - in a class, "method private virtual" is not accepted anymore, the order has to be "method virtual private".
  - assert MySet.is_empty set; is not accepted anymore either, I have to add brackets: assert (MySet.is_empty set);
  - compiling a file containing this kind of comment (* <<<< COMMENT *) fails with "Quotation not terminated".
  - in a .mli, declaring an empty module ABC, with "module type ABC" does not work (but does without preprocessing).

I used the version from http://caml.inria.fr/pub/distrib/ocaml-3.10/ocaml-3.10.0+beta.tar.gz, so maybe some things have been corrected since.




Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Profitez des connaissances, des opinions et des expériences des internautes sur Yahoo! Questions/Réponses <http://fr.rd.yahoo.com/evt=42054/*http:/fr.answers.yahoo.com> .

Ce message et toutes les pieces jointes (ci-apres le "message") sont confidentiels et etablis a l'intention exclusive de ses destinataires. 
Toute utilisation ou diffusion non autorisee est interdite. 
Tout message electronique est susceptible d'alteration. 
Societe Generale Asset Management et ses filiales declinent toute responsabilite au titre de ce message s'il a ete altere, deforme ou falsifie. 
Decouvrez l'offre et les services de Societe Generale Asset Management sur le site www.sgam.fr 
This message and any attachments (the "message") are confidential and intended solely for the addressees. 
Any unauthorised use or dissemination is prohibited. 
E-mails are susceptible to alteration. 
Neither Societe Generale Asset Management nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified. 
Find out more about Societe Generale Asset Management's proposal on www.sgam.com