I have a similar development setup and have made effective use of ocp-build to enable a tight development loop while still supporting opam deployment.  Suppose you have libraries A and B and a program P that uses these, each in their own directory (or repository).  You set these up with a per-project .ocp file that describes the library / program sources and a per-project Makefile.  For each project X, the Makefile (or OPAM build rules) executes:
  ocp-build init
  ocp-build configure
  ocp-build X

This configures ocp-build to only search in that directory when doing its build.  When doing development, you skip the per-project makefiles and instead arrange things as:
  projects/A
  projects/B
  projects/P

And you execute the "ocp-build init; ocp-build configure" portion in the *projects* directory.  This sets "projects" as the ocp-build root directory and causes ocp-build to find all the per-project .ocp files.  The dependencies between the program and libraries will be properly resolved and even if you have A or B installed with findlib, the local versions of the libraries will take precedence when building / linking P.  Just compile P with "ocp-build P" (executed somewhere in the projects/ directory tree).  You do have to be careful to ensure that during development you never accidentally create a "projects/X/_obuild" directory (e.g. you never accidentally invoke "make" in any of the project directories).  ocp-build will stop at the first _obuild directory it finds, so having _obuild directories other than projects/_obuild will prevent the full traversal of the projects/* subdirectories.

--Stephen


On Thu, Dec 12, 2013 at 7:12 PM, Daniel Bünzli <daniel.buenzli@erratique.ch> wrote:


Le vendredi, 13 décembre 2013 à 00:57, Anthony Tavener a écrit :

> I regularly develop libraries in parallel with application code.

Since you seem to be using ocamlbuild, at a certain point I was using (and still use sometimes) a workflow that I described here:

http://brion.inria.fr/gallium/index.php/Working_on_dependent_projects_with_ocamlbuild

If you work with version control you could also make local git package for the libs. That way you can update your all your libraries after new commits with a single `opam update && opam upgrade`.

Best,

Daniel



--
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs