This repository contains some very simple examples showing how to use dune and opam for building and packaging systems.
-
the directory
simple-exe
shows how to usedune
to compile and run a simple program (making use of theUnix
external library) -
the directory
simple-lib-and-exe
shows how to usedune
to compile and run a simple program, making use of a local library -
the directory
simple-exe-with-inline-test
shows how to usedune
to build a simple program and use the inline, ppx-based, test mechanism to test it -
the directory
simple-lib-and-exe-with-debug
shows how to debug a program (using a library) usingocamldebug
-
the directory
package-with-lib
shows how to build, test, install and use a simple package consisting in a single library -
the directory
package-with-lib-and-exe
shows how to build, test, install and use a simple package consisting in a single library and an executable -
the directory
package-with-lib-and-sublib
shows how to build, test, install and use a simple package consisting in two libraries: a main library and an auxiliary library
For the package-xxx
examples, each directory consists in two sub-directories:
-
a directory named
build
, for building, testing and installing the package (including the documentation in.html
format), -
a directory named
use
, for building and running a small program using the package.
git clone https://github.com/jserot/dune-howto
cd dune-howto
See the Readme
file inside each example directory