summaryrefslogtreecommitdiffstats
path: root/Modules/Platform/Linux-GNU-Fortran.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2008-03-17 12:55:05 (GMT)
committerBrad King <brad.king@kitware.com>2008-03-17 12:55:05 (GMT)
commit9f54e1f043dc522f14ce53c7356f4de1ae316c63 (patch)
tree949c1c3bafc749bfcb9bb900c38861ef42ba211b /Modules/Platform/Linux-GNU-Fortran.cmake
parent5a670176b944ad26b6501647563ba5ace4d6acba (diff)
downloadCMake-9f54e1f043dc522f14ce53c7356f4de1ae316c63.zip
CMake-9f54e1f043dc522f14ce53c7356f4de1ae316c63.tar.gz
CMake-9f54e1f043dc522f14ce53c7356f4de1ae316c63.tar.bz2
ENH: Patch from Maik to add per-configuration default flags to GCC and Intel Fortran compilers on Linux.
Diffstat (limited to 'Modules/Platform/Linux-GNU-Fortran.cmake')
-rw-r--r--Modules/Platform/Linux-GNU-Fortran.cmake15
1 files changed, 15 insertions, 0 deletions
diff --git a/Modules/Platform/Linux-GNU-Fortran.cmake b/Modules/Platform/Linux-GNU-Fortran.cmake
index ba13a43..16d63fc 100644
--- a/Modules/Platform/Linux-GNU-Fortran.cmake
+++ b/Modules/Platform/Linux-GNU-Fortran.cmake
@@ -1 +1,16 @@
SET(CMAKE_Fortran_MODDIR_FLAG -J)
+SET (CMAKE_SHARED_LIBRARY_Fortran_FLAGS "-fPIC") # -pic
+SET (CMAKE_Fortran_FLAGS_INIT "")
+SET (CMAKE_Fortran_FLAGS_DEBUG_INIT "-g")
+SET (CMAKE_Fortran_FLAGS_MINSIZEREL_INIT "-Os")
+SET (CMAKE_Fortran_FLAGS_RELEASE_INIT "-O3")
+SET (CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
+
+IF(NOT APPLE)
+ SET (CMAKE_INCLUDE_SYSTEM_FLAG_Fortran "-isystem ")
+ENDIF(NOT APPLE)
+
+# These will require updates to CMake C++ code to support
+# preprocessing rules for Fortran.
+#SET (CMAKE_Fortran_CREATE_PREPROCESSED_SOURCE "<CMAKE_Fortran_COMPILER> <DEFINES> <FLAGS> -E <SOURCE> > <PREPROCESSED_SOURCE>")
+#SET (CMAKE_Fortran_CREATE_ASSEMBLY_SOURCE "<CMAKE_Fortran_COMPILER> <DEFINES> <FLAGS> -S <SOURCE> -o <ASSEMBLY_SOURCE>")