mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-08 14:50:10 -06:00
Linux-PGI: Prevent -rdynamic ending up in flags
Ensure that PGI on Linux keeps its CMAKE_SHARED_LIBRARY_LINK_<LANG>_FLAGS empty, especially of -rdynamic. In CMakeFortranInformation a lot of flags will be copied from their C equivalents if they're not defined. By using a combination of GCC and PGFortran, this will lead to -rdynamic ending up in the PGI flags and none of the PGI compilers understand that flag, crashing with a fatal error.
This commit is contained in:
@@ -14,4 +14,5 @@ macro(__linux_compiler_pgi lang)
|
||||
set(CMAKE_${lang}_COMPILE_OPTIONS_PIE "")
|
||||
set(CMAKE_SHARED_LIBRARY_${lang}_FLAGS "-fPIC")
|
||||
set(CMAKE_SHARED_LIBRARY_CREATE_${lang}_FLAGS "-shared")
|
||||
set(CMAKE_SHARED_LIBRARY_LINK_${lang}_FLAGS " ")
|
||||
endmacro()
|
||||
|
||||
Reference in New Issue
Block a user