
Hi, I'm trying to include the Boost Regex source in a Visual C++ project, but I get the following linker error: (indented for legibility) error LNK2019: unresolved external symbol "private: class boost::basic_regex< char, struct boost::regex_traits< char, class boost::w32_regex_traits<char> > > & __thiscall boost::basic_regex< char, struct boost::regex_traits< char, class boost::w32_regex_traits<char> > >:: do_assign( char const *, char const *, unsigned int)" (?do_assign@?$basic_regex@DU?$regex_traits@DV?$w32_regex_traits@D@bo ost@@@boost@@@boost@@AAEAAV12@PBD0I@Z) referenced in function "public: class boost::basic_regex< char, struct boost::regex_traits< char, class boost::w32_regex_traits<char> > > & __thiscall boost::basic_regex< char, struct boost::regex_traits< char, class boost::w32_regex_traits<char> > >:: assign( char const *, char const *, unsigned int)" (?assign@?$basic_regex@DU?$regex_traits@DV?$w32_regex_traits@D@boost @@@boost@@@boost@@QAEAAV12@PBD0I@Z) Here are the steps I'm taking: I downloaded the latest Boost (boost_1_39_0.zip), and extracted it all into its own directory; I've tried extracting with both the built-in Windows Zip Folder support and the latest WinRAR. I did not do any making (nmake) or building on the Boost source -- after extracting, I don't touch this directory directly at all. In both Visual Studio 2005 and Visual C++ 2008 Express Edition (http://www.microsoft.com/express/vc/), I created a new empty console project, and I added a new .cpp file to the project. I went to Project -> Properties, Configuration Properties -> C/C++ -
General: Additional Include Directories, and (for the "Active(Debug)" configuration) added the full path of the directory containing the source, so that "boost" is a subdirectory in the selected directory.
I wrote the following code:
#define BOOST_REGEX_SOURCE
#include