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

make时未定义的引用 #2458

Closed
duishuhaoqi opened this issue Mar 22, 2021 · 5 comments
Closed

make时未定义的引用 #2458

duishuhaoqi opened this issue Mar 22, 2021 · 5 comments

Comments

@duishuhaoqi
Copy link

Please check the FAQ documentation before raising an issue*

Please check the FAQ documentation and old issues before raising an issue in case someone has asked the same question that you are asking.

Describe the bug (must be provided)
make时报错:

/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::Codec::doGetUncompressedLength(folly::IOBuf const*, folly::Optional) const’中:
(.text+0x238):对‘lzma_stream_buffer_bound’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::Codec::doGetUncompressedLength(folly::IOBuf const*, folly::Optional) const’中:
(.text+0xf4c):对‘lzma_end’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::Codec::doGetUncompressedLength(folly::IOBuf const*, folly::Optional) const’中:
(.text+0x1138):对‘lzma_end’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::Codec::doGetUncompressedLength(folly::IOBuf const*, folly::Optional) const’中:
(.text+0x1848):对‘lzma_end’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::Codec::doGetUncompressedLength(folly::IOBuf const*, folly::Optional) const’中:
(.text+0x1878):对‘lzma_end’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::hasStreamCodec(folly::io::CodecType)’中:
(.text+0x55ae):对‘lzma_code’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::hasStreamCodec(folly::io::CodecType)’中:
(.text+0x562a):对‘lzma_code’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::hasStreamCodec(folly::io::CodecType)’中:
(.text+0x5720):对‘lzma_auto_decoder’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::hasStreamCodec(folly::io::CodecType)’中:
(.text+0x5d87):对‘lzma_easy_encoder’未定义的引用
/home/syy/kg/nebula_test/nebula/build/third-party/install/lib/libfolly.a(Compression.cpp.o):在函数‘folly::io::hasStreamCodec(folly::io::CodecType)’中:
(.text+0x5ebd):对‘lzma_code’未定义的引用
collect2: 错误:ld 返回 1
make[2]: *** [bin/simple_kv_verify] 错误 1
make[1]: *** [src/tools/simple-kv-verify/CMakeFiles/simple_kv_verify.dir/all] 错误 2
make: *** [all] 错误 2

A clear and concise description of what the bug is.

Your Environments (must be provided)

  • OS: uname -a

Linux master 5.10.10-1.el7.elrepo.x86_64 #1 SMP Sat Jan 23 09:49:22 EST 2021 x86_64 x86_64 x86_64 GNU/Linux

  • Compliler: g++ --version or clang++ --version

g++ (GCC) 7.3.0

  • CPU: lscpu

Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 16
On-line CPU(s) list: 0-15
Thread(s) per core: 2
Core(s) per socket: 8

  • Commit id (e.g. a3ffc7d8)

How To Reproduce(must be provided)

Steps to reproduce the behavior:

  1. mkdir build
  2. cd build
  3. cmake ..
  4. make -j 12

Expected behavior

A clear and concise description of what you expected to happen.

Additional context

Provide logs and configs, or any other context to trace the problem.

@laura-ding
Copy link
Contributor

@duishuhaoqi thanks for your question. Could you give the output of 3. cmake ..

@duishuhaoqi
Copy link
Author

  • The output of cmake..
    -- NEBULA_USE_LINKER: bfd
    -- ENABLE_ASAN: OFF
    -- ENABLE_TESTING: ON
    -- ENABLE_UBSAN: OFF
    -- ENABLE_FUZZ_TEST: OFF
    -- ENABLE_TSAN: OFF
    -- ENABLE_STATIC_ASAN : OFF
    -- ENABLE_STATIC_UBSAN : OFF
    -- ENABLE_WERROR: ON
    -- ENABLE_STRICT_ALIASING: OFF
    -- ENABLE_PCH: OFF
    -- ENABLE_FRAME_POINTER: ON
    -- ENABLE_CCACHE: ON
    -- CCACHE_DIR: /home/syy/.ccache
    -- CMAKE_BUILD_TYPE = Debug (Options are: Debug, Release, RelWithDebInfo, MinSizeRel)
    -- CMAKE_INSTALL_PREFIX: /usr/local/nebula
    -- Specified NEBULA_THIRDPARTY_ROOT: /home/syy/kg/nebula/build/third-party/install
    -- CMAKE_INCLUDE_PATH: /home/syy/kg/nebula/build/third-party/install/include
    -- CMAKE_LIBRARY_PATH: /home/syy/kg/nebula/build/third-party/install/lib64:/home/syy/kg/nebula/build/third-party/install/lib
    -- CMAKE_PROGRAM_PATH: /home/syy/kg/nebula/build/third-party/install/bin
    -- Mstch_INCLUDE_DIR = /home/syy/kg/nebula/build/third-party/install/include , Mstch_LIBRARY = /home/syy/kg/nebula/build/third-party/install/lib/libmstch.a
    -- Could NOT find Threads (missing: Threads_FOUND)
    -- found krb5-config here /home/syy/kg/nebula/build/third-party/install/bin/krb5-config
    -- Found kerberos 5 headers: /home/syy/kg/nebula/build/third-party/install/include
    -- Found kerberos 5 libs: /home/syy/kg/nebula/build/third-party/install/lib/libgssapi_krb5.a;/home/syy/kg/nebula/build/third-party/install/lib/libkrb5.a;/home/syy/kg/nebula/build/third-party/install/lib/libk5crypto.a;/home/syy/kg/nebula/build/third-party/install/lib/libcom_err.a;/home/syy/kg/nebula/build/third-party/install/lib/libkrb5support.a
    -- Could NOT find LibLZMA (missing: LIBLZMA_HAS_AUTO_DECODER LIBLZMA_HAS_EASY_ENCODER LIBLZMA_HAS_LZMA_PRESET) (found version "5.2.4")
    -- Glibc version is 2.17
    -- Create the pre-commit hook
    -- Creating pre-commit hook done
    -- ENABLE_PACK_ONE: ON
    -- is_one is ON
    -- Configuring done
    -- Generating done
    -- Build files have been written to: /home/syy/kg/nebula/build

