diff --git a/cmake/external_libs/libevent.cmake b/cmake/external_libs/libevent.cmake index dcf58cd6255..44b0e701bbb 100644 --- a/cmake/external_libs/libevent.cmake +++ b/cmake/external_libs/libevent.cmake @@ -1,6 +1,6 @@ set(libevent_CFLAGS "-fstack-protector-all -D_FORTIFY_SOURCE=2 -O2") if(NOT CMAKE_SYSTEM_NAME MATCHES "Darwin") - set(libevent_LDFLAGS "-Wl,-z,now") + set(libevent_LDFLAGS "-Wl,-z,now -ldl") endif() if(ENABLE_GITEE) diff --git a/cmake/external_libs/openssl.cmake b/cmake/external_libs/openssl.cmake index 368c96ba5ca..0b6cd35a2ce 100644 --- a/cmake/external_libs/openssl.cmake +++ b/cmake/external_libs/openssl.cmake @@ -11,3 +11,4 @@ mindspore_add_pkg(openssl URL ${REQ_URL} MD5 ${MD5} CONFIGURE_COMMAND ./config no-zlib no-shared) +include_directories(${openssl_INC}) \ No newline at end of file diff --git a/third_party/patch/grpc/grpc.patch001 b/third_party/patch/grpc/grpc.patch001 index b1cad454218..e105cf9ec38 100644 --- a/third_party/patch/grpc/grpc.patch001 +++ b/third_party/patch/grpc/grpc.patch001 @@ -10,3 +10,15 @@ diff -Npur grpc/CMakeLists.txt grpc-patch/CMakeLists.txt target_include_directories(grpc_cpp_plugin PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} +diff -Npur grpc/cmake/cares.cmake grpc-patch/cmake/cares.cmake +--- grpc/cmake/cares.cmake 2020-02-27 03:12:33.000000000 +0800 ++++ grpc-patch/cmake/cares.cmake 2021-04-10 14:22:35.895725700 +0800 +@@ -39,7 +39,7 @@ if(gRPC_CARES_PROVIDER STREQUAL "module" + set(gRPC_INSTALL FALSE) + endif() + elseif(gRPC_CARES_PROVIDER STREQUAL "package") +- find_package(c-ares 1.13.0 REQUIRED) ++ find_package(c-ares REQUIRED) # cmake 3.19+ cannot find cares 1.15.0 + if(TARGET c-ares::cares) + set(_gRPC_CARES_LIBRARIES c-ares::cares) + endif()