id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 10038,filesystem library with -std=c++11 causes undefined reference to copy_file,jim.king@…,Beman Dawes,"{{{ #include int main(void) { boost::filesystem::copy_file(""a"", ""b""); return 0; } }}} Using either g++ 4.8.1 or clang++ 3.5 when I enable the compiler option -std=c++11, the boost::filesystem::detail::copy_file cannot be found in the library: {{{ root@dvm-3:/tmp# g++ --version g++ (Ubuntu 4.8.1-2ubuntu1~12.04) 4.8.1 # g++ -g -I/usr/include/boost-1_56 fscopy.cpp -o fscopy -lboost_filesystem-clang35-mt-d-1_56 -lboost_system-clang35-mt-d-1_56 # g++ -std=c++11 -g -I/usr/include/boost-1_56 fscopy.cpp -o fscopy -lboost_filesystem-clang35-mt-d-1_56 -lboost_system-clang35-mt-d-1_56 /usr/include/boost-1_56/boost/filesystem/operations.hpp:385: error: undefined reference to 'boost::filesystem::detail::copy_file(boost::filesystem::path const&, boost::filesystem::path const&, boost::filesystem::copy_option, boost::system::error_code*)' collect2: error: ld returned 1 exit status # /usr/bin/clang++ -g -I/usr/include/boost-1_56 fscopy.cpp -o fscopy -lboost_filesystem-clang35-mt-d-1_56 -lboost_system-clang35-mt-d-1_56 # /usr/bin/clang++ -std=c++11 -g -I/usr/include/boost-1_56 fscopy.cpp -o fscopy -lboost_filesystem-clang35-mt-d-1_56 -lboost_system-clang35-mt-d-1_56 /usr/include/boost-1_56/boost/filesystem/operations.hpp:385: error: undefined reference to 'boost::filesystem::detail::copy_file(boost::filesystem::path const&, boost::filesystem::path const&, boost::filesystem::copy_option, boost::system::error_code*)' clang: error: linker command failed with exit code 1 (use -v to see invocation) }}} The boost 1.56 libraries were built with clang-3.5 on Ubuntu 12.04.2 LTS with libstdc++ from g++-4.8.1 installed.",Bugs,closed,Boost 1.57.0,filesystem,Boost 1.56.0,Problem,fixed,filesystem copy_file undefined,