Installing Batteries

Jürgen Hötzel edited this page Dec 30, 2016 · 11 revisions
  1. Installing from packages

Batteries is packaged in several distributions and package systems (some may have older packages):

  1. Installing from source

Batteries can be installed from source by downloading and unpacking the tarball (or cloning the Git repository) and running the following commands with GNU Make:

$ make
$ make test
$ make install

Optionally:

$ make install-doc

The following variables can be used to control Make’s behavior:

  • BATTERIES_NATIVE_SHLIB
    Set this to `no` to disable building dynamically-loadable native code modules for Batteries.
  • BATTERIES_NATIVE
    Set this to `no` to disable all native code compilation. This disables dynamically loaded native code modules as well.
  • DOCROOT
    Specifies the location for installing documentation. Defaults to `/usr/share/doc/ocaml-batteries`.
  • BROWSER_COMMAND
    Specifies the default command for invoking a web browser for help in the Batteries toplevel enhancements. Defaults to `x-www-browser %s`.

The modules are installed to `ocamlfind`’s default installation directory. Consult the OCamlFind documentation for how to control this via environment variables.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.