This would allow packages producing shared libraries to link to packages producing only static libraries, even if the static library packages not add -fPIC in their build.
@mathstuf said:
Well, it's not always spelled '-fPIC', but yes, this makes sense. Here's
CMake's "table" of -fPIC flags:
Modules/Compiler/GNU.cmake: set(CMAKE_${lang}_COMPILE_OPTIONS_PIC "-fPIC")
Modules/Compiler/NAG-Fortran.cmake:set(CMAKE_Fortran_COMPILE_OPTIONS_PIC "-PIC")
Modules/Compiler/SCO.cmake: set(CMAKE_${lang}_COMPILE_OPTIONS_PIC -Kpic)
Modules/Compiler/SunPro-C.cmake:set(CMAKE_C_COMPILE_OPTIONS_PIC -KPIC)
Modules/Compiler/SunPro-CXX.cmake:set(CMAKE_CXX_COMPILE_OPTIONS_PIC -KPIC)
Modules/Compiler/SunPro-Fortran.cmake:set(CMAKE_Fortran_COMPILE_OPTIONS_PIC "-KPIC")
Modules/Compiler/XL.cmake: set(CMAKE_${lang}_COMPILE_OPTIONS_PIC "-qpic")