From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by sympa.inria.fr (Postfix) with ESMTPS id 44F4881792 for ; Wed, 26 Jun 2013 20:46:15 +0200 (CEST) Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of wojciech.meyer@gmail.com) identity=pra; client-ip=74.125.82.45; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="wojciech.meyer@gmail.com"; x-sender="wojciech.meyer@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail2-smtp-roc.national.inria.fr: domain of wojciech.meyer@gmail.com designates 74.125.82.45 as permitted sender) identity=mailfrom; client-ip=74.125.82.45; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="wojciech.meyer@gmail.com"; x-sender="wojciech.meyer@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail2-smtp-roc.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-wg0-f45.google.com) identity=helo; client-ip=74.125.82.45; receiver=mail2-smtp-roc.national.inria.fr; envelope-from="wojciech.meyer@gmail.com"; x-sender="postmaster@mail-wg0-f45.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AqYBAAs2y1FKfVItk2dsb2JhbABbwwCBAxYOAQEBAQcLCwkUBCSCIwEBBAFAARsdAQMBCwYFCw0JJQ8BBA8RAQUBDgETE4d7AQMJBgScO4xNgn+EUQoZJw1Yh3QBBQyOF4EoB4NjA5dFj2A/hDiBZyQ X-IPAS-Result: AqYBAAs2y1FKfVItk2dsb2JhbABbwwCBAxYOAQEBAQcLCwkUBCSCIwEBBAFAARsdAQMBCwYFCw0JJQ8BBA8RAQUBDgETE4d7AQMJBgScO4xNgn+EUQoZJw1Yh3QBBQyOF4EoB4NjA5dFj2A/hDiBZyQ X-IronPort-AV: E=Sophos;i="4.87,946,1363129200"; d="scan'208";a="23520804" Received: from mail-wg0-f45.google.com ([74.125.82.45]) by mail2-smtp-roc.national.inria.fr with ESMTP/TLS/RC4-SHA; 26 Jun 2013 20:46:14 +0200 Received: by mail-wg0-f45.google.com with SMTP id j13so10622359wgh.0 for ; Wed, 26 Jun 2013 11:46:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=zHdtNjKdUp7bFI+RQSh0auGUqUiqXgoGkK9gFl+E8bg=; b=RpQeru223sFiiav83ReJw4CTuBJOClDZa5nozcvNz/Kxr7QFIu+s/ueHviUt5xQaTd z8DnPP8yluvdP3YLWC1l97e93La0kqEtQ3M2+5TfMiKd53fXKMsBdLITg0fGbBllV+Gm P9pKSYzXnZpLRsvGS4/DC7zP+Eny0jIVc15P1SrBi6npv2CZVa2GNqd8sgRbfAkpcWzl jlP1SWqq30yidE57i75BSNVrcPjY5T0hCb570U5HoTHQ2p1rwuC5hUTgfj+bpyHlChDu 4us+uuCbpV1/V8AsaVol4CZPpZELYh1CTHYkPwVDuzcBiahsTeDLYAfDQY0u33Px7pOY N7BQ== X-Received: by 10.194.133.106 with SMTP id pb10mr3706979wjb.62.1372272374298; Wed, 26 Jun 2013 11:46:14 -0700 (PDT) Received: from spec-desktop.danmey.org (cpc2-cmbg12-0-0-cust796.5-4.cable.virginmedia.com. [86.9.203.29]) by mx.google.com with ESMTPSA id h8sm2952065wie.1.2013.06.26.11.46.12 for (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Wed, 26 Jun 2013 11:46:13 -0700 (PDT) From: Wojciech Meyer To: Adrien Nader Cc: Gerd Stolpmann , Bikal Gurung , caml-list@inria.fr References: <20130624172105.GB32244@notk.org> <1372104978.3769.2@samsung> <20130626182947.GC31557@notk.org> Date: Wed, 26 Jun 2013 19:46:17 +0100 In-Reply-To: <20130626182947.GC31557@notk.org> (Adrien Nader's message of "Wed, 26 Jun 2013 20:29:47 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Caml-list] Ocaml on windows Hi Adrien, I'd raise a general mantis ticket "OCamlBuild has to work on Windows" for ocamlbuild, to cover this work, we might do at some point. (although don't hold your breath at the moment, this is a substantial development). Wojciech Adrien Nader writes: > On Mon, Jun 24, 2013, Gerd Stolpmann wrote: >> Am 24.06.2013 19:21:05 schrieb(en) Adrien Nader: >> >On Mon, Jun 24, 2013, Bikal Gurung wrote: >> >> Hi, >> >> >> >> I am looking to use ocaml to implement a project for my >> >employer. However, the >> >> environment is Windows OS. I am using cygwin and so far it seems >> >to work but >> >> curious on experiences others have on using ocaml on windows - >> >both as a >> >> development and deployment platform. Also has anyone tried using >> >opam on >> >> windows? Does it work? >> >> >> > >> >I believe opam on windows is pretty far away. >> > >> >The issues can be summarized in a few words: source-based package >> >manager for ocaml on pure windows. >> >For this to fully work, you need a perfect toolchain where everything >> >works wonderfully. >> >> I can quickly report what I did to get GODI working on Windows. It >> is of course not "pure Windows": You need Cygwin for doing builds, >> but that's "only" because almost all build utilities are Unix-ish, >> and it would be very hard to build anything without having some >> shell and the usual file utilities at hand. (AFAIK the only build >> utility that works in a pure Windows environment is omake.) >> >> So GODI assumes a mixed Windows environment, and this is in deed >> doable. ocaml and all compiled code run on native Windows here, and >> for executing build scripts there is Cygwin. This solves the utility >> question, but you get in return some new problems, like the >> different calling conventions. All GODI core utilities have e.g. >> built-in support for translating Cygwin paths forth and back, so >> they can operate on Cygwin paths although they are native Windows >> programs. Another problem are the strange Windows rules for >> splitting a command-line into words. As generic fallback when there >> are too many "bad characters" in the command line I simply generate >> a temporary script that is then executed with bash. There are >> probably more such tricks I currently do not remember. >> >> So this mixed mode is actually doable, and works so well that many >> GODI packages can be built on Windows without any special porting >> effort. If you look at WODI, the special adaption of GODI for >> Windows, you will mostly find additional C libraries (because you >> cannot link against the libraries coming with Cygwin). >> >> We could go further and replace Cygwin completely only if we had a >> substitute for the shell utilities. That's the core of the problem, >> and it's a hard one, because many scripts assume 100% POSIX >> behavior, and e.g. using Windows command-line conventions is out of >> question. > > Yup, agreed, mixed is doable as WODI has proven. > The most annoying constraint is probably that it slows down builds a lot > and it makes frequent updates very painful (that makes source-based > package managers far less attractive on windows [ note that on linux, I > use and enjoy godi ]). > > That said, I've used ocaml on pure windows (besides bash for > ocamlbuild). I was running everything from cmd.exe and it worked well. > I had also built libraries which rely on oasis and it had gone well too. > I believe that with a sufficiently full-featured build system, pure > windows is doable and that's something which is probably fairly close. > > -- > Adrien Nader -- Wojciech