@laura-ding
Copy link
Contributor

Please give the whole content, the head output such as -- The C compiler identification is GNU

@duishuhaoqi
Copy link
Author

-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 7.3.0
-- Check for working C compiler: /usr/lib64/ccache/cc
-- Check for working C compiler: /usr/lib64/ccache/cc - works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/lib64/ccache/c++
-- Check for working CXX compiler: /usr/lib64/ccache/c++ - works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- NEBULA_USE_LINKER: bfd
-- ENABLE_ASAN: OFF
-- ENABLE_TESTING: ON
-- ENABLE_UBSAN: OFF
-- ENABLE_FUZZ_TEST: OFF
-- ENABLE_TSAN: OFF
-- ENABLE_STATIC_ASAN : OFF
-- ENABLE_STATIC_UBSAN : OFF
-- ENABLE_WERROR: ON
-- ENABLE_STRICT_ALIASING: OFF
-- ENABLE_PCH: OFF
-- ENABLE_FRAME_POINTER: ON
-- ENABLE_CCACHE: ON
-- CCACHE_DIR: /home/syy/.ccache
-- CMAKE_BUILD_TYPE = Debug (Options are: Debug, Release, RelWithDebInfo, MinSizeRel)
-- CMAKE_INSTALL_PREFIX: /usr/local/nebula
-- Found Git: /usr/bin/git (found version "1.8.3.1")
-- Downloading prebuilt third party automatically...
Downloading vesoft-third-party-x86_64-libc-2.17-gcc-7.1.0-abi-11.sh...
Nebula Third Party has been installed to /home/syy/kg/nebula/build/third-party/install
-- Specified NEBULA_THIRDPARTY_ROOT: /home/syy/kg/nebula/build/third-party/install
-- CMAKE_INCLUDE_PATH: /home/syy/kg/nebula/build/third-party/install/include
-- CMAKE_LIBRARY_PATH: /home/syy/kg/nebula/build/third-party/install/lib64:/home/syy/kg/nebula/build/third-party/install/lib
-- CMAKE_PROGRAM_PATH: /home/syy/kg/nebula/build/third-party/install/bin
-- Mstch_INCLUDE_DIR = /home/syy/kg/nebula/build/third-party/install/include , Mstch_LIBRARY = /home/syy/kg/nebula/build/third-party/install/lib/libmstch.a
-- Found ZLIB: /home/syy/kg/nebula/build/third-party/install/lib/libz.a (found version "1.2.11")
-- Found Boost: /home/syy/kg/nebula/build/third-party/install/include (found version "1.67.0")
-- Looking for pthread.h
-- Looking for pthread.h - not found
-- Could NOT find Threads (missing: Threads_FOUND)
-- Found OpenSSL: /home/syy/kg/nebula/build/third-party/install/lib/libcrypto.a (found version "1.1.1c")
-- found krb5-config here /home/syy/kg/nebula/build/third-party/install/bin/krb5-config
-- Found kerberos 5 headers: /home/syy/kg/nebula/build/third-party/install/include
-- Found kerberos 5 libs: /home/syy/kg/nebula/build/third-party/install/lib/libgssapi_krb5.a;/home/syy/kg/nebula/build/third-party/install/lib/libkrb5.a;/home/syy/kg/nebula/build/third-party/install/lib/libk5crypto.a;/home/syy/kg/nebula/build/third-party/install/lib/libcom_err.a;/home/syy/kg/nebula/build/third-party/install/lib/libkrb5support.a
-- Found GPERF: /home/syy/kg/nebula/build/third-party/install/bin/gperf (found suitable version "3.1", minimum required is "2.8")
-- Found Libunwind: /home/syy/kg/nebula/build/third-party/install/lib/libunwind.a
-- Found BISON: /home/syy/kg/nebula/build/third-party/install/bin/bison (found suitable version "3.0.5", minimum required is "3.0.5")
-- Found FLEX: /home/syy/kg/nebula/build/third-party/install/bin/flex (found version "2.6.4")
-- Found NCURSES: /usr/include
-- Looking for lzma_auto_decoder in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a
-- Looking for lzma_auto_decoder in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a - not found
-- Looking for lzma_easy_encoder in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a
-- Looking for lzma_easy_encoder in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a - not found
-- Looking for lzma_lzma_preset in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a
-- Looking for lzma_lzma_preset in /home/syy/kg/nebula/build/third-party/install/lib/liblzma.a - not found
-- Could NOT find LibLZMA (missing: LIBLZMA_HAS_AUTO_DECODER LIBLZMA_HAS_EASY_ENCODER LIBLZMA_HAS_LZMA_PRESET) (found version "5.2.4")
-- Glibc version is 2.17
-- Create the pre-commit hook
-- Creating pre-commit hook done
-- ENABLE_PACK_ONE: ON
-- is_one is ON
-- Configuring done
-- Generating done
-- Build files have been written to: /home/syy/kg/nebula/build

@laura-ding
Copy link
Contributor

-- The C compiler identification is GNU 4.8.5 -- The CXX compiler identification is GNU 7.3.0
Your GCC compiler is not the same version, please make them more than version 7.20.

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

No branches or pull requests

3 participants