alibaba / GraphScope

🔨 🍇 💻 🚀 GraphScope: A One-Stop Large-Scale Graph Computing System from Alibaba | 一站式图计算系统
https://graphscope.io
Apache License 2.0
3.26k stars 442 forks source link

GraphScope Flex Interactive is incompatible with new version arrow. #3891

Closed zhanglei1949 closed 2 months ago

zhanglei1949 commented 3 months ago

When I have new version arrow installed, like v15.0.2, there seems to be cmake errors when building GraphScope Flex.

When I do cd GraphScope/flex && mkdir build && cd build && cmake ..

-- 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
-- Build HighQPS Engine: ON
-- Build test: ON
-- Build doc: OFF
-- Build odps fragment loader: OFF
-- Use pthash indexer : OFF
Build HighQPS Engine
5.15.0-58-generic
Use copy file range
-- Found MPI_CXX: /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi_cxx.so (found version "3.1") 
-- Found MPI: TRUE (found version "3.1")  
-- Found libgrapelite: /usr/local/lib/cmake/libgrapelite/libgrapelite-config.cmake (found version "0.3.4")
-- 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 Boost: /usr/lib/x86_64-linux-gnu/cmake/Boost-1.74.0/BoostConfig.cmake (found version "1.74.0") found components: system filesystem context program_options regex thread date_time 
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.2") 
-- Checking for modules 'libbrotlicommon;libbrotlienc;libbrotlidec'
--   Found libbrotlicommon, version 1.0.9
--   Found libbrotlienc, version 1.0.9
--   Found libbrotlidec, version 1.0.9
-- Found BrotliAlt: /usr/lib/x86_64-linux-gnu/libbrotlicommon.so  
-- Found OpenSSL: /usr/lib/x86_64-linux-gnu/libcrypto.so (found version "3.0.2")  
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11") 
-- Checking for module 'liblz4'
--   Found liblz4, version 1.9.3
-- Found lz4Alt: /usr/lib/x86_64-linux-gnu/liblz4.so  
-- Checking for module 'libzstd'
--   Found libzstd, version 1.4.8
-- Found zstdAlt: /usr/lib/x86_64-linux-gnu/libzstd.so (found 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
-- Found re2Alt: /usr/lib/x86_64-linux-gnu/libre2.so  
-- Found BZip2: /usr/lib/x86_64-linux-gnu/libbz2.so (found version "1.0.8") 
-- Looking for BZ2_bzCompressInit
-- Looking for BZ2_bzCompressInit - found
-- Found utf8proc: /usr/lib/x86_64-linux-gnu/libutf8proc.so (found version "2.7.0") 
-- Found nlohmann_json: /usr/lib/cmake/nlohmann_json/nlohmann_jsonConfig.cmake (found version "3.10.5") 
-- Found CURL: /usr/lib/x86_64-linux-gnu/libcurl.so (found version "7.81.0")  
-- Arrow version: 15.0.2
-- Found the Arrow shared library: /usr/lib/x86_64-linux-gnu/libarrow.so.1500.2.0
-- Found the Arrow import library: ARROW_IMPORT_LIB-NOTFOUND
-- Found the Arrow static library: /usr/lib/x86_64-linux-gnu/libarrow.a
CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindBrotliAlt.cmake:153 (add_library):
  add_library cannot create imported target "Brotli::brotlicommon" 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:109 (find_dependency)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:132 (arrow_find_dependencies)
  cmake/FindArrow.cmake:393 (find_package)
  CMakeLists.txt:125 (include)

CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindBrotliAlt.cmake:157 (add_library):
  add_library cannot create imported target "Brotli::brotlienc" 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:109 (find_dependency)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:132 (arrow_find_dependencies)
  cmake/FindArrow.cmake:393 (find_package)
  CMakeLists.txt:125 (include)

CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindBrotliAlt.cmake:161 (add_library):
  add_library cannot create imported target "Brotli::brotlidec" 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:109 (find_dependency)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:132 (arrow_find_dependencies)
  cmake/FindArrow.cmake:393 (find_package)
  CMakeLists.txt:125 (include)

CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/FindzstdAlt.cmake:132 (add_library):
  add_library cannot create imported target "zstd::libzstd_shared" 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:109 (find_dependency)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:132 (arrow_find_dependencies)
  cmake/FindArrow.cmake:393 (find_package)
  CMakeLists.txt:125 (include)

-- Zstandard library: /usr/lib/x86_64-linux-gnu/libzstd.so
-- Zstandard include directory: /usr/include

CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Arrow/Findutf8proc.cmake:114 (add_library):
  add_library cannot create imported target "utf8proc::utf8proc" 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:109 (find_dependency)
  /usr/lib/x86_64-linux-gnu/cmake/Arrow/ArrowConfig.cmake:132 (arrow_find_dependencies)
  cmake/FindArrow.cmake:393 (find_package)
  CMakeLists.txt:125 (include)

-- Arrow version: 15.0.2
-- Found the Arrow shared library: /usr/lib/x86_64-linux-gnu/libarrow.so
-- Found the Arrow import library: ARROW_IMPORT_LIB-NOTFOUND
-- Found the Arrow static library: /usr/lib/x86_64-linux-gnu/libarrow.a
-- Found Arrow: /usr/include (found version "15.0.2") 
-- Arrow version: 15.0.2 (CMake package configuration: Arrow)

It seems strange, since theoretically these dependencies should be taken care by cmake.

But when I manually include these dependencies before I find_package(arrow) in CMakeLists.txt, the problem seems to be resolved.

zhanglei1949 commented 3 months ago

@sighingnow Any idea?

zhanglei1949 commented 3 months ago

I suspect that another dependency, such as Seastar, has introduced the some same third-party library as Arrow, for example, utf8proc, and for some reason, add_library has been called twice.

zhanglei1949 commented 3 months ago

![Uploading 截屏2024-06-07 15.30.45.png…]()

zhanglei1949 commented 2 months ago

Fixed