grpc compile -fpic

This commit is contained in:
huaixin.lmy 2024-09-25 15:51:21 +08:00
parent e6efa89691
commit eb65f9bf35
1 changed files with 2 additions and 0 deletions

View File

@ -44,6 +44,8 @@ cd third_party/cares/cares
# git checkout cares-1_15_0
mkdir -p cmake/build
cd cmake/build
export CFLAGS="-fPIC"
export CXXFLAGS="-fPIC"
cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=${RPM_BUILD_ROOT}/%{_prefix} -DCARES_STATIC=ON -DCARES_SHARED=OFF -DCARES_STATIC_PIC=ON ../..
CPU_CORES=`grep -c ^processor /proc/cpuinfo`
make -j${CPU_CORES} install