| Anonymous | Login | Signup for a new account | 2013-06-20 00:56 CEST | ![]() |
| Main | My View | View Issues | Change Log | Roadmap |
| View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||||
| 0003190 | OCaml | OCaml general | public | 2004-09-29 05:11 | 2004-10-06 11:41 | ||||||
| Reporter | administrator | ||||||||||
| Assigned To | |||||||||||
| Priority | normal | Severity | feature | Reproducibility | always | ||||||
| Status | acknowledged | Resolution | open | ||||||||
| Platform | OS | OS Version | |||||||||
| Product Version | |||||||||||
| Target Version | Fixed in Version | ||||||||||
| Summary | 0003190: RFE: ocamldep flag to generate dependency on .cmi even when only .ml is present. | ||||||||||
| Description | Full_Name: Aleksey Nogin Version: 3.08.1 and CVS OS: Fedora Core Linux Submission from: charter-242-009.caltech.edu (131.215.242.9) Currently, if ocamldep finds an .ml file, but no .mli file while resolving dependencies, then ocamldep tries to do a make-compatible workaround. E.g., if files x.ml and x.mli contain "open Y", and only y.ml is present, then ocamldep will generate: x.cmi: y.cmo x.cmo: y.cmo x.cmx: y.cmx and "ocamldep -native" will generate x.cmi: y.cmx x.cmo: y.cmx x.cmx: y.cmx This is all fine in case of a build tool that is only paying attention to timestamps (as make does). However, in case of a build tool (such as omake) that: a) uses checksums to figure out when dependencies change and files need to be rebuilt, b) knows that compiling an .ml may produce a .cmi (if no .mli exists), the current ocamldep behaviour turns out to be suboptimal and even dangerous. If the y.ml file changes in a way that y.cmo/.cmx change, but the types and y.cmi remain the same, then the way ocamldep currently generates dependencies, the x.cmi and x.cmo would end up being rebuilt for no good reason. What's worse, if somehow a change in types affects the y.cmi, but y.cmo and/or y.cmx remain unchanged, then the x.cm* files might end up not being rebuilt when they should be. In short, I would like to request that an option be added to ocamldep (not sure what a good name for it would be - may be "-natural"?) to generate the "natural" dependencies even when only the .ml file is present. E.g. in the example above, "ocamldep -natural" would generate x.cmi: y.cmi x.cmo: y.cmi x.cmx: y.cmi y.cmx | ||||||||||
| Tags | No tags attached. | ||||||||||
| Attached Files | |||||||||||
Issue History |
|||
| Date Modified | Username | Field | Change |
| 2005-11-18 10:13 | administrator | New Issue | |
| Copyright © 2000 - 2011 MantisBT Group |