diff --git a/CMakeLists.txt b/CMakeLists.txt index a60786458b1202ebce8c38a22730675f755b283d..1248f096a914dda2fc992ce34ae069fbacfe06f8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1487,6 +1487,8 @@ target_include_directories(grpc_cronet target_link_libraries(grpc_cronet ${_gRPC_BASELIB_LIBRARIES} ${_gRPC_SSL_LIBRARIES} + ${_gRPC_ZLIB_LIBRARIES} + ${_gRPC_CARES_LIBRARIES} ${_gRPC_ALLTARGETS_LIBRARIES} gpr ) @@ -2075,6 +2077,8 @@ target_include_directories(grpc_unsecure target_link_libraries(grpc_unsecure ${_gRPC_BASELIB_LIBRARIES} + ${_gRPC_ZLIB_LIBRARIES} + ${_gRPC_CARES_LIBRARIES} ${_gRPC_ALLTARGETS_LIBRARIES} gpr ) diff --git a/templates/CMakeLists.txt.template b/templates/CMakeLists.txt.template index 71509c416bd48d8ad5a397797c183ed4a9c6f32d..53ae543c4c53432ea51c263cd5b484da4d3d0fba 100644 --- a/templates/CMakeLists.txt.template +++ b/templates/CMakeLists.txt.template @@ -43,7 +43,7 @@ deps.append("${_gRPC_SSL_LIBRARIES}") if target_dict.language == 'c++': deps.append("${_gRPC_PROTOBUF_LIBRARIES}") - if target_dict['name'] in ['grpc']: + if target_dict['name'] in ['grpc', 'grpc_cronet', 'grpc_unsecure']: deps.append("${_gRPC_ZLIB_LIBRARIES}") deps.append("${_gRPC_CARES_LIBRARIES}") deps.append("${_gRPC_ALLTARGETS_LIBRARIES}")