diff options
author | Brad King <brad.king@kitware.com> | 2011-01-10 14:58:55 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2011-01-10 14:58:55 (GMT) |
commit | c2d73c938abc726df985058aa771a5b1710d96f2 (patch) | |
tree | 5a6f3548e2f89b042d32f4072d4b9f321111d51e /Modules/CMakeFortranInformation.cmake | |
parent | a300edab4132d73093deaf0987b6c4cf027dc2d5 (diff) | |
download | CMake-c2d73c938abc726df985058aa771a5b1710d96f2.zip CMake-c2d73c938abc726df985058aa771a5b1710d96f2.tar.gz CMake-c2d73c938abc726df985058aa771a5b1710d96f2.tar.bz2 |
Allow platform files to set large archive rules (#11674)
Commit aaa88d33 (Build large archives incrementally, 2008-08-04)
hard-coded rules to create static archives incrementally in each
language information file. Set each rule conditionally to allow
compiler and platform information files to override the language
default rules.
Inspired-by: Harald Pohl <pohl.h@eppendorf.de>
Diffstat (limited to 'Modules/CMakeFortranInformation.cmake')
-rw-r--r-- | Modules/CMakeFortranInformation.cmake | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/Modules/CMakeFortranInformation.cmake b/Modules/CMakeFortranInformation.cmake index 1e9b4e0..d18353a 100644 --- a/Modules/CMakeFortranInformation.cmake +++ b/Modules/CMakeFortranInformation.cmake @@ -163,9 +163,15 @@ ENDIF(NOT CMAKE_Fortran_CREATE_SHARED_MODULE) # Create a static archive incrementally for large object file counts. # If CMAKE_Fortran_CREATE_STATIC_LIBRARY is set it will override these. -SET(CMAKE_Fortran_ARCHIVE_CREATE "<CMAKE_AR> cr <TARGET> <LINK_FLAGS> <OBJECTS>") -SET(CMAKE_Fortran_ARCHIVE_APPEND "<CMAKE_AR> r <TARGET> <LINK_FLAGS> <OBJECTS>") -SET(CMAKE_Fortran_ARCHIVE_FINISH "<CMAKE_RANLIB> <TARGET>") +IF(NOT DEFINED CMAKE_Fortran_ARCHIVE_CREATE) + SET(CMAKE_Fortran_ARCHIVE_CREATE "<CMAKE_AR> cr <TARGET> <LINK_FLAGS> <OBJECTS>") +ENDIF() +IF(NOT DEFINED CMAKE_Fortran_ARCHIVE_APPEND) + SET(CMAKE_Fortran_ARCHIVE_APPEND "<CMAKE_AR> r <TARGET> <LINK_FLAGS> <OBJECTS>") +ENDIF() +IF(NOT DEFINED CMAKE_Fortran_ARCHIVE_FINISH) + SET(CMAKE_Fortran_ARCHIVE_FINISH "<CMAKE_RANLIB> <TARGET>") +ENDIF() # compile a Fortran file into an object file IF(NOT CMAKE_Fortran_COMPILE_OBJECT) |