caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Ocamldoc and multiple packages
@ 2009-09-11 15:47 Alexey Rodriguez
  2009-09-11 18:45 ` [Caml-list] " Ashish Agarwal
  2009-09-12 15:27 ` Edgar Friendly
  0 siblings, 2 replies; 4+ messages in thread
From: Alexey Rodriguez @ 2009-09-11 15:47 UTC (permalink / raw)
  To: OCaml List

Dear list,

I am trying to build ocamldoc documentation for an ocaml project that
contains multiple packages (collections of modules built using
-for-pack and -pack). My current setup generates documentation for
each package but it won't generate hyperlinks to modules in other
packages (module not found errors). I tried using the -load and -dump
commands to allow ocamldoc see the ocamldoc-results of the referred to
package, but I still get problems. I suspect that the problem arises
because ocamldoc does not have a -pack option, so it always sees
modules in a flat way. So if you have package Pack1 with module A, and
module B in Pack2 which refers to Pack1.A.t, ocamldoc cannot solve
this reference because it does not know that module A is inside
another module called Pack1.

The solutions I see right now seem to involve more effort than I am
willing to spend. So, before I embark on a task that might take too
long I would like to ask for tips on this. How do you perform ocamldoc
generation for projects with multiple packages? Thanks!

Cheers,

Alexey


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Caml-list] Ocamldoc and multiple packages
  2009-09-11 15:47 Ocamldoc and multiple packages Alexey Rodriguez
@ 2009-09-11 18:45 ` Ashish Agarwal
  2009-09-12 15:27 ` Edgar Friendly
  1 sibling, 0 replies; 4+ messages in thread
From: Ashish Agarwal @ 2009-09-11 18:45 UTC (permalink / raw)
  To: Alexey Rodriguez; +Cc: OCaml List

[-- Attachment #1: Type: text/plain, Size: 1611 bytes --]

I don't know the answer but you might try using ocamlbuild's mlpack and
odocl features, and see how it does it.

On Fri, Sep 11, 2009 at 11:47 AM, Alexey Rodriguez <mrchebas@gmail.com>wrote:

> Dear list,
>
> I am trying to build ocamldoc documentation for an ocaml project that
> contains multiple packages (collections of modules built using
> -for-pack and -pack). My current setup generates documentation for
> each package but it won't generate hyperlinks to modules in other
> packages (module not found errors). I tried using the -load and -dump
> commands to allow ocamldoc see the ocamldoc-results of the referred to
> package, but I still get problems. I suspect that the problem arises
> because ocamldoc does not have a -pack option, so it always sees
> modules in a flat way. So if you have package Pack1 with module A, and
> module B in Pack2 which refers to Pack1.A.t, ocamldoc cannot solve
> this reference because it does not know that module A is inside
> another module called Pack1.
>
> The solutions I see right now seem to involve more effort than I am
> willing to spend. So, before I embark on a task that might take too
> long I would like to ask for tips on this. How do you perform ocamldoc
> generation for projects with multiple packages? Thanks!
>
> Cheers,
>
> Alexey
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
>

[-- Attachment #2: Type: text/html, Size: 2262 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Caml-list] Ocamldoc and multiple packages
  2009-09-11 15:47 Ocamldoc and multiple packages Alexey Rodriguez
  2009-09-11 18:45 ` [Caml-list] " Ashish Agarwal
@ 2009-09-12 15:27 ` Edgar Friendly
  2009-09-15 12:11   ` Alexey Rodriguez
  1 sibling, 1 reply; 4+ messages in thread
From: Edgar Friendly @ 2009-09-12 15:27 UTC (permalink / raw)
  To: Alexey Rodriguez; +Cc: OCaml List

Alexey Rodriguez wrote:
> Dear list,
> 
> I am trying to build ocamldoc documentation for an ocaml project that
> contains multiple packages (collections of modules built using
> -for-pack and -pack). 

Batteries also has this problem, and does a decent job of solving it
through methods that are too complicated for me to explain in the margin
of this email.  :)  Read the source.

E


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Caml-list] Ocamldoc and multiple packages
  2009-09-12 15:27 ` Edgar Friendly
@ 2009-09-15 12:11   ` Alexey Rodriguez
  0 siblings, 0 replies; 4+ messages in thread
From: Alexey Rodriguez @ 2009-09-15 12:11 UTC (permalink / raw)
  To: Edgar Friendly; +Cc: OCaml List

Hi Edgar,

On Sat, Sep 12, 2009 at 5:27 PM, Edgar Friendly <thelema314@gmail.com> wrote:
> Alexey Rodriguez wrote:
>> Dear list,
>>
>> I am trying to build ocamldoc documentation for an ocaml project that
>> contains multiple packages (collections of modules built using
>> -for-pack and -pack).
>
> Batteries also has this problem, and does a decent job of solving it
> through methods that are too complicated for me to explain in the margin
> of this email.  :)  Read the source.

I had a quick look at batteries. I understood that the build system
makes one ocaml source file with the module structure of the whole
project, which ocamldoc should be able to parse. This solution looks
reusable (at least the idea does not seem too complex to implement).
Thanks for the tip!

Thanks to anyone else who replied.

Cheers,

Alexey


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-09-15 12:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-11 15:47 Ocamldoc and multiple packages Alexey Rodriguez
2009-09-11 18:45 ` [Caml-list] " Ashish Agarwal
2009-09-12 15:27 ` Edgar Friendly
2009-09-15 12:11   ` Alexey Rodriguez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).