This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: building gcj on OS X (also AWT)
- From: John Gabriele <john3g at bestweb dot net>
- To: java at gcc dot gnu dot org
- Date: Wed, 19 May 2004 21:25:07 -0400
- Subject: Re: building gcj on OS X (also AWT)
- References: <200405192245.i4JMjKb30026@tin.geop.uc.edu>
On May 19, 2004, at 6:45 PM, Andrew Pinski wrote:
I'd like to build gcc 3.4.0 on Mac OS X 10.3.3. In particular,
I want gcj, hopefully with whatever AWT/Swing comes with it,
just so I can write command line and also simple GUI user apps.
I've got a few questions on the build procedure. I've already
downloaded gcc-core and gcc-java 3.4.0 from my local mirror.
I unpacked them in ~/src, and also created a build-directory there
~/src/gcc_build_dir (so I can run the configure and make commands
from there) as the directions
http://gcc.gnu.org/install/configure.html
recommend.
You also need gcc-c++ as the Java compiler depends on the C++
compiler.
Ok. Downloading it now... (on dialup)
So, since I guess I'm building what the directions
refer to as a "native compiler" (?), is it correct that my
procedure should be:
cd ~/src/gcc_build_dir
../gcc-3.4.0/configure --prefix=/usr/local/gcj \
--enable-threads=posix --enable-shared
make CC='cc -no-cpp-precomp' bootstrap
You really do not need to set the CC anymore.
Thanks. I'll give it a try without it.
?
Do I then have to run 'make' with *no* target specified?
(Before running "make install")
no, it is already built.
Check.
Looking at
http://gcc.gnu.org/install/specific.html#powerpc-*-darwin*
it says:
| The default stack limit of 512K is too small, which may cause
| compiles to fail with 'Bus error'. Set the stack larger, for
| instance by doing "limit stack 800".
What does it mean to "limit stack 800" and how would I go about
it? Is that something that gets done with ./configure or at
build-time?
The default stack limit on Panther (10.3) is much bigger than
older versions, this really only applies to the older ones.
Check.
It might be useful (for other new folks getting started with gcj
on OS X) to update that note in
http://gcc.gnu.org/install/specific.html#powerpc-*-darwin*
Also, is GCJ's AWT currently the best option (vs. Swing) to do
a simple GUI? Are there any special ./configure options I need
to use? The instructions
http://gcc.gnu.org/install/configure.html
hint at --with-x and --enable-java-awt=xlib
and although I *do* have Apple's X11 installed, I'm not sure
what to do here. Will gcj's awt use OS X's Quartz by default
if I leave those arguments out?
Will AWT only work with X (and not Quartz)?
Not yet, I have been thinking about adding it but I really do not
have time to add support at this point.
Ok. So, does that mean I should to use --with-x and
--enable-java-awt=xlib when I ./configure?
Is there enough of AWT implemented to do some simple GUI stuff
(like buttons and labels)? I specifically want to be able to
have a button and to be able to draw some pixels (I'm recoding
a very simple raytracer I originally wrote in C++).
Thanks,
Andrew Pinski
a Mac OS X user and a GCC developer
Thanks,
---John