*** Welcome to Batteries Included ***

OCaml Batteries Included: a community-maintained foundation library
for your OCaml projecs.


Batteries Included serves the following purposes:
* define a standard set of libraries which may be
  expected on every compliant installation of OCaml
* organize these libraries into a hierarchy of modules,
  with one source of documentation
* provide a consistent API for otherwise independent
  libraries.

*** Building Batteries Included ***

**** Requirements ****
You will need
* OCaml >= 3.11
* OMake (http://omake.metaprl.org/index.html)
* Findlib >= 1.2.5  (http://projects.camlcity.org/projects/findlib.html/)
* Camomile >= 0.7 (http://camomile.sourceforge.net/)
* OUnit    to build and run the tests

**** Configuration and installation ****

To install the full version of OCaml Batteries Included, execute

   $ omake all
   $ omake test     [ optional ]
   $ sudo omake install 

   $ omake doc      [ optional ]
   $ sudo omake install-doc   [ optional ]

If you want the documentation installed elsewhere, set this *before*
starting the build process (it becomes part of batteries_config.ml).

   $ export BATTERIES_DOCROOT=/path/to/new/docroot/

If you want findlib to use a -destdir argument to [ocamlfind install], set

   $ export DESTDIR=/path/to/findlib/dest

To disable native compilation:
   
   $ export BATTERIES_NATIVE=false

*** Using Batteries ***

To get started using Batteries at the toplevel, copy the ocamlinit
file to ~/.ocamlinit:

   $ cp ocamlinit ~/.ocamlinit

If you already have findlib in your ~/.ocamlinit, you only need the
last line in our ocamlinit to load batteries.

*** ExtLib Compatibility ***

If your project currently uses ExtLib, most likely you can just change
[-package extlib] to [-package batteries] and add [open Extlibcompat]
to the top of any extlib-using modules.  Batteries' modules are all
named BatFoo to differentiate them from extlib's modules, so one can
use Batteries and ExtLib in the same project.

COMPATIBILITY NOTE: If you're using ExtLib's Unzip module, it does not
have a corresponding module in batteries at the moment.

*** Extending Batteries Included ***

See doc/batteries/GUIDELINES
