rizsotto / Bear

Bear is a tool that generates a compilation database for clang tooling.
GNU General Public License v3.0
4.76k stars 312 forks source link

source build Bear failed on REL7/GCC8.1 -- SessionLibrary.cc:(.text+0x91e): undefined reference to `std::filesystem::path::_M_split_cmpts()' #449

Closed qluo1 closed 2 years ago

qluo1 commented 2 years ago

Describe the bug build from master branch failed with error: SessionLibrary.cc:(.text+0x91e): undefined reference to `std::filesystem::path::_M_split_cmpts()'

issue seems related to link c++ filesystem ?!

To Reproduce git clone https://github.com/rizsotto/Bear.git

cd Bear mkdir build ; cd build cmake ../ ... 16:13 $ make [ 19%] Built target grpc_dependency [ 19%] Built target googletest_dependency [ 39%] Built target nlohmann_json_dependency [ 58%] Built target fmt_dependency [ 78%] Built target spdlog_dependency [ 80%] Performing build step for 'BearSource' [ 1%] Built target flags_a [ 3%] Built target shell_a [ 13%] Built target sys_a [ 16%] Built target main_a [ 26%] Built target rpc_a [ 29%] Built target domain_a [ 32%] Built target events_db_a [ 45%] Built target exec_a [ 55%] Built target intercept_a [ 57%] Linking CXX executable intercept CMakeFiles/intercept_a.dir/source/collect/SessionLibrary.cc.o: In function ic::LibraryPreloadSession::supervise(domain::Execution const&) const': SessionLibrary.cc:(.text+0x91e): undefined reference tostd::filesystem::path::_M_split_cmpts()'

Environment:

Additional context

16:23 $ gcc --version gcc (GCC) 8.3.1 20190311

rizsotto commented 2 years ago

See https://github.com/rizsotto/Bear/issues/305#issuecomment-749002592