facebook / wdt

Warp speed Data Transfer (WDT) is an embeddedable library (and command line tool) aiming to transfer data between 2 systems as fast as possible over multiple TCP paths.
https://www.facebook.com/WdtOpenSource
Other
2.86k stars 391 forks source link

Execute cmake pathtowdtsrcdir -DBUILD_TESTING=on ,,,error #167

Closed shanwu888 closed 3 years ago

shanwu888 commented 7 years ago

-- Boost version: 1.64.0 -- Found the following Boost libraries: -- system -- filesystem -- Configuring done CMake Error in CMakeLists.txt: Target "option_type_test_short_flags" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "option_type_test_long_flags" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_files" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt4tests" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbenchtestslib" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbenchlib" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "protocol_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbin" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "folly4wdt" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "file_reader_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt4tests_min" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_url_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_stats" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "test_encdeci64_func" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_fd_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "test_stats" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "histogram" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_min" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "resource_controller_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_misc_tests" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "encryption_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

-- Generating done -- Build files have been written to: /usr/local/src/wdt

ldemailly commented 7 years ago

looks like your compiler is too old ? you need gcc 4.9 or equivalent/newer

next time please paste the full output up to the first error instead of the end

shanwu888 commented 7 years ago

my gcc version is 4.9。The installation of folly is right。

ldemailly commented 7 years ago

can you show the output of

cmake version
g++ --version

and the full output including your exact command line (cmake ../wdt ...) up to the first Target "option_type_test_short_flags" requires the language dialect "CXX14" error

shanwu888 commented 7 years ago

[root@itop wdt]# cmake --version cmake version 3.9.2

CMake suite maintained and supported by Kitware (kitware.com/cmake). [root@itop wdt]# g++ --version g++ (GCC) 4.9.4 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

shanwu888 commented 7 years ago

[root@itop wdt]# cmake /usr/local/src/wdt/ -DBUILD_TESTING=on -- Boost version: 1.64.0 -- Found the following Boost libraries: -- system -- filesystem -- Configuring done CMake Error in CMakeLists.txt: Target "option_type_test_short_flags" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "option_type_test_long_flags" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_files" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt4tests" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbenchtestslib" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbenchlib" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "protocol_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdtbin" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "folly4wdt" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "file_reader_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt4tests_min" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_url_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_stats" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_gen_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "test_encdeci64_func" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_fd_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "test_stats" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "histogram" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_min" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "resource_controller_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "wdt_misc_tests" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

CMake Error in CMakeLists.txt: Target "encryption_test" requires the language dialect "CXX14" (with compiler extensions), but CMake does not know the compile flags to use to enable it.

-- Generating done -- Build files have been written to: /usr/local/src/wdt

ldemailly commented 7 years ago

very strange, maybe a change in cmake 3.9, which OS is that ?

shanwu888 commented 7 years ago

OS is centos

ldemailly commented 7 years ago

can you try cmake 3.8 or what we need to change in the cmakelist to make it work ?

ldemailly commented 7 years ago

given you had compiler errors before maybe your build dir is caching your old compiler. try cmake ... from a new empty directory

shanwu888 commented 6 years ago

os is ubuntu。make appear error。 root@ubuntu:/usr/local/src/wdt# make [ 11%] Built target gtest [ 20%] Built target folly4wdt [ 60%] Built target wdt_min [ 61%] Built target wdt4tests_min [ 64%] Built target wdt4tests [ 66%] Built target encryption_test Linking CXX executable _bin/wdt/file_reader_test libwdt4tests.so: undefined reference to google::FlagRegisterer::FlagRegisterer<long>(char const*, char const*, char const*, long*, long*)' libwdt4tests.so: undefined reference togoogle::FlagRegisterer::FlagRegisterer(char const, char const, char const, int, int)' libwdt4tests.so: undefined reference to `google::FlagRegisterer::FlagRegisterer(char const, char const, char const, std::string, std::string)' libwdt4tests.so: undefined reference to google::FlagRegisterer::FlagRegisterer<double>(char const*, char const*, char const*, double*, double*)' libwdt4tests.so: undefined reference togoogle::FlagRegisterer::FlagRegisterer(char const, char const, char const, bool, bool*)' collect2: error: ld returned 1 exit status make[2]: [_bin/wdt/file_reader_test] Error 1 make[1]: [CMakeFiles/file_reader_test.dir/all] Error 2 make: *** [all] Error 2

ldemailly commented 6 years ago

you need to install gflags with the proper namespace https://github.com/facebook/wdt/blob/master/build/BUILD.md#build-instructions

hjmallon commented 5 years ago

This Pull Req might help at least part of this (the Gflags namespace) https://github.com/facebook/wdt/pull/191

davide125 commented 3 years ago

191 is merged, please reopen if this still repros