[antlr-interest] Linker error on TOKENSOURCE .. Newbie story continues!

Jim Idle jimi at temporal-wave.com
Thu Jun 19 08:07:34 PDT 2008


On Thu, 2008-06-19 at 12:06 +0200, mimarob at algonet.se wrote:

> Hello again!
> 
> Thank you all for the advice on the 2.7.7 / 3.0.1 antlr issues.
> 
> Now I managed to produce a CParser.c and a CLexer.c.
> 
> Being a C-code generation fanatic I think it looks great!
> 
> Only problem now, I get a linker error on the macro(?) TOKENSOURCE, 
> see below:
> 
> Any idea what is going wrong?
> 
> I have installed libantlr3c-3.0.1


You want to build the 3.1 source to use the TOKENSOURCE macro :-) and
use ANTLR 3.1.

Download the current 3.1 beta, and unzip it into your home directory.

Locate the dist directoory under runtime/C

Untar the tgz that is in there. 
Run ./configure
make
sudo make install

The link with the 3.1 .so library in /usr/local/lib and use
-I /usr/local/include

Then you will be running with the latest C code and headers and the 3.1
stuff will all be in sync.

This is documented more in the C API documentation (look for the API
docs link on the Antlr home page).
Jim

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20080619/81c8bcb8/attachment.html 


More information about the antlr-interest mailing list