The PLplot project has been supporting some additional Fortran compilers via files in cmake/modules/Platform in our source tree where we use
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake/modules) This CMake_MODULE_PATH approach requires that we put a slightly modified version of CMakeFortranInformation.cmake in cmake/modules that searches ${CMAKE_MODULE_PATH}/Platform locations as well as ${CMAKE_ROOT}/Modules/Platform. That's pretty clumsy but this procedure has worked fine for CMake-2.6.x. However, I am having trouble with the cmake-2.8.0 case. (I am getting strange errors that use g++ rather than gfortran as the Fortran linker for the static Fortran library case). My guess is I need to add additional Fortran support files in cmake/modules for the CMake-2.8.0 case. But that is clumsier still and requires that we immediately drop CMake-2.6.x support. Thus, I am wondering if there is a better procedure (or whether such a procedure could be implemented within CMake) to allow convenient CMake support for a project like PLplot to support additional Fortran compilers (or any additional compilers for a CMake-supported language like Fortran) without requiring our users patch their installed version of CMake. Of course, the long-term solution to this problem is to contribute our files that support additional Fortran compilers to CMake. We would be happy to do that, but that probably involves considerable delay until they are accepted into an official CMake release, and in any case if our users find additional Fortran compilers (or C compilers or C++ compilers) they would like us to support, we would always need to independently test these files over at least one PLplot release cycle ourselves before contributing them to CMake. So I would appreciate an answer to the above question about the best procedure for supporting additional compilers (for Fortran or any other officially supported language for CMake) within a project like PLplot. 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