[antlr-interest] build problem with antlr-2.7.5

Krishanu Debnath krishanu.debnath at gmail.com
Wed Feb 9 04:01:14 PST 2005


Hello,

I am getting the following errors during build of antlr-2.7.5 .

krishanu at meghna[199] configure --prefix=/u/krishanu/my_local/antlr_275/
...

krishanu at meghna[194] make
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>> make -C ./antlr install
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
make[1]: Entering directory `/u/krishanu/ANTLR/antlr-2.7.5/antlr'
/bin/sh /u/krishanu/ANTLR/antlr-2.7.5/scripts/antlr.sh
/u/krishanu/ANTLR/antlr-2.7.5/antlr/../antlr/antlr.g
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Unable to compile ANTLR grammar file(s)
 /u/krishanu/ANTLR/antlr-2.7.5/antlr/../antlr/antlr.g
Reason(s):
 (a) there's no /u/krishanu/ANTLR/antlr-2.7.5/antlr/antlr.jar
 (b) there's no /u/krishanu/ANTLR/antlr-2.7.5/antlr.jar
 (c) there's no /u/krishanu/ANTLR/antlr-2.7.5/lib/antlr.jar
 (d) options --with-antlr-jar --with-antlr-cmd not applied
     or value given is not correct.                                   
         You may resolve this problem by setting environment variable
$ANTLR_JAR.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
make[1]: *** [ANTLRParser.java] Error 1
make[1]: Leaving directory `/u/krishanu/ANTLR/antlr-2.7.5/antlr'
make: *** [install] Error 1
krishanu at meghna[195] pwd
/u/krishanu/ANTLR/antlr-2.7.5

I noticed that antlr.jar is used to there in earlier releases, atleast
in 2.7.4.I use antlr for C++ code generation. So in earlier i used to
build libantlr.a and use antlr in the following
way.


java -cp "/u/krishanu/ANTLR/antlr-2.7.4/antlr.jar" antlr.Tool lexer.g
java -cp "/u/krishanu/ANTLR/antlr-2.7.4/antlr.jar" antlr.Tool parser.g
gcc -c -g -I. -I$ANTLR_HOME/lib/cpp -Wall myLexer.cpp
gcc -c -g -I. -I$ANTLR_HOME/lib/cpp -Wall myParser.cpp
gcc -c -g -I. -I$ANTLR_HOME/lib/cpp -Wall main.cpp
gcc main.o myLexer.o myParser.o $ANTLR_HOME/lib/cpp/src/libantlr.a -lstdc++

Am I missing something? (My java knowledge is frustratingly poor)


Thanks
Krishanu

-- 
"When I have to rely on inadequacy, I prefer it to be my own."
--Richard Heathfield


More information about the antlr-interest mailing list