Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
Impala 2.9.0
-
None
-
ghx-label-2
Description
The glog and gflags libraries are currently always statically linked against Impala, whether or not BUILD_SHARED_LIBS is true.
However, that can cause a problem if one of our libraries itself tries to link against glog or gflags: the google library will be linked twice in the final binary, and that causes problems for these particular libraries that require that they are linked at most once.
The proposed fix is to dynamically link glog and gflags if BUILD_SHARED_LIBS is true.
This is not an issue in our current code, but making this fix future-proofs us against running into the problem later (and the kudu util library has this exact issue, as it tries to link against glog directly).