Ctypes bindings to flock(2) for OCaml
OCaml Makefile C
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bindings
lib
lib_test
stubgen
.coverage.excludes
.gitignore
.travis.yml
LICENSE
Makefile
README.md
_oasis
configure
myocamlbuild.ml
opam

README.md

ocaml-flock

Build Status Coverage Status API reference

Some type-safe C bindings to flock(2) and a simple OCaml wrapper function.

If you want to use flock and get on with your life then this is for you. Sure you can get this in Core, but if you only need flock then that's 10 more minutes building your package and 10 more MB to link it in that you can do without, right?

Installation

./configure [--enable-tests]
make
make install

Usage

There's only one function exposed by this library:

val flock : ?nonblocking:bool -> Unix.file_descr -> lock_operation -> unit

Go nuts!

Documentation

The API documentation for this library is automatically generated from source using ocamldoc and is available online.