Build/link error with android ndk r19 due to librt
未關閉
- 主要語言
- C++
- 星號
- 18.1k
- 分支
- 3.2k
- 平均合併
- 20 小時 36 分鐘
- 30 天內合併 PR
- 1
描述
We face a build error with the current LTS branch during the linking stage because abseil tries to link librt which doesn't really exist for android.
```
/opt/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/lib/gcc/arm-linux-androideabi/4.9.x/../../../../arm-linux-androideabi/bin/ld.gold: error: /usr/lib32/librt.so: incompatible target
```
It is fixed by replacing https://github.com/abseil/abseil-cpp/blob/68494aae959dfbbf781cdf03a988d2f5fc7e4802/absl/base/CMakeLists.txt#L17 by
```
if(NOT ANDROID)
find_library(LIBRT rt)
endif(NOT ANDROID)
```
貢獻指南
評估
這個 Issue 還沒有評估資料。