From 724a0346f7bd424ce0e5db246cee46db9f377a6f Mon Sep 17 00:00:00 2001 From: Marc Chevrier Date: Thu, 11 Oct 2018 12:20:29 +0200 Subject: POSITION_INDEPENDENT_CODE: Fix erroneous '-fPIE' flag for Sun Studio Fixes: #16311 --- Modules/Compiler/SunPro-C.cmake | 1 + Modules/Compiler/SunPro-CXX.cmake | 1 + Modules/Compiler/SunPro-Fortran.cmake | 1 + 3 files changed, 3 insertions(+) diff --git a/Modules/Compiler/SunPro-C.cmake b/Modules/Compiler/SunPro-C.cmake index 047de43..1988aae 100644 --- a/Modules/Compiler/SunPro-C.cmake +++ b/Modules/Compiler/SunPro-C.cmake @@ -6,6 +6,7 @@ include(Compiler/SunPro) set(CMAKE_C_VERBOSE_FLAG "-#") set(CMAKE_C_COMPILE_OPTIONS_PIC -KPIC) +set(CMAKE_C_COMPILE_OPTIONS_PIE "") set(CMAKE_SHARED_LIBRARY_C_FLAGS "-KPIC") set(CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS "-G") set(CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG "-R") diff --git a/Modules/Compiler/SunPro-CXX.cmake b/Modules/Compiler/SunPro-CXX.cmake index 4c1ac5b..f463be3 100644 --- a/Modules/Compiler/SunPro-CXX.cmake +++ b/Modules/Compiler/SunPro-CXX.cmake @@ -6,6 +6,7 @@ include(Compiler/SunPro) set(CMAKE_CXX_VERBOSE_FLAG "-v") set(CMAKE_CXX_COMPILE_OPTIONS_PIC -KPIC) +set(CMAKE_CXX_COMPILE_OPTIONS_PIE "") set(CMAKE_SHARED_LIBRARY_CXX_FLAGS "-KPIC") set(CMAKE_SHARED_LIBRARY_CREATE_CXX_FLAGS "-G") set(CMAKE_SHARED_LIBRARY_RUNTIME_CXX_FLAG "-R") diff --git a/Modules/Compiler/SunPro-Fortran.cmake b/Modules/Compiler/SunPro-Fortran.cmake index 2247dd0..d3a415f 100644 --- a/Modules/Compiler/SunPro-Fortran.cmake +++ b/Modules/Compiler/SunPro-Fortran.cmake @@ -3,6 +3,7 @@ set(CMAKE_Fortran_FORMAT_FIXED_FLAG "-fixed") set(CMAKE_Fortran_FORMAT_FREE_FLAG "-free") set(CMAKE_Fortran_COMPILE_OPTIONS_PIC "-KPIC") +set(CMAKE_Fortran_COMPILE_OPTIONS_PIE "") set(CMAKE_SHARED_LIBRARY_Fortran_FLAGS "-KPIC") set(CMAKE_SHARED_LIBRARY_CREATE_Fortran_FLAGS "-G") set(CMAKE_SHARED_LIBRARY_RUNTIME_Fortran_FLAG "-R") -- cgit v0.12