Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Find the gRPC package correctly #278

Merged
merged 1 commit into from
Aug 31, 2023
Merged

Conversation

lidongze0629
Copy link
Contributor

@lidongze0629 lidongze0629 commented Aug 31, 2023

This PR fixes the failure during compiling graphlearn with the vineyard package by:

  • Correctly the behavior in FindGRPC.cmake to find the gRPC package
  • Find vineyard before gRPC to fix the the problem in cmake: gRPC::grpc++_reflection target already exists.
cmake -DCMAKE_INSTALL_PREFIX=/opt/graphscope         -DKNN=OFF         -DWITH_VINEYARD=ON         -DTESTING=OFF ..
-- The CXX compiler identification is GNU 11.4.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for C++ include pthread.h
-- Looking for C++ include pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Found Glog: /usr/include
-- Found glog    (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libglog.so)
-- Found GFlags: /usr/include
-- Found gflags  (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libgflags.so)
-- Found gRPC: /usr/lib/x86_64-linux-gnu/libgpr.so
Graph-learn is built with vineyard support.
-- Checking for modules 'libbrotlicommon;libbrotlienc;libbrotlidec'
--   Found libbrotlicommon, version 1.0.9
--   Found libbrotlienc, version 1.0.9
--   Found libbrotlidec, version 1.0.9
-- Checking for module 'thrift'
--   Found thrift, version 0.16.0
-- Checking for module 'liblz4'
--   Found liblz4, version 1.9.3
-- Checking for module 'libzstd'
--   Found libzstd, version 1.4.8
-- Zstandard library: /usr/lib/x86_64-linux-gnu/libzstd.so
-- Zstandard include directory: /usr/include
-- Checking for module 're2'
--   Found re2, version 0.0.0
-- Checking for module 'grpc++'
--   Found grpc++, version 1.30.2
CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindgRPCAlt.cmake:85 (add_library):
  add_library cannot create imported target "gRPC::grpc++" because another
  target with the same name already exists.
Call Stack (most recent call first):
  /usr/share/cmake-3.22/Modules/CMakeFindDependencyMacro.cmake:47 (find_package)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:115 (find_dependency)
  /opt/vineyard/lib/cmake/vineyard/vineyard-config.cmake:42 (find_package)
  CMakeLists.txt:298 (find_package)


CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindgRPCAlt.cmake:94 (add_library):
  add_library cannot create imported target "gRPC::grpc++_reflection" because
  another target with the same name already exists.
Call Stack (most recent call first):
  /usr/share/cmake-3.22/Modules/CMakeFindDependencyMacro.cmake:47 (find_package)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:115 (find_dependency)
  /opt/vineyard/lib/cmake/vineyard/vineyard-config.cmake:42 (find_package)
  CMakeLists.txt:298 (find_package)


CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindgRPCAlt.cmake:100 (add_executable):
  add_executable cannot create imported target "gRPC::grpc_cpp_plugin"
  because another target with the same name already exists.
Call Stack (most recent call first):
  /usr/share/cmake-3.22/Modules/CMakeFindDependencyMacro.cmake:47 (find_package)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:115 (find_dependency)
  /opt/vineyard/lib/cmake/vineyard/vineyard-config.cmake:42 (find_package)
  CMakeLists.txt:298 (find_package)


-- Found libgrapelite: /opt/vineyard/lib/cmake/libgrapelite/libgrapelite-config.cmake (found version "0.3.1")
-- Found vineyard: /opt/vineyard/lib/cmake/vineyard/vineyard-config.cmake (found version "0.16.4")
-- Performing Test HAS_STDCXX_17
-- Performing Test HAS_STDCXX_17 - Success
-- Configuring incomplete, errors occurred!
See also "/home/graphscope/GraphScope/learning_engine/graph-learn/graphlearn/cmake-build/CMakeFiles/CMakeOutput.log".

@sighingnow sighingnow merged commit 9682c9b into alibaba:master Aug 31, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants