[antlr-interest] DLL under MSVC

Ney, Richard richard.ney at aspect.com
Mon Feb 9 22:53:13 PST 2004


Jorg,

Don't know if anyone answered your question. Make sure you have both

ANTLR_EXPORTS
ANTLR_CXX_SUPPORTS_NAMESPACE

In your preprocessor defines. For the application that is linking in the library make sure you have 

ANTLR_IMPORTS 

In the preprocessor defines. For MS specific solutions I normally make the import the default and place the export in the precompiled header but I assume Ric didn't do this due to the specifics of other compilers.

-Richard

-----Original Message-----
From: Jörg Werner [mailto:joerg+computer.antlr at bodensee.pi5.physik.uni-stuttgart.de] 
Sent: Saturday, February 07, 2004 3:22 PM
To: antlr-interest at yahoogroups.com
Subject: [antlr-interest] DLL under MSVC

Hi!

I'm trying to compile antlr-2.7.3rc2 as a dll using MSVC 7.1. When trying
to link my project with the dll i get the following error:

unresolved external symbol '"__declspec(dllimport) public: class
antlr::ASTRefCount<class antlr::AST> & __thiscall antlr::ASTRefCount<class
antlr::AST>::operator=(class antlr::AST *)"
(__imp_??4?$ASTRefCount at VAST@antlr@@@antlr@@QAEAAV01 at PAVAST@1@@Z)',
verwiesen in Funktion '"public: void __thiscall
MatlabWalker::patternExecuteStatement(class antlr::ASTRefCount<class
antlr::AST>)"
(?patternExecuteStatement at MatlabWalker@@QAEXV?$ASTRefCount at VAST@antlr@@@antlr@@@Z)'

Linking with a statically linked antlr-lib works.
Can anyone help me getting rid of this error?

Jörg

-- 

Jörg Werner
j.werner at physik.uni-stuttgart.de




-- 



 
Yahoo! Groups Links



 



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/antlr-interest/

<*> To unsubscribe from this group, send an email to:
     antlr-interest-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
     http://docs.yahoo.com/info/terms/
 



More information about the antlr-interest mailing list