This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Merge GNU Classpath (libgcj-snapshot-20090102) to trunk


2009/1/6 Andrew John Hughes <gnu_andrew@member.fsf.org>:
> 2009/1/6 Tom Tromey <tromey@redhat.com>:
>>>>>>> "Andrew" == Andrew John Hughes <gnu_andrew@member.fsf.org> writes:
>>
>> Andrew> This patch updates the version of Classpath on trunk to
>> Andrew> encompass a number of regression fixes recently added to GNU
>> Andrew> Classpath.
>>
>> Andrew> Ok for trunk?
>>
>> Yes, this is ok.
>> Thanks for doing this.
>>
>
> Thanks for reviewing :)
>
>> Andrew>         * java/lang/String.java:
>> Andrew>         (byte[],int,int,String): Call new Charset method.
>> [...]
>>
>> Due to the libgcj override, this changes won't show up.  So, if you
>> want this in the next libgcj, you'll have to apply them to the local
>> String.
>>
>
> Ah yes, thanks for spotting.  I'll post a patch to sync String once
> the merge is committed.
>
>> Tom
>>
>
> --
> Andrew :-)
>
> Support Free Java!
> Contribute to GNU Classpath and the OpenJDK
> http://www.gnu.org/software/classpath
> http://openjdk.java.net
>
> PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
> Fingerprint: F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8
>


I've implemented the two new methods in libjava/java/lang/String.java
and natString.cc.  The structure of String.java seems to suggest that
pretty much everything of any worth is native in GCJ's String
implementation, so I ported the implementation of the
String(byte[],int.int,java.nio.charset.Charset) over to CNI using the
existing CNI constructors as a base.

However, it seems bringing NIO into String causes some build issues.
A number of NIO classes are in standard.omit.in:

gnu/java/nio/charset/iconv
java/util/zip/DeflaterConstants.java
java/util/zip/DeflaterEngine.java
java/util/zip/DeflaterHuffman.java
java/util/zip/DeflaterPending.java
java/util/zip/InflaterDynHeader.java
java/util/zip/InflaterHuffmanTree.java
java/util/zip/OutputWindow.java
java/util/zip/PendingBuffer.java
java/util/zip/StreamManipulator.java
gnu/java/nio/NIOSocketImpl.java
gnu/java/nio/KqueueSelectorImpl.java
gnu/java/nio/EpollSelectorImpl.java
gnu/java/nio/FileChannelImpl.java
gnu/java/nio/KqueueSelectionKeyImpl.java
gnu/java/nio/EpollSelectionKeyImpl.java

Because java.lang.String now uses Charset, CharsetDecoder, CharBuffer
and ByteBuffer, it seems to be dragging in most of these excluded
classes and failing as a result:

libtool: compile:  /home/andrew/builder/gcj/gcc/gcj
-B/home/andrew/builder/gcj/x86_64-unknown-linux-gnu/libjava/ -B/home\
/andrew/builder/gcj/gcc/ -fomit-frame-pointer -fclasspath=
-fbootclasspath=/home/andrew/projects/classpath/gcj/sources/g\
cc/libjava/classpath/lib --encoding=UTF-8 -Wno-deprecated
-fbootstrap-classes -g -O2 -c -fsource-filename=/home/andrew/b\
uilder/gcj/x86_64-unknown-linux-gnu/libjava/classpath/lib/classes -MT
gnu/java/net/protocol/jar.lo -MD -MP -MF gnu/java/\
net/protocol/jar.deps @gnu/java/net/protocol/jar.list  -fPIC -o
gnu/java/net/protocol/.libs/jar.o
libtool: compile:  /home/andrew/builder/gcj/gcc/gcj
-B/home/andrew/builder/gcj/x86_64-unknown-linux-gnu/libjava/ -B/home\
/andrew/builder/gcj/gcc/ -fomit-frame-pointer -fclasspath=
-fbootclasspath=/home/andrew/projects/classpath/gcj/sources/g\
cc/libjava/classpath/lib --encoding=UTF-8 -Wno-deprecated
-fbootstrap-classes -g -O2 -c -fsource-filename=/home/andrew/b\
uilder/gcj/x86_64-unknown-linux-gnu/libjava/classpath/lib/classes -MT
gnu/java/nio.lo -MD -MP -MF gnu/java/nio.deps @gnu\
/java/nio.list  -fPIC -o gnu/java/.libs/nio.o
gnu/java/nio/EpollSelectionKeyImpl.java: In class
'gnu.java.nio.EpollSelectionKeyImpl':
gnu/java/nio/EpollSelectionKeyImpl.java: In method
'gnu.java.nio.EpollSelectionKeyImpl.interestOps(int)':
In file included from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/gnu/java/nio/DatagramChannelSelectionKey.j\
ava:57,
                 from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/gnu/java/nio/DatagramChannelImpl.java:300,
                 from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/classpath/gnu/java/nio/ChannelWriter.java:\
189,
                 from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/classpath/gnu/java/nio/ChannelReader.java:\
215,
                 from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/classpath/gnu/java/nio/ChannelOutputStream\
.java:66,
                 from
/home/andrew/projects/classpath/gcj/sources/gcc/libjava/classpath/gnu/java/nio/ChannelInputStream.\
java:90,
                 from <built-in>:64:
gnu/java/nio/EpollSelectionKeyImpl.java:97: error: cannot find file
for class gnu.java.nio.EpollSelectorImpl
gnu/java/nio/EpollSelectionKeyImpl.java:97: error: class
'gnu.java.nio.EpollSelectorImpl' has no method named 'epoll_mod\
ify' matching signature '(Lgnu/java/nio/EpollSelectionKeyImpl;I)V'
gnu/java/nio/EpollSelectionKeyImpl.java: In method
'gnu.java.nio.EpollSelectionKeyImpl.selector()':
gnu/java/nio/EpollSelectionKeyImpl.java:120: error: cannot find file
for class gnu.java.nio.EpollSelectorImpl
gnu/java/nio/EpollSelectionKeyImpl.java:120: internal compiler error:
vector VEC(tree,base) index domain error, in class\
_depth at java/class.c:576
Please submit a full bug report,

The above list suggests we shouldn't have compiled these classes, yet
class files (but no headers) are present in the source tree now.
Any ideas?
-- 
Andrew :-)

Support Free Java!
Contribute to GNU Classpath and the OpenJDK
http://www.gnu.org/software/classpath
http://openjdk.java.net

PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint: F8EF F1EA 401E 2E60 15FA  7927 142C 2591 94EF D9D8


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]