[CMake] Unable to run cmake using absoft f95 Fortran compiler

Brad King brad.king at kitware.com
Mon Aug 31 14:23:27 EDT 2009


venugopal gudimetla wrote:
> Thank you very much for your quick response.

BTW, Fortran support is greatly improved in CMake's development version.
If you can try the latest version from CVS HEAD, please do so.

> Yeah I noticed too that for
> some reason Cmakes is assuming f95 to be a GNU compiler.

CMake is not assuming anything.  It actually compiles a test source
file with the ".F" extension so that the preprocessor runs.  The source
uses preprocessor definitions to detect the compiler identification.
I think the compiler is defining __GNUC__.  This brings us back to
my question: does the compiler identify itself with any documented
preprocessor symbol?

> In the  file
> /cmake/Modules/CMakeDetermineFortranCompiler.cmake, I didn't see any
> reference to Absoft compilers, even though f90/f95 compilers are being
> listed as possible compilers.

Many Fortran compiler vendors provide tools called 'f90' and 'f95'.

> 2. I also set(CMAKE_SHARED_LIBRARY_LINK_Fortran_FLAGS "") in my
> CMakeLists.txt, which made no difference to the error message.

What is the actual link line that is failing?  You can see it
by running "make VERBOSE=1".

-Brad


More information about the CMake mailing list