4 ocamldep \- Dependency generator for Objective Caml
17 command scans a set of Objective Caml source files
18 (.ml and .mli files) for references to external compilation units,
19 and outputs dependency lines in a format suitable for the
21 utility. This ensures that make will compile the source files in the
22 correct order, and recompile those files that need to when a source
31 where .depend is the file that should contain the
34 Dependencies are generated both for compiling with the bytecode
37 and with the native-code compiler
42 The following command-line option is recognized by
47 Add the given directory to the list of directories searched for
48 source files. If a source file foo.ml mentions an external
49 compilation unit Bar, a dependency on that unit's interface
50 bar.cmi is generated only if the source for bar is found in the
51 current directory or in one of the directories specified with
53 Otherwise, Bar is assumed to be a module from the standard library,
54 and no dependencies are generated. For programs that span multiple
55 directories, it is recommended to pass
57 the same -I options that are passed to the compiler.
61 Generate dependencies for a pure native-code program (no bytecode
62 version). When an implementation file (.ml file) has no explicit
63 interface file (.mli file),
65 generates dependencies on the
66 bytecode compiled file (.cmo file) to reflect interface changes.
67 This can cause unnecessary bytecode recompilations for programs that
68 are compiled to native-code only. The flag
70 causes dependencies on native compiled files (.cmx) to be generated instead
71 of on .cmo files. (This flag makes no difference if all source files
72 have explicit .mli interface files.)
78 .I The Objective Caml user's manual,
79 chapter "Dependency generator".