|
Notes |
|
|
(0016827)
|
|
Maik Beckmann
|
|
2009-07-07 15:44
|
|
|
|
|
(0016828)
|
|
Maik Beckmann
|
|
2009-07-07 15:48
|
|
I tweaked Modules/Platform/Linux-GNU-Fortran.cmake to make it work again
IF(CMAKE_Fortran_COMPILER MATCHES ".*g95")
SET (CMAKE_Fortran_MODDIR_FLAG -fmod=)
ELSE()
SET (CMAKE_Fortran_MODDIR_FLAG -J)
ENDIF()
I guess "IF(CMAKE_Fortran_COMPILER MATCHES ".*g95.exe")..." would solve this problem on windows, but I didn't tried it so far. |
|
|
|
(0017494)
|
|
Brad King
|
|
2009-09-14 17:59
|
|
|
Does this compiler have a vendor-specific preprocessor id (like __GNUC__ or _MSC_VER)? Is it really GNU? |
|
|
|
(0017526)
|
|
Maik Beckmann
|
2009-09-15 06:34
(edited on: 2009-09-16 02:53) |
|
<g95 manual>
Predefined Preprocessor Macros
The macros that are always defined are:
__G95__ 0
__G95_MINOR__ 50
__FORTRAN__ 95
__GNUC__ 4
</g95 manual>
So
#elif defined(__G95__)
is what we want.
This will of course only work, if this statement is listed before
#elif defined(__GNUC__)
or we rather use
#elif defined(__GFORTRAN__)
which unfortunately isn't defined before 4.3.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31694 [^]
|
|
|
|
(0017537)
|
|
Brad King
|
|
2009-09-15 12:29
|
|
So the proper compiler id should be "G95"?
Then we can create Compiler/G95-Fortran.cmake to set the moddir flag. |
|
|
|
(0017539)
|
|
Brad King
|
|
2009-09-15 12:49
|
|
|
Is g95 command-line compatible with GNU Fortran other than this option? |
|
|
|
(0017540)
|
|
Maik Beckmann
|
|
2009-09-15 13:03
|
|
My knowledge isn't comprehensive, I just reacted to the moddir problem I ran into.
But addressing this made everything work, so they don't differ in the command line options we use so far. |
|
|
|
(0018202)
|
|
Brad King
|
|
2009-10-23 08:26
|
|
Test all target types in Fortran
/cvsroot/CMake/CMake/Tests/Fortran/CMakeLists.txt,v <-- Tests/Fortran/CMakeLists.txt
new revision: 1.34; previous revision: 1.33
/cvsroot/CMake/CMake/Tests/Fortran/hello.f,v <-- Tests/Fortran/hello.f
new revision: 1.2; previous revision: 1.1
/cvsroot/CMake/CMake/Tests/Fortran/testf.f,v <-- Tests/Fortran/testf.f
initial revision: 1.1
/cvsroot/CMake/CMake/Tests/Fortran/world.f,v <-- Tests/Fortran/world.f
initial revision: 1.1
Add support for the g95 Fortran compiler
/cvsroot/CMake/CMake/Modules/CMakeFortranCompilerId.F.in,v <-- Modules/CMakeFortranCompilerId.F.in
new revision: 1.5; previous revision: 1.4
/cvsroot/CMake/CMake/Modules/Compiler/G95-Fortran.cmake,v <-- Modules/Compiler/G95-Fortran.cmake
initial revision: 1.1 |
|