[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MirageOS-devel] Project setup with dune


  • To: Andrew J <andrewj25836@xxxxxxxxx>
  • From: Christophe Troestler <Christophe.Troestler@xxxxxxxxxxx>
  • Date: Mon, 29 Oct 2018 12:59:27 +0100
  • Authentication-results: spf=pass (sender IP is 193.190.208.132) smtp.mailfrom=umons.ac.be; gmail.com; dkim=none (message not signed) header.d=none;gmail.com; dmarc=bestguesspass action=none header.from=umons.ac.be;
  • Cc: mirageos-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Mon, 29 Oct 2018 11:59:47 +0000
  • List-id: Developer list for MirageOS <mirageos-devel.lists.xenproject.org>
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:99

Hi,

On 29 October 2018 at 10:16 GMT, Andrew J wrote:
>
> I'm starting a project with mirage to build a protocol server. I'm wondering 
> if there is any way to use dune to handle the configuring and building since 
> it can do tests and other things too.
>
> I guess this would be something similar to running the mirage configure then 
> make commands but don't know if something like this exists for dune.

If you want to have a configure step in Dune, you usually write an executable 
using dune.configurator https://dune.readthedocs.io/en/latest/configurator.html 
which will be called by a rule to generate some targets which are then used in 
your build (e.g. using the variable read-lines 
https://dune.readthedocs.io/en/latest/dune-files.html#variables-expansion or 
(:include ...)).

See for example how config/discover.ml is used to detect the fortran compiler 
for odepack — https://github.com/Chris00/ocaml-odepack

Best,
C.

_______________________________________________
MirageOS-devel mailing list
MirageOS-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/mirageos-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.