https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68631
Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution|--- |INVALID --- Comment #11 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to Hubert Jarosz from comment #9) > Oh, wait, now it works. So it's a bug when -lstdc++fs is not at the end. It's a bug in your command when you don't put it at the end. > On my normal g++/clang++ puting -l flags on the end works well, except for > this one on 5.3. It (sometimes) works for shared libraries. This is a static library, so must be listed after any objects that need it. This is how linkers work, so not a bug. http://c-faq.com/lib/libsearch.html