The group you are posting to is a
Usenet group . Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
From:
Kevlar <ts... @verse-studios.com>
Date: Sat, 26 Jan 2008 12:21:49 -0800 (PST)
Local: Sat, Jan 26 2008 3:21 pm
Subject: Re: [Boost-users] libXXX
I'm also having the same problem after installing from the BoostPro Installer with VC9.
Just going off the basic example, my program is:
#include "stdafx.h" #include <boost/regex.hpp> #include <iostream> #include <string>
using namespace std;
#ifdef WIN32 int _tmain(int argc, _TCHAR* argv[]) #else int main() #endif { std::string line; boost::regex pat( "^Subject: (Re: |Aw: )*(.*)" );
while (std::cin) { std::getline(std::cin, line); boost::smatch matches; if (boost::regex_match(line, matches, pat)) std::cout << matches[2] << std::endl; }
}
And I'm getting: Linking... libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Orphan_all(void)const " (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ) referenced in function "public: class std::vector<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > > & __thiscall std::vector<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > >::operator=(class std::vector<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > > const &)" (??4?$vector@U?$sub_match@PBD@boost@@V?$allocator@U?$sub_match@PBD@boost@@@ std@@@std@@QAEAAV01@ABV01@@Z) libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::~_Container_base(void)" (__imp_??1_Container_base@std@@QAE@XZ) referenced in function "public: __thiscall std::_Vector_val<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > >::~_Vector_val<struct boost::sub_match<char const *>,class
std::allocator<struct boost::sub_match<char const *> > >(void)" (??1?$_Vector_val@U?$sub_match@PBD@boost@@V?$allocator@U?$sub_match@PBD@boo st@@@std@@@std@@QAE@XZ) libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall std::_Container_base::_Container_base(void)" (__imp_??0_Container_base@std@@QAE@XZ) referenced in function "protected: __thiscall std::_Vector_val<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > >::_Vector_val<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > >(class std::allocator<struct boost::sub_match<char const *> >)" (??0?$_Vector_val@U?$sub_match@PBD@boost@@V?$allocator@U?$sub_match@PBD@boo st@@@std@@@std@@IAE@V?$allocator@U?$sub_match@PBD@boost@@@1@@Z) libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall std::_Container_base::_Swap_all(class std::_Container_base &)const " (__imp_?_Swap_all@_Container_base@std@@QBEXAAV12@@Z) referenced in function "public: void __thiscall std::vector<struct boost::sub_match<char const *>,class std::allocator<struct boost::sub_match<char const *> > >::swap(class std::vector<struct boost::sub_match<char const *>,class
std::allocator<struct boost::sub_match<char const *> > > &)" (?swap@?$vector@U?$sub_match@PBD@boost@@V?$allocator@U?$sub_match@PBD@boost @@@std@@@std@@QAEXAAV12@@Z) libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::_String_iterator<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >::insert(class std::_String_iterator<char,struct std::char_traits<char>,class std::allocator<char> >,char)" (__imp_?insert@?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@ @QAE?AV?$_String_iterator@DU?$char_traits@D@std@@V?$allocator@D@2@@2@V32@D@ Z) referenced in function "public: struct boost::re_detail::re_syntax_base * __thiscall boost::re_detail::basic_regex_creator<char,struct boost::regex_traits<char,class boost::w32_regex_traits<char> > >::append_set(class boost::re_detail::basic_char_set<char,struct
boost::regex_traits<char,class boost::w32_regex_traits<char> > > const &,struct boost::mpl::bool_<0> *)" (?append_set@?$basic_regex_creator@DU?$regex_traits@DV?$w32_regex_traits@D@ boost@@@boost@@@re_detail@boost@@QAEPAUre_syntax_base@23@ABV?$basic_char_se t@DU?$regex_traits@DV?$w32_regex_traits@D@boost@@@boost@@@23@PAU?$bool_@$0A @@mpl@3@@Z) C:\Documents and Settings\corwin\My Documents\Visual Studio 2008\Projects\Bella\Debug\Bella.exe : fatal error LNK1120: 5 unresolved externals
David Randolph Palmer wrote:
> I was able to build everything, but now get link errors, anyone know the > answer?
> Dave
> Build Log Rebuild started: Project: example, Configuration: > Debug|Win32 > Command Lines Creating temporary file "c:\Users\dad\Documents\Visual > Studio 2008\Projects\example\example\Debug\RSP00001227165100.rsp" with > contents > [ > /Od /I "C:\Program Files\boost\boost_1_34_1" /D "WIN32" /D "_DEBUG" /D > "_UNICODE" /D "UNICODE" /FD /EHa /MDd /Fo"Debug\\" /Fd"Debug\vc90.pdb" /W3 > /c /Zi /clr /TP /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll" /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Data.dll" /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.XML.dll"
> ".\example.cpp"
> ".\AssemblyInfo.cpp" > ] > Creating command line "cl.exe @"c:\Users\dad\Documents\Visual Studio > 2008\Projects\example\example\Debug\RSP00001227165100.rsp" /nologo > /errorReport:prompt" > Creating temporary file "c:\Users\dad\Documents\Visual Studio > 2008\Projects\example\example\Debug\RSP00001327165100.rsp" with contents > [ > /Od /I "C:\Program Files\boost\boost_1_34_1" /D "WIN32" /D "_DEBUG" /D > "_UNICODE" /D "UNICODE" /FD /EHa /MDd /Yc"stdafx.h" /Fp"Debug\example.pch" > /Fo"Debug\\" /Fd"Debug\vc90.pdb" /W3 /c /Zi /clr /TP /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll" /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.Data.dll" /FU > "c:\Windows\Microsoft.NET\Framework\v2.0.50727\System.XML.dll"
> ".\stdafx.cpp" > ] > Creating command line "cl.exe @"c:\Users\dad\Documents\Visual Studio > 2008\Projects\example\example\Debug\RSP00001327165100.rsp" /nologo > /errorReport:prompt" > Creating command line "rc.exe /d "_UNICODE" /d "UNICODE" > /fo"Debug/app.res" ".\app.rc"" > Creating temporary file "c:\Users\dad\Documents\Visual Studio > 2008\Projects\example\example\Debug\RSP00001427165100.rsp" with contents > [ > /OUT:"C:\Users\dad\Documents\Visual Studio > 2008\Projects\example\Debug\example.exe" /INCREMENTAL /LIBPATH:"C:\Program > Files\boost\boost_1_34_1\lib" /LIBPATH:"C:\Program > Files\boost\boost_1_34_1\lib\\" /MANIFEST > /MANIFESTFILE:"Debug\example.exe.intermediate.manifest" > /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /ASSEMBLYDEBUG > /PDB:"C:\Users\dad\Documents\Visual Studio > 2008\Projects\example\Debug\example.pdb" /DYNAMICBASE /FIXED:No /NXCOMPAT > /MACHINE:X86 ".\Debug\AssemblyInfo.obj"
> ".\Debug\example.obj"
> ".\Debug\stdafx.obj"
> ".\Debug\app.res" > ] > Creating command line "link.exe @"c:\Users\dad\Documents\Visual Studio > 2008\Projects\example\example\Debug\RSP00001427165100.rsp" /NOLOGO > /ERRORREPORT:PROMPT" > Output Window Compiling... > stdafx.cpp > Compiling... > example.cpp > Unknown compiler version - please run the configure tests and report the > results > AssemblyInfo.cpp > Generating Code... > Compiling resources... > Microsoft (R) Windows (R) Resource Compiler Version 6.0.5724.0 > Copyright (C) Microsoft Corporation. All rights reserved. > Linking... > libboost_regex-vc80-mt-gd-1_34_1.lib(usinstances.obj) : error LNK2019: > unresolved external symbol "__declspec(dllimport) public: void __thiscall > std::_Container_base::_Orphan_all(void)const " > (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ) referenced in function > "public: class std::vector,class std::allocator > > & __thiscall > std::vector,class std::allocator > >::operator=(class std::vector,class > std::allocator > > const &)" > (??4?$vector@U?$sub_match@PBG@boost@@V?$allocator@U?$sub_match@PBG@boost@@@ std@@@std@@QAEAAV01@ABV01@@Z) > libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2001: > unresolved external symbol "__declspec(dllimport) public: void __thiscall > std::_Container_base::_Orphan_all(void)const " > (__imp_?_Orphan_all@_Container_base@std@@QBEXXZ) > libboost_regex-vc80-mt-gd-1_34_1.lib(usinstances.obj) : error LNK2019: > unresolved external symbol "__declspec(dllimport) public: __thiscall > std::_Container_base::~_Container_base(void)" > (__imp_??1_Container_base@std@@QAE@XZ) referenced in function "public: > __thiscall std::_Vector_val,class std::allocator > >::~_Vector_val,class > std::allocator > >(void)" > (??1?$_Vector_val@U?$sub_match@PBG@boost@@V?$allocator@U?$sub_match@PBG@boo st@@@std@@@std@@QAE@XZ) > libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2001: > unresolved external symbol "__declspec(dllimport) public: __thiscall > std::_Container_base::~_Container_base(void)" > (__imp_??1_Container_base@std@@QAE@XZ) > libboost_regex-vc80-mt-gd-1_34_1.lib(usinstances.obj) : error LNK2019: > unresolved external symbol "__declspec(dllimport) public: __thiscall > std::_Container_base::_Container_base(void)" > (__imp_??0_Container_base@std@@QAE@XZ) referenced in function "protected: > __thiscall std::_Vector_val,class std::allocator > >::_Vector_val,class > std::allocator > >(class std::allocator >)" > (??0?$_Vector_val@U?$sub_match@PBG@boost@@V?$allocator@U?$sub_match@PBG@boo st@@@std@@@std@@IAE@V?$allocator@U?$sub_match@PBG@boost@@@1@@Z) > libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2001: > unresolved external symbol "__declspec(dllimport) public: __thiscall > std::_Container_base::_Container_base(void)"
...
read more »
You must
Sign in before you can post messages.
You do not have the permission required to post.
From:
"David R. Palmer" <dpal... @davidrpalmer.com>
Date: Sat, 26 Jan 2008 19:49:37 -0500
Local: Sat, Jan 26 2008 7:49 pm
Subject: Re: [Boost-users] libXXX
Note Kevlar, you are trying to link against version 8 lib's "Linking... libboost_regex-*vc80*-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: "
Download and replace auto_link.hpp (most likely found here) C:\Program Files\boost\boost_1_34_1\boost\config with the one from http://svn.boost.org/trac/boost/browser/trunk/boost/config/auto_link.hpp
Also your user-config.jam file if you want to rebuild all the libraries needs these lines;
# MSVC configuration using msvc : 9.0 : "C:/Program Files/Microsoft Visual Studio 9.0/VC/bin/cl.exe" ; # C:\Program Files\Microsoft Visual Studio 9.0\VC\bin
This file needs to be in the user default directory in Vista. So the Kevlar directory, if that is your Vista Log In name.
Also if you read this post, it will also list a couple other fixes I made, thanks to Greorgy Jikia, about half way down the post. http://www.nabble.com/Preliminary-0.9.0-tarballs---VC%2B%2B-2008-Expr...
Dave
Kevlar wrote:
> I'm also having the same problem after installing from the BoostPro Installer
> with VC9.
> Just going off the basic example, my program is:
> #include "stdafx.h" > #include <boost/regex.hpp> > #include <iostream> > #include <string>
> using namespace std;
> #ifdef WIN32 > int _tmain(int argc, _TCHAR* argv[]) > #else > int main() > #endif > { > std::string line; > boost::regex pat( "^Subject: (Re: |Aw: )*(.*)" );
> while (std::cin) > { > std::getline(std::cin, line); > boost::smatch matches; > if (boost::regex_match(line, matches, pat)) > std::cout << matches[2] << std::endl; > } > }
> And I'm getting: > Linking... > libboost_regex-vc80-mt-gd-1_34_1.lib(instances.obj) : error LNK2019:
_______________________________________________ Boost-users mailing list Boost-us... @lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
You must
Sign in before you can post messages.
You do not have the permission required to post.
From:
Kevlar <ts... @verse-studios.com>
Date: Sun, 27 Jan 2008 08:04:46 -0800 (PST)
Local: Sun, Jan 27 2008 11:04 am
Subject: Re: [Boost-users] libXXX
Thanks, that did the trick. Now when people google the error, they will come accross this thread with the solution (like I did).
Of course after changing the auto_link to point at the vc90 libs, it was necessary to recompile them all, but that was possible after the change to the user_config.
David Randolph Palmer wrote:
> Note Kevlar, you are trying to link against version 8 lib's
> "Linking... > libboost_regex-*vc80*-mt-gd-1_34_1.lib(instances.obj) : error LNK2019: "
> Download and replace auto_link.hpp (most likely found here) C:\Program > Files\boost\boost_1_34_1\boost\config with the one from > http://svn.boost.org/trac/boost/browser/trunk/boost/config/auto_link.hpp
> *snip*
-- View this message in context: http://www.nabble.com/libXXX-tp14734770p15120578.html Sent from the Boost - Users mailing list archive at Nabble.com. _______________________________________________ Boost-users mailing list Boost-us... @lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
You must
Sign in before you can post messages.
You do not have the permission required to post.