Commit 00477de1 authored by Brad King's avatar Brad King
Browse files

Use response file for objects on MinGW and MSYS

Windows command lines are limited to about 32K so we need to use
response files for linking very large lists of object files.

See issue #10401.
parent f9268c9c
include(Platform/Windows-GNU) include(Platform/Windows-GNU)
__windows_compiler_gnu(Fortran) __windows_compiler_gnu(Fortran)
set(CMAKE_Fortran_USE_RESPONSE_FILE_FOR_OBJECTS 0)
...@@ -68,6 +68,8 @@ macro(__windows_compiler_gnu lang) ...@@ -68,6 +68,8 @@ macro(__windows_compiler_gnu lang)
endif() endif()
set(CMAKE_SHARED_LIBRARY_${lang}_FLAGS "") # No -fPIC on Windows set(CMAKE_SHARED_LIBRARY_${lang}_FLAGS "") # No -fPIC on Windows
set(CMAKE_${lang}_USE_RESPONSE_FILE_FOR_OBJECTS 1)
set(CMAKE_${lang}_RESPONSE_FILE_LINK_FLAG "-Wl,@")
# Binary link rules. # Binary link rules.
set(CMAKE_${lang}_CREATE_SHARED_MODULE set(CMAKE_${lang}_CREATE_SHARED_MODULE
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment