|Anonymous | Login | Signup for a new account||2014-10-23 17:48 CEST|
|Main | My View | View Issues | Change Log | Roadmap|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0001217||OCaml||OCaml general||public||2002-06-26 16:38||2013-08-31 12:46|
|Target Version||Fixed in Version|
|Summary||0001217: ocamldep should warn about non-existent dependencies|
|Description||The manual for ocamldep states|
-I directory Add the given directory to the list of directories searched for
source files. If a source file foo.ml mentions an external compilation unit
Bar, a dependency on that unit's interface bar.cmi is generated only if the
source for bar is found in the current directory or in one of the
directories specified with -I. Otherwise, Bar is assumed to be a module form
the standard library, and no dependencies are generated. For programs that
span multiple directories, it is recommended to pass ocamldep the same -I
options that are passed to the compiler.
This is unsafe. In other words I had a bug in my Makefile and the -I
flags were not being passed to ocamldep. It took a while to notice
that bug. As a possible solution, I suggest that ocamldep check that
the module really does reside in the stdlib. There are other
solutions that you may prefer but I think we should err on the side of
Also, the word "form" should be changed to "from". (I often make this
|Tags||No tags attached.|
Fixed the typo in the doc.
Not sure the feature is worth the trouble.
I don't think we can implement this feature because ocamldep is not exact: because it works at the syntactic level and doesn't handle all the subtleties of the module system, it sometimes finds dependencies that are nonexistent.
A canonical example would be:
let random_state = State.make [| 1 |];;
On this file, currently ocamldep either ignores the reference to State (because it cannot find the .mli) or outputs a spurious dependency on state.cmi (if there is a file named state.mli).
With your change, in the first case it would output a spurious warning (that state.mli was not found).
This would rather discourage any serious use of the module system.
I'm setting this feature wish to resolved/wontfix, meaning that we won't work on it for the moment. We might come back to it one day if ocamldep gets an exact computation of dependencies.
|2005-11-18 10:13||administrator||New Issue|
|2008-01-22 14:07||doligez||Note Added: 0004427|
|2008-01-22 14:07||doligez||Summary||ocamldep => ocamldep should warn about non-existent dependencies|
|2008-01-22 14:07||doligez||Description Updated|
|2012-01-25 14:43||doligez||Note Added: 0006792|
|2012-01-25 14:43||doligez||Status||acknowledged => resolved|
|2012-01-25 14:43||doligez||Resolution||open => won't fix|
|2013-08-31 12:46||xleroy||Status||resolved => closed|
|Copyright © 2000 - 2011 MantisBT Group|