This page describes the current state of the OCaml ecosystem.
- check.ocamllabs.io: View current build status of the entire OPAM ecosystem.
- The OCaml Platform: a community endeavor to standardize the infrastructure in the OCaml world.
For a list of things currently missing in OCaml’s ecosystem, see Help Needed
For an overview of the different standard library options and recommendations, see Standard Libraries.
Data Structures and Algorithms
Build System/Package Management
- aws-s3: Access to Amazon’s Simple Storage Solution (S3)
- Google Drive OCamlFuse: A User file system for Google Drive. Also one of the few ways to sync Google Drive from Linux.
See Code Tools
Command Line Arguments
- The standard library contains the Arg module, which has a simple syntax for defining command line arguments. However, it uses mutable state for arguments, and doesn’t have a built-in way to handle things such as sub-arguments, or argument aliases (long and short) for the same command, though these things can be done.
- Cmdliner is a declarative approach to laying out command-line arguments. The library uses combinators to build up the desired arguments.
- BOS - Basic OS Interaction is a general OS abstraction library which also contains a command line argument module (BOS.OS.Arg).
- Jane Street’s Core standard library contains the Command module, which takes a similar approach to Cmdliner.
- Minicli is a self-described minimalist library for command line parsing.
For compilation tools made in OCaml, see Compilers
Concurrency, Parallelism, Distributed Computing
- OCaml comes with a built-in debugger for the bytecode compiler.
You invoke it with the
ocamldebugcommand. See the manual for more details.
- The easiest way to debug OCaml code, other than inserting print statements, is choosing bytecode as your compilation target, and using teh OCaml debugger.
- Additionally, one can use
gdbto debug native code.
Formal Software Verification
For manipulating different file formats from OCaml, see File Formats
See File Manipulation.
Foreign Function Interface
For integrating with C, C++, Python etc., see Foreign Function Interface.
Functional Reactive Programming
For graphic libraries, see Graphics.
For usage of OCaml in hardware design, see Hardware Design
Accessors: a Lens library (easy access/functional updates to records).
- dolog: a simple OCaml logger.
- Volt: a variant of Bolt OCaml logging tool.
- Logs: provides a logging infrastructure for OCaml.
- easy-logging: An object-based simple logging module.
Machine Learning, Data Science, Scientific Computing
For machine learning, data science and scientific computing, see Scientific Computing
Metaprogramming and PPX
For metaprogramming facilities such as PPX, camlp4 and MetaOCaml, see Metaprogramming.
For compilation of OCaml to mobile platforms, see Mobile.
See Pretty Printing.
See Process Management.
For support of protocols, see Protocols
For static analysis using OCaml, see Static Analysis
For libraries related to search, see Searching
- The standard library’s String module is somewhat lacking in terms of functionality.
- Containers has an expanded String module, with iteration functions and so on. Containers strives to be backwards-compatible with the Stdlib.
- AString: another implementation of expanded string functionality, with less regard for standard library compatibility
- Bigstring: On 32-bit platforms, OCaml strings are constrained to 20MB sizes. This library allows one to handle strings of any sizes, and also to handle C-style strings as if they were OCaml strings. Built on top of BigArray, and supports memory-mapping.
- Bigstring/af: another implementation of a string overlay on top of BigArray, with similar benefits. Emphasizes speed.
For low-level systems programming, see Systems Programming
For testing frameworks in OCaml, see Testing
Time and Date
- For short-term timing requirements, Sys.time can do the job.
- mtime: wall-clock monotonic time, and the best choice for longer-running timing requirements.
- ptime: POSIX time.
For GUIs and TUIs (Terminal User Interfaces), see User Interface
Web and Networking
For libraries related to web development and networking, see Web and Networking