This is the mail archive of the
mailing list for the Java project.
Re: cannot build libjava/gnu/gcj/xlib/natClip.cc
- To: Per Bothner <per at bothner dot com>
- Subject: Re: cannot build libjava/gnu/gcj/xlib/natClip.cc
- From: Bryce McKinlay <bryce at albatross dot co dot nz>
- Date: Tue, 02 Jan 2001 14:30:15 +1300
- CC: java-discuss at sources dot redhat dot com
- References: <firstname.lastname@example.org> <3A4FC13C.755758CB@albatross.co.nz> <email@example.com>
Per Bothner wrote:
> > Perhaps we could look at changing it. Then again I'm not really sure what a good alternative is, obviously we cant keep native pointers in Java collections.
> Not directly, however there is a mechanism for native pointers in
> Java objects: The gnu.gcj.RawData class. The purpose of RawData
> is that if you declare a Java field or other variable as being "RawData"
> then it is a native pointer that should be ignored by Java memory
> management. I don't know if this convention actually is supported,
> but that was the intent, and I think it's a useful and simple idea.
RawData works, however actual cases where it is useful dont seem to be all that common. If its our code thats doing the allocating, it is easier to use
_Jv_AllocBytes and disguise the native data in an Object field. If we keep a pointer to something allocated with malloc, the GC will just ignore it anyway (but
it is nicer to use a RawData just to make it obvious that the field shouldn't be touched from Java code).
> > I've heard reports of this problem but havn't been able to reproduce it. What is your exact configure line and build procedure?
> /home/bothner/GNU/egcs/configure --enable-threads=posix --prefix=/home/bothner/GNU/linux --enable-shared --enable-languages=c++,java --disable-new-gxx-abi
> make bootstrap
Hmm. The only difference here is that I don't do a "make bootstrap".
In the top level configure.in, a "libstdcxx_flags" variable is set by cat'ing the contents of libstdc++.INC. This should then get passed down to libjava's
configure as part of the definition of CXX (I guess this is picked up from the config.cache?):
checking for c++... (cached) /home/bryce/cvs/gcc/build/gcc/g++ -B/home/bryce/cvs/gcc/build/gcc/ -nostdinc++ -nostdinc++
-I/home/bryce/cvs/gcc/libstdc++-v3/include -I/home/bryce/cvs/gcc/libstdc++-v3/include/std -I/home/bryce/cvs/gcc/libstdc++-v3/include/c_std
-I/home/bryce/cvs/gcc/build/i686-pc-linux-gnu/libstdc++-v3/libio -I/home/bryce/cvs/gcc/libstdc++-v3/libio -I/home/bryce/cvs/gcc/libstdc++-v3/libmath
-B/home/bryce/gcc/i686-pc-linux-gnu/bin/ -B/home/bryce/gcc/i686-pc-linux-gnu/lib/ -isystem /home/bryce/gcc/i686-pc-linux-gnu/include
checking whether we are using GNU C++... (cached) yes
Can you figure out why this doesnt work for you?
[ bryce ]