fix(3p/abseil): Create position independent code
This makes it possible to link Abseil into shared libraries, e.g. the various Nix libraries.
This commit is contained in:
parent
e2fad0f0d2
commit
6dfef31374
1 changed files with 3 additions and 0 deletions
3
third_party/abseil_cpp/CMakeLists.txt
vendored
3
third_party/abseil_cpp/CMakeLists.txt
vendored
|
@ -51,6 +51,9 @@ list(APPEND CMAKE_MODULE_PATH
|
|||
${CMAKE_CURRENT_LIST_DIR}/absl/copts
|
||||
)
|
||||
|
||||
# Linking Abseil to shared libraries (such as Nix) requires PIC.
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE TRUE)
|
||||
|
||||
include(AbseilInstallDirs)
|
||||
include(CMakePackageConfigHelpers)
|
||||
include(AbseilDll)
|
||||
|
|
Loading…
Reference in a new issue