Linker errors when using boost::filesystem?
问题 I have the following code: #include <iostream> #include <boost\filesystem.hpp> int main(){ const char* file_path = "my_path"; std::cout << boost::filesystem::file_size(file_path) << std::endl; } and when I build I get the following errors: 1>Main.obj : error LNK2019: unresolved external symbol "class boost::system::error_category const & __cdecl boost::system::system_category(void)" (?system_category@system@boost@@YAAEBVerror_category@12@XZ) referenced in function "void __cdecl boost::system: