1 Installing GNU Classpath - Last updated: September 7, 2005
3 First, this is a development release only! Unless you are interested in
4 active development and debugging, or just like running random alpha code,
5 this release is probably not for you. Please see the README file for a
6 list of VMs that work with GNU Classpath.
8 Note that if you are building from a non-released (CVS) version of GNU
9 classpath, installation instructions are found in the doc/hacking.texi
10 file. Or at http://www.gnu.org/software/classpath/docs/hacking.html
12 ------------------------------------------------------------------
14 ------------------------------------------------------------------
15 GNU make ("gmake") is required for building Classpath.
17 For any build environment involving native libraries, these
18 new versions of autoconf, automake, and libtool are required
19 if changes are made that require rebuilding configure, Makefile.in,
20 aclocal.m4, or config.h.in.
26 When working from CVS you can run the above tools by executing
27 ./autogen.sh in the source directory.
29 For building the Java bytecode (.class files), one of these
30 compilers are required. You can select which compiler using
31 --with-jikes, --with-gcj, --with-ecj or --with-kjc as argument to
32 configure; the present default is gcj.
34 - GCJ 4.0+ (part of the GNU GCC package).
36 - Eclipse Compiler for Java 3.1+
37 - The kjc compiler is supported with configure but we have
38 been unable to successfully compile with it.
40 IMPORTANT: Versions of GCJ which are earlier than 4.0 contain
41 bugs which make it impossible to compile the class library and
42 are *not* supported any more. If you are stuck on a system where
43 GCC 3.x is the system compiler we recommend using Jikes.
45 For building the gtk+ AWT peer JNI native libraries, the following
46 are required unless --disable-gtk-peer is used as an argument to
49 - GTK+ 2.4.x (or higher)
52 - XTest Extension (libXtst) for GdkRobot support in java.awt.
54 For building the Cairo GdkGraphics2D backend you need at least
57 For building the Qt AWT peer JNI native libraries you have to
58 specify --enable-qt-peer and need the following library:
62 Please note that at the moment most operating systems do not
63 ship Qt4 by default. We recommend using GNU Classpath' Qt4
64 support only for its developers and bug reporters. See
65 http://developer.classpath.org/mediation/ClasspathShowcase
66 for details on how to get it to work.
68 For building the xmlj JAXP implementation (disabled by default, use
69 configure --enable-xmlj) you need the following installed:
70 - The XML C library for Gnome (libxml2)
71 http://www.xmlsoft.org/
72 Minimum version of libxml2 required: 2.6.8
74 - The XSLT C library for Gnome (libxslt)
75 http://www.xmlsoft.org/XSLT/
76 Minimum version of libxslt required: 1.1.11
78 For building the documentation you will need
80 - texinfo 4.2 or higher.
82 For building the ALSA midi provider code you will need
83 ALSA. http://www.alsa-project.org.
85 For building the DSSI midi synthesizer provider code you will
86 need DSSI from http://dssi.sourceforge.net. This, in turn,
87 introduces many dependencies, including:
89 - liblo: the Lightweight OSC implementation
90 http://plugin.org.uk/liblo/
92 - LADSPA: Linux Audio Developer's Simple Plugin API
95 - the JACK Audio Connection Kit: A low latency audio server
96 http://jackit.sourceforge.net
98 - libsndfile: an audio file I/O library
99 http://www.mega-nerd.com/libsndfile/
101 - fluidsynth: a real-time SoundFont 2 based soft-synth
102 http://www.fluidsynth.org/
105 This package was designed to use the GNU standard for configuration
106 and makefiles. To build and install do the following:
108 1). Run the "configure" script to configure the package. There are
109 various options you might want to pass to configure to control how the
110 package is built. Consider the following options, "configure --help"
111 gives a complete list.
113 --enable-java compile Java source default=yes
114 --enable-jni compile JNI source default=yes
115 --enable-gtk-peer compile GTK native peers default=yes
116 --enable-gtk-cairo compile cairo based Graphics2D default=no
117 --enable-qt-peer compile Qt4 native peers default=no
118 --enable-default-toolkit
119 fully qualified class name of default AWT toolkit
121 --enable-xmlj compile native libxml/xslt library default=no
122 --enable-load-library enable to use JNI native methods default=yes
123 --with-jikes to compile the class library using jikes
124 the default is to use gcj
125 --with-glibj define what to install (zip|flat|both|none)
127 --enable-Werror whether to compile C code with -Werror which turns
128 any compiler warning into a compilation failure
130 --with-gjdoc generate documentation using gjdoc default=no
131 --with-jay Regenerate the parsers with jay must be given the
132 path to the jay executable
134 For more flags run configure --help.
136 2). Type "gmake" to build the package. There is no longer a
137 dependency problem and we aim to keep it that way.
139 3). Type "gmake install" to install everything. This may require
140 being the superuser. The default install path is /usr/local/classpath
141 you may change it by giving configure the --prefix=<path> option.
143 Report bugs to classpath@gnu.org or much better via Savannah at this
144 URL: http://savannah.gnu.org/support/?func=addsupport&group=classpath
148 Once installed, GNU Classpath is ready to be used by any VM that supports
149 using the official version of GNU Classpath. Simply ensure that
150 /usr/local/classpath/share/classpath is in your $CLASSPATH environment
151 variable. You'll also have to set your LD_LIBRARY_PATH
152 variable (or similar system configuration) to include the Classpath
153 native libraries in /usr/local/classpath/lib/classpath.
155 *NOTE* All example paths assume the default prefix is used with configure.
156 If you don't know what this means then the examples are correct.
158 LD_LIBRARY_PATH=/usr/local/classpath/lib/classpath
159 CLASSPATH=/usr/local/classpath/share/classpath/glibj.zip:.
160 export LD_LIBRARY_PATH CLASSPATH
162 More information about the VMs that use GNU Classpath can be found in the
165 ------------------------------------------------------------------
167 ------------------------------------------------------------------
168 Compilation is accomplished using a compiler's @file syntax. For our
169 part, we avoid placing make style dependencies as rules upon the
170 compilation of a particular class file and leave this up to the Java
173 The --enable-maintainer-mode option to configure currently does very
174 little and shouldn't be used by ordinary developers or users anyway.
176 On Windows machines, the native libraries do not currently build, but
177 the Java bytecode library will. Gcj trunk is beginning to work under
178 Cygwin. The mingw32 version of jikes cannot follow symbolic links, you
179 must use a cygwin build of jikes to access this limited functionality.