Using regex with Visual Studio. NET 2003
Hi,
I am porting a project that uses regex from Visual Studio 6 to Visual
Studio .NET 2003. It works fine with VS6, but now I am getting linker
errors:
TestConsole.obj : error LNK2019: unresolved external symbol
"__declspec(dllimport) public: __thiscall boost::reg_expression ::~reg_expression I have changed the C-runtime library settings, I have set
BOOST_REGEX_STATIC_LINK to make sure I link against the static version, but
nothing worked. Looking at the error messages, it seems I am still linking
against the DLL version (dllimport).
Does anybody have regex working with .NET 2003?
Thanks
Hans Merkl
On Tue, 2004-01-06 at 14:35, Hans Merkl wrote: Hi
I am porting a project that uses regex from Visual Studio 6 to Visual Studio .NET 2003. It works fine with VS6, but now I am getting linker errors:
(snip)
I have changed the C-runtime library settings, I have set BOOST_REGEX_STATIC_LINK to make sure I link against the static version, but nothing worked. Looking at the error messages, it seems I am still linking against the DLL version (dllimport).
Does anybody have regex working with .NET 2003?
We've had it working for some time. In fact we didn't have any sort of problem with MSVC 7.1 (.Net 2003) and the regex, python or threading libraries. Are you linking against the libraries built with MSVC 6.0 or have you regenerated them with MSVC 7.1? We have had problems in the past linking MSVC 6.0 static libraries with MSVC 7.0. -- Regards Paul Paul Grenyer Email: paul@paulgrenyer.co.uk Web: http://www.paulgrenyer.co.uk Have you met Aeryn: http://www.paulgrenyer.co.uk/aeryn/?
Paul, Thanks for confirming that it's possible. This project is rather big, so it's likely that something else is causing the problem. Hans On Tue, 06 Jan 2004 18:33:43 +0000, Paul Grenyer wrote:
On Tue, 2004-01-06 at 14:35, Hans Merkl wrote:
Hi
I am porting a project that uses regex from Visual Studio 6 to Visual Studio .NET 2003. It works fine with VS6, but now I am getting linker errors:
(snip)
I have changed the C-runtime library settings, I have set BOOST_REGEX_STATIC_LINK to make sure I link against the static version, but nothing worked. Looking at the error messages, it seems I am still linking against the DLL version (dllimport).
Does anybody have regex working with .NET 2003?
We've had it working for some time. In fact we didn't have any sort of problem with MSVC 7.1 (.Net 2003) and the regex, python or threading libraries.
Are you linking against the libraries built with MSVC 6.0 or have you regenerated them with MSVC 7.1? We have had problems in the past linking MSVC 6.0 static libraries with MSVC 7.0.
I am porting a project that uses regex from Visual Studio 6 to Visual Studio .NET 2003. It works fine with VS6, but now I am getting linker errors:
TestConsole.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: __thiscall boost::reg_expression
I have changed the C-runtime library settings, I have set BOOST_REGEX_STATIC_LINK to make sure I link against the static version, but nothing worked. Looking at the error messages, it seems I am still linking against the DLL version (dllimport).
How did you set the define? It should be set in the project settings -> C++ -> preprocessor options section. Other obvious things to double check: You rebuilt the library with vc7.1 right? And are the libraries in your lib search path ?
Does anybody have regex working with .NET 2003?
Yes thanks, it what boost.regex is primarily developed in :-) John
participants (3)
-
Hans Merkl
-
John Maddock
-
Paul Grenyer