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

failed to build CacheLib following document #312

Open
gaowayne opened this issue May 12, 2024 · 2 comments
Open

failed to build CacheLib following document #312

gaowayne opened this issue May 12, 2024 · 2 comments

Comments

@gaowayne
Copy link

Hello expert, I run ./contrib/build.sh -T -v

but I got below build error on Folly

[ 99%] Linking CXX shared library liblogging_example_lib.so
cd /mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example && /usr/bin/cmake -E cmake_link_script CMakeFiles/logging_example_lib.dir/link.txt --verbose=YES
/usr/bin/c++ -fPIC -O2 -g -DNDEBUG -shared -Wl,-soname,liblogging_example_lib.so -o liblogging_example_lib.so CMakeFiles/logging_example_lib.dir/lib.cpp.o  -Wl,-rpath,/mnt/sdb/wayne/cachelib/CacheLib/build-folly:/mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib ../../../libfolly.so.0.58.0-dev /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libfmt.so.10.2.1 /usr/lib/x86_64-linux-gnu/libboost_context.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_filesystem.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_program_options.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_regex.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_system.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_thread.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_atomic.so.1.74.0 -ldouble-conversion /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libgflags.so.2.2.2 -lglog -levent -lz -lssl -lcrypto -lbz2 -llzma -llz4 /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libzstd.so -lsnappy -ldwarf -Wl,-Bstatic -liberty -Wl,-Bdynamic -laio -lsodium -ldl -lunwind 
make[2]: Leaving directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
[ 99%] Built target logging_example_lib
make  -f folly/logging/example/CMakeFiles/logging_example.dir/build.make folly/logging/example/CMakeFiles/logging_example.dir/depend
make[2]: Entering directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
cd /mnt/sdb/wayne/cachelib/CacheLib/build-folly && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /mnt/sdb/wayne/cachelib/CacheLib/cachelib/external/folly /mnt/sdb/wayne/cachelib/CacheLib/cachelib/external/folly/folly/logging/example /mnt/sdb/wayne/cachelib/CacheLib/build-folly /mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example /mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example/CMakeFiles/logging_example.dir/DependInfo.cmake --color=
make[2]: Leaving directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
make  -f folly/logging/example/CMakeFiles/logging_example.dir/build.make folly/logging/example/CMakeFiles/logging_example.dir/build
make[2]: Entering directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
[100%] Building CXX object folly/logging/example/CMakeFiles/logging_example.dir/main.cpp.o
cd /mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example && /usr/bin/c++ -DBOOST_ALL_NO_LIB -DBOOST_ATOMIC_DYN_LINK -DBOOST_CONTEXT_DYN_LINK -DBOOST_FILESYSTEM_DYN_LINK -DBOOST_PROGRAM_OPTIONS_DYN_LINK -DBOOST_REGEX_DYN_LINK -DBOOST_SYSTEM_DYN_LINK -DBOOST_THREAD_DYN_LINK -DFMT_SHARED -DFOLLY_XLOG_STRIP_PREFIXES=\"/mnt/sdb/wayne/cachelib/CacheLib/cachelib/external/folly:/mnt/sdb/wayne/cachelib/CacheLib/build-folly\" -DGFLAGS_IS_A_DLL=0 -I/mnt/sdb/wayne/cachelib/CacheLib/cachelib/external/folly -I/mnt/sdb/wayne/cachelib/CacheLib/build-folly -I/usr/include/libdwarf -I/usr/include/libiberty -isystem /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/include -O2 -g -DNDEBUG -fcoroutines -std=gnu++17 -MD -MT folly/logging/example/CMakeFiles/logging_example.dir/main.cpp.o -MF CMakeFiles/logging_example.dir/main.cpp.o.d -o CMakeFiles/logging_example.dir/main.cpp.o -c /mnt/sdb/wayne/cachelib/CacheLib/cachelib/external/folly/folly/logging/example/main.cpp
[100%] Linking CXX executable logging_example
cd /mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example && /usr/bin/cmake -E cmake_link_script CMakeFiles/logging_example.dir/link.txt --verbose=YES
/usr/bin/c++ -O2 -g -DNDEBUG -rdynamic CMakeFiles/logging_example.dir/main.cpp.o -o logging_example  -Wl,-rpath,/mnt/sdb/wayne/cachelib/CacheLib/build-folly/folly/logging/example:/mnt/sdb/wayne/cachelib/CacheLib/build-folly:/mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib liblogging_example_lib.so ../../../libfolly.so.0.58.0-dev /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libfmt.so.10.2.1 /usr/lib/x86_64-linux-gnu/libboost_context.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_filesystem.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_program_options.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_regex.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_system.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_thread.so.1.74.0 /usr/lib/x86_64-linux-gnu/libboost_atomic.so.1.74.0 -ldouble-conversion /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libgflags.so.2.2.2 -lglog -levent -lz -lssl -lcrypto -lbz2 -llzma -llz4 /mnt/sdb/wayne/cachelib/CacheLib/opt/cachelib/lib/libzstd.so -lsnappy -ldwarf -Wl,-Bstatic -liberty -Wl,-Bdynamic -laio -lsodium -ldl -lunwind 
/usr/bin/ld: ../../../libfolly.so.0.58.0-dev: undefined reference to `google::ErrnoLogMessage::ErrnoLogMessage(char const*, int, int, unsigned long, void (google::LogMessage::*)())'
collect2: error: ld returned 1 exit status
make[2]: *** [folly/logging/example/CMakeFiles/logging_example.dir/build.make:124: folly/logging/example/logging_example] Error 1
make[2]: Leaving directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
make[1]: *** [CMakeFiles/Makefile2:331: folly/logging/example/CMakeFiles/logging_example.dir/all] Error 2
make[1]: Leaving directory '/mnt/sdb/wayne/cachelib/CacheLib/build-folly'
make: *** [Makefile:136: all] Error 2
build-package.sh: error: make failed
build.sh: error: failed to build dependency 'folly'
root@mlperfubuntu:/mnt/sdb/wayne/cachelib/CacheLib# ./contrib/build.sh  -T -v 
@therealgymmy
Copy link
Contributor

can you share your build environment?

@therealgymmy
Copy link
Contributor

@gaowayne: is this related to #311 ?

Can we move all discussion there?

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

2 participants