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:
Vincent Ambo 2020-05-20 04:01:41 +01:00
parent e2fad0f0d2
commit 6dfef31374

View file

@ -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)