summaryrefslogtreecommitdiffstats
path: root/lib/antlr/README
blob: 6ca0913ba4a18cf222ff6e5ec33a4c843a015564 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
C++ support libraries

Original GNU autconf stuff contributed by Braden N. McDaniel. Slightly
hacked up by me (Ric Klaren (klaren@cs.utwente.nl)) for who it's the first
autoconf/automake/aclocal stuff ever, so suggestions additions welcome.

HOW TO INSTALL

In theory do:

./configure --prefix=<basedirectory where you want it installed>
make
make install

Now libantlr.a should reside under <basedir>/lib/libantlr.a and the
includes should be at <basedir>/include/antlr.

NOTE: this only installs the C++ library and header files.

In the contrib directory a dsp/dsw project for Microsoft Visual C++ can be
found.

In general this library needs runtime typing information (RTTI) make sure
you enable this in whatever compiler you are using.

SUPPORTED COMPILERS

Pasted from the FAQ entry on: http://www.jguru.com/jguru/faq/view.jsp?EID=121

Compiler               OS                         Version
------------------     ---------------------      ----------
Sun Workshop 4.2       Solaris 2.6, 7             2.7.1a2
Sun Workshop 5.0       Solaris 2.7                2.7.1a2
Sun Workshop 6.0       Solaris 2.7                2.7.1a2
egcs-1.1.2             Solaris 2.6,7              2.7.1a2
egcs-1.1.2             Linux 2.2, Solaris 2.6     2.7.1a2
gcc-2.95.2             Linux 2.2, Solaris 2.6,7   2.7.1a2
gcc-2.96 (20000527)    Solaris 2.6                2.7.1a2
aCC A.01.21            HP-UX 10.20                2.7.0 no!
Visual C++ 6.0         PC                         2.7.1a2 (warnings)
Intel C++ 4.0          NT 4.0                     2.7.0
Borland 5.0            NT 4.0                     2.7.0

IT DOESN'T WORK!?

Check out the faq: http://www.jguru.com/jguru/faq/view.jsp?EID=120

The text of that entry (by Peter Wells):

The ANTLR code uses some relatively new features of C++ which not all
compilers support yet (such as namespaces, and new style standard headers).

There is work currently in progress to provide a compatibility mode for
ANTLR, to enable older compilers to handle this.

At the moment, you may be able to work around the problem with a few nasty
tricks:

Try creating some header files like 'iostream' just containing:

#include <iostream.h>

and compile with an option to define away the word 'std', such as

CC .... -Dstd= ....

Also in the antlr subdirectory there's a file config.hpp. Tweak this one to
enable/disable the different bells and whistles used in the rest of the code.
Don't forget to submit those changes back to us (along with compiler info)
so we can incorporate them in our next release!

Thanks!