Boost logo

Boost Users :

From: Alan Gray (alan_l_gray_at_[hidden])
Date: 2006-08-11 08:51:11


Maybe using wchar_t as a built in the library but not your project?

>From: "John Maddock" <john_at_[hidden]>
>Reply-To: boost-users_at_[hidden]
>To: <boost-users_at_[hidden]>
>Subject: Re: [Boost-users] [regex]Using regex in x64 exe with VC 8.0
>Date: Fri, 11 Aug 2006 09:47:33 +0100
>
>Bill Buklis wrote:
> > I was able to successfully compile the boost libraries for x64 under
> > VC 8.0 using the following line:
> >
> > bjam "-sTOOLS=vc-8_0-amd64"
> >
> > As far as I can tell everything was successful (see note at end of
> > message). There was, of course, a vast quantity of warnings, but all
> > of the lib files seem to be there.
> >
> > Then I tried creating an app using regex. The test code essentially
> > boils down to this:
> >
> > #include <boost/regex.hpp>
> >
> > bool testregex( const char* StringToMatch )
> > {
> > return( boost::regex_match( StringToMatch, boost::regex("[A-Z]+") )
> > );
> > }
> >
> >
> > It compiles fine, but fails to resolve three regex related functions
> > in the linker. Paraphrasing to make it a little more readable (if you
> > want to see the full text, let me know):
> >
> > basic_regex<char, regex_traits<char,w32_regex_traits<char> >
> > >::do_assign
> >
> > re_detail::perl_matcher<...>::match
> >
> > re_detail::perl_matcher<...>::perl_matcher [constructor]
> >
> >
> > All three of these functions reference boost::w32_regex_traits.
> > Perhaps this is where the problem lies? Should it be w64_regex_traits?
> >
> > Am I missing a define somewhere? Any ideas?
>
>No ideas I'm afraid. There is no w64_regex_traits: the w32_* version is
>intended for all Windows platforms.
>
>Things to try:
>
>1) Make sure you're actually linking to the 64-bit lib's, are the 32-bit
>ones lurking on anywhere on your hard drive and getting picked out instead?
>2) Try defining BOOST_REGEX_NO_LIB when building your test app and adding
>all the regex source files directly to the app's project. If this succeeds
>it indicates that the lib's you're linking against aren't correctly built.
>3) If (2) fails you could try again with BOOST_REGEX_NO_EXTERNAL_TEMPLATES
>defined (the errors all relate to template instantiations that are normally
>placed in the lib file).
>
>Oh and one other suggestion: are you selecting the lib to link against
>manually rather than let the auto-link code select it by any chance? You
>could see errors like that if you link against the regex dll import lib,
>without defining BOOST_REGEX_DYN_LINK so it knows to add
>__declspec(dllimport) to the codes defs (or vices versa: setting that
>define
>then linking against the static link lib).
>
>HTH, John.
>
>_______________________________________________
>Boost-users mailing list
>Boost-users_at_[hidden]
>http://lists.boost.org/mailman/listinfo.cgi/boost-users


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net