congratulations! :) please let me know when you have completed your scripts, so that i can replace mine with your in the yars refactoring tree.
cheers, keyan On 26 Jan 2010, at 22:53, Judicaël Bedouet wrote: > Thanks for your help. It is solved. A dependency between custom targets was > missing. In fact, the dependency was just between the custom command outputs > and I didn't think that setting a dependency between custom targets would > have solved the problem. > > I also have had to generate objects in separate directories (a directory per > target). Indeed, in the example of Keyan, some files are compiled twice and > there is no dependency between the two targets. So, if I compile all files in > the same directory, a file may be compiled and used in a link command at the > same time. It is a much more complex with separate directories and I have to > revise ocamldep output but it works. > > I don't have so much time for the moment but I will take a look at your CMake > files as soon as possible to test and improve my scripts. > > Thanks, > > J. Bedouet > > > > 2010/1/26 Alan W. Irwin <ir...@beluga.phys.uvic.ca> > On 2010-01-26 00:28+0100 Judicaël Bedouet wrote: > > I see one solution : add a macro to create an only target with all OCaml > libraries and executables, but it's not perfect. > > This issue should be straighforward to solve with proper dependencies for > _both_ custom targets and custom command OUTPUT files. We have our own > independent method of compiling OCaml libraries and executables which takes > care of such dependency issues correctly. See > http://plplot.svn.sourceforge.net/viewvc/plplot/trunk/bindings/ocaml/CMakeLists.txt?view=log, > http://plplot.svn.sourceforge.net/viewvc/plplot/trunk/bindings/ocaml/plcairo/CMakeLists.txt?view=log, > and > http://plplot.svn.sourceforge.net/viewvc/plplot/trunk/examples/ocaml/CMakeLists.txt?view=log. > > Our method is pretty brute force (a series of add_custom commands and > add_custom targets) so we are open to adopting something different if this > current thread results in something that ultimately ends up as part > of a CMake release. > > Note, our current method does work fine for parallel builds. Thus, it should > also be straightforward to make parallel builds work properly for any other > method of building ocaml libraries and apps if the necessary target and file > dependencies are handled correctly. > > Alan > __________________________ > Alan W. Irwin > > Astronomical research affiliation with Department of Physics and Astronomy, > University of Victoria (astrowww.phys.uvic.ca). > > Programming affiliations with the FreeEOS equation-of-state implementation > for stellar interiors (freeeos.sf.net); PLplot scientific plotting software > package (plplot.org); the libLASi project (unifont.org/lasi); the Loads of > Linux Links project (loll.sf.net); and the Linux Brochure Project > (lbproject.sf.net). > __________________________ > > Linux-powered Science > __________________________ > > _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake