On Tue, 1 Jun 2010 08:43:43 -0600, "Kelly Thompson" <k...@lanl.gov> wrote: > This can be done using a Fortran compile option. For gfortran, add the > option "-M<dir>" to CMAKE_Fortran_FLAGS.
Sure, however 1. One should use -J instead because (since 4.0), "-M is deprecated to avoid conflicts with existing GCC options." 2. It only works for gfortran, this is a serious problem if you have to support a lot of vendor compilers. Simply copying the module file to the desired destination is a much better solution. 3. The dependencies become even more broken, CMake needs to know where this file is generated and what rule is used to produce it. Hacking this in with compiler-specific flags will prevent CMake from knowing about it and generating correct build rules. Jed _______________________________________________ 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