Am Donnerstag, den 09.04.2015, 17:33 +0200 schrieb Daniel Bünzli: > In the assemblage project we are quite interested in seeing packages as named entities providing flags/and or objects to use in a given command execution context (defined as pre-processing, compiling, linking, etc. see [1] for more details). > > During the first build ("configure") we want to `ocamlfind query` packages for the right flags in each context and cache them so that we don't have to go through ocamlfind during the compilation (which slows down things quite a bit). > > Is there an invocation that allow us to get the flags or objects to use, the following don't seem to work: > > > ocamlfind query -predicates ppx -pp lwt.ppx > > ocamlfind query -pp lwt.ppx > > > and I don't see an obvious specifier for `-format` I can use. ocamlfind query -format '%(ppx)' lwt.ppx -pp is not meant for ppx. > It would be nice in general if ocamlfind would allow us to use `ocamlfind query` in obvious ways so that we can exactly reproduce what it does when whatever `ocamlfind TOOL -pkg PKG1,PKG2,PKG3` is being invoked. E.g. ocamlfind ocamlc -only-show ... then get the command from stdout and run it as often as you want. Gerd > I'm not working on this at the moment and don't have these things in my head but I remember that it proved to be quite challenging (if not impossible) to achieve that goal. > > Best, > > Daniel > > [1] http://samoht.github.io/assemblage/Assemblage.Ctx.html > > > -- ------------------------------------------------------------ Gerd Stolpmann, Darmstadt, Germany gerd@gerd-stolpmann.de My OCaml site: http://www.camlcity.org Contact details: http://www.camlcity.org/contact.html Company homepage: http://www.gerd-stolpmann.de ------------------------------------------------------------