From 778db61bf16b1b0b41cb8909b6dc8641fa40608f Mon Sep 17 00:00:00 2001 From: Julien Girard <julien.girard2@cea.fr> Date: Fri, 23 Sep 2022 15:10:54 +0200 Subject: [PATCH] [doc] Updated installation instructions. --- doc/installation.rst | 61 ++++++++++++++++++++++++++++++++++---------- 1 file changed, 47 insertions(+), 14 deletions(-) diff --git a/doc/installation.rst b/doc/installation.rst index e914f07..be23b34 100644 --- a/doc/installation.rst +++ b/doc/installation.rst @@ -3,25 +3,58 @@ Installation ============ -For now, no binaries are provided. Installation must be made -directly by compiling the source. -It requires Ocaml package manager Opam, v2.1 or higher. +The latest release of CAISAR is available as an +`opam <https://opam.ocaml.org/>`_ package or +a `Docker <https://www.docker.com/>`_ image. +The development version of CAISAR is available only by compiling the source code. -For development, it is recommended you set-up your own -Opam switch (an OCaml installation isolated from system -libraries):: +Install through Opam +-------------------- - git clone https://git.frama-c.com/pub/laiser/caisar.git && cd caisar - opam switch create --yes --no-install . ocaml-base-compiler.4.13.1 +**Please note:** CAISAR requires the OCaml package manager +(Opam) v2.1 or higher, which is typically avaible in all major +GNU/Linux distributions. -Install external dependencies::: +To install CAISAR via opam, do the following: - opam depext --yes ocplib-endian base fmt alt-ergo.2.4.0 - opam install . --deps-only --with-test --yes +``$ opam install caisar`` -Finally, run the compilation and the unit tests::: +Install through Docker +---------------------- - make - make test +This method requires Docker to be installed in your system. +A ready-to-use Docker image of CAISAR is available on +`Docker Hub <https://hub.docker.com>`_. To retrieve it, do the +following: +``$ docker pull laiser/caisar:pub`` + +Alternatively, a Docker image for CAISAR can be +created locally by proceeding as follows: + +:: + +$ git clone https://git.frama-c.com/pub/caisar +$ cd caisar +$ make docker + +To run the CAISAR Docker image, do the following: +``$ docker run -it laiser/caisar:pub sh`` + +Compile from source +------------------- + +To build and install CAISAR, do the following: + +:: + +$ git clone https://git.frama-c.com/pub/caisar +$ cd caisar +$ opam switch create --yes --no-install . 4.13.1 +$ opam install . --deps-only --with-test --yes +$ make +$ make install + +To run the tests: +``$ make test`` -- GitLab