Hi All,<br>
I have used kaffe previously to write simple java programs and also
some advanced ones like a text editor based on AWT using the Kaffe VM.<br>
However I have then worked extensively on Sun JDK and I want to incorporate certain features provided there into Kaffe VM.<br>
But I am a newbie here and I dunno from where I should start for
studying the source code for Kaffe.Also please guide me as to how i can
use the CVS system at Kaffe to get access to checkout/checkin source
code<br>
<br>
Thanks for your help and looking forward for an exciting development time ahead<br>
<br>
Regards<br>
Prahalad<br><br><div><span class="gmail_quote">On 11/28/06, <b class="gmail_sendername"><a href="mailto:kaffe-request@kaffe.org">kaffe-request@kaffe.org</a></b> <<a href="mailto:kaffe-request@kaffe.org">kaffe-request@kaffe.org
</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Send kaffe mailing list submissions to<br> <a href="mailto:kaffe@kaffe.org">
kaffe@kaffe.org</a><br><br>To subscribe or unsubscribe via the World Wide Web, visit<br> <a href="http://kaffe.org/cgi-bin/mailman/listinfo/kaffe">http://kaffe.org/cgi-bin/mailman/listinfo/kaffe</a><br>or, via email, send a message with subject or body 'help' to
<br> <a href="mailto:kaffe-request@kaffe.org">kaffe-request@kaffe.org</a><br><br>You can reach the person managing the list at<br> <a href="mailto:kaffe-owner@kaffe.org">kaffe-owner@kaffe.org</a><br><br>When replying, please edit your Subject line so it is more specific
<br>than "Re: Contents of kaffe digest..."<br><br><br>Today's Topics:<br><br> 1. Re: Kaffe Project Status (pietro ferrari)<br> 2. Re: Kaffe Project Status (Dalibor Topic)<br> 3. CVS kaffe (robilad): fixed the build on mac os x
10.4.8<br> (Kaffe CVS)<br><br><br>----------------------------------------------------------------------<br><br>Message: 1<br>Date: Mon, 27 Nov 2006 16:54:56 -0200<br>From: "pietro ferrari" <<a href="mailto:pietro.ferrari@gmail.com">
pietro.ferrari@gmail.com</a>><br>Subject: Re: [kaffe] Kaffe Project Status<br>To: <a href="mailto:kaffe@kaffe.org">kaffe@kaffe.org</a><br>Message-ID:<br> <<a href="mailto:6eb9e8610611271054t789c4cf0n16b203d016b912ed@mail.gmail.com">
6eb9e8610611271054t789c4cf0n16b203d016b912ed@mail.gmail.com</a>><br>Content-Type: text/plain; charset=UTF-8; format=flowed<br><br>i'm just another kaffe user lurking around, but i'd like to ask if we<br>can get another kaffe release when classpath
0.93 comes out and is<br>synched?<br><br>pietro.<br><br><br><br>------------------------------<br><br>Message: 2<br>Date: Mon, 27 Nov 2006 21:46:27 +0100<br>From: Dalibor Topic <<a href="mailto:robilad@kaffe.org">robilad@kaffe.org
</a>><br>Subject: Re: [kaffe] Kaffe Project Status<br>To: pietro ferrari <<a href="mailto:pietro.ferrari@gmail.com">pietro.ferrari@gmail.com</a>><br>Cc: <a href="mailto:kaffe@kaffe.org">kaffe@kaffe.org</a><br>Message-ID: <
<a href="mailto:456B4EA3.7030807@kaffe.org">456B4EA3.7030807@kaffe.org</a>><br>Content-Type: text/plain; charset=UTF-8; format=flowed<br><br>pietro ferrari wrote:<br><br>> i'm just another kaffe user lurking around, but i'd like to ask if we
<br>> can get another kaffe release when classpath 0.93 comes out and is<br>> synched?<br><br>Ciao pietro,<br><br>that's the plan. :)<br><br>cheers,<br>dalibor topic<br><br><br><br>------------------------------<br>
<br>Message: 3<br>Date: Mon, 27 Nov 2006 13:48:21 -0800<br>From: Kaffe CVS <<a href="mailto:cvs-commits@kaffe.org">cvs-commits@kaffe.org</a>><br>Subject: [kaffe] CVS kaffe (robilad): fixed the build on mac os x<br>
10.4.8<br>To: <a href="mailto:kaffe@kaffe.org">kaffe@kaffe.org</a><br>Message-ID: <<a href="mailto:E1GooKr-0006Iq-00@pogo.kaffe.org">E1GooKr-0006Iq-00@pogo.kaffe.org</a>><br><br>PatchSet 7451<br>Date: 2006/11/27 21:47:20
<br>Author: robilad<br>Branch: HEAD<br>Tag: (none)<br>Log:<br>fixed the build on mac os x 10.4.8<br><br>2006-11-27 Dalibor Topic <<a href="mailto:robilad@kaffe.org">robilad@kaffe.org</a>><br><br> Fixed the build on Mac OS X
10.4.8.<br> Reported by: Jim Pick <<a href="mailto:jim@kaffe.org">jim@kaffe.org</a>><br><br> * libraries/clib/io/File.c: Renamed to<br> * libraries/clib/io/java_io_File.c: this one.<br><br> * libraries/clib/native/Object.c: Renamed to
<br> * libraries/clib/native/java_lang_Object.c: this one.<br><br> * libraries/clib/native/String.c: Renamed to<br> * libraries/clib/native/java_lang_String.c: this one.<br><br> * libraries/clib/native/Thread.c: Renamed to
<br> * libraries/clib/native/java_lang_Thread.c: this one.<br><br> * kaffe/kaffevm/Makefile.am: Updated to use the new names.<br><br>Members:<br> ChangeLog:1.4951->1.4952<br> kaffe/kaffevm/Makefile.am:
1.95->1.96<br> kaffe/kaffevm/Makefile.in:1.255->1.256<br> libraries/clib/io/File.c:1.28->1.29(DEAD)<br> libraries/clib/io/java_io_File.c:INITIAL->1.1<br> libraries/clib/native/Object.c:
1.20->1.21(DEAD)<br> libraries/clib/native/String.c:1.21->1.22(DEAD)<br> libraries/clib/native/Thread.c:1.26->1.27(DEAD)<br> libraries/clib/native/java_lang_Object.c:INITIAL->1.1<br> libraries/clib/native/java_lang_String.c:INITIAL->
1.1<br> libraries/clib/native/java_lang_Thread.c:INITIAL->1.1<br><br>Index: kaffe/ChangeLog<br>diff -u kaffe/ChangeLog:1.4951 kaffe/ChangeLog:1.4952<br>--- kaffe/ChangeLog:1.4951 Sun Nov 19 21:32:12 2006<br>
+++ kaffe/ChangeLog Mon Nov 27 21:47:20 2006<br>@@ -1,3 +1,22 @@<br>+2006-11-27 Dalibor Topic <<a href="mailto:robilad@kaffe.org">robilad@kaffe.org</a>><br>+<br>+ Fixed the build on Mac OS X 10.4.8.<br>+ Reported by: Jim Pick <
<a href="mailto:jim@kaffe.org">jim@kaffe.org</a>><br>+<br>+ * libraries/clib/io/File.c: Renamed to<br>+ * libraries/clib/io/java_io_File.c: this one.<br>+<br>+ * libraries/clib/native/Object.c: Renamed to
<br>+ * libraries/clib/native/java_lang_Object.c: this one.<br>+<br>+ * libraries/clib/native/String.c: Renamed to<br>+ * libraries/clib/native/java_lang_String.c: this one.<br>+<br>+ * libraries/clib/native/Thread.c: Renamed to
<br>+ * libraries/clib/native/java_lang_Thread.c: this one.<br>+<br>+ * kaffe/kaffevm/Makefile.am: Updated to use the new names.<br>+<br> 2006-11-19 Guilhem Lavaux <<a href="mailto:guilhem@kaffe.org">guilhem@kaffe.org
</a>>,<br> Riccardo Mottola <<a href="mailto:riccardo@kaffe.org">riccardo@kaffe.org</a>><br><br>Index: kaffe/kaffe/kaffevm/Makefile.am<br>diff -u kaffe/kaffe/kaffevm/Makefile.am:1.95 kaffe/kaffe/kaffevm/Makefile.am:
1.96<br>--- kaffe/kaffe/kaffevm/Makefile.am:1.95 Sun Sep 24 18:21:12 2006<br>+++ kaffe/kaffe/kaffevm/Makefile.am Mon Nov 27 21:47:20 2006<br>@@ -135,7 +135,7 @@<br> $(top_srcdir)/libraries/clib/net/NetworkInterface.c \
<br> $(top_srcdir)/libraries/clib/net/PlainDatagramSocketImpl.c \<br> $(top_srcdir)/libraries/clib/net/PlainSocketImpl.c \<br>- $(top_srcdir)/libraries/clib/io/File.c \<br>+ $(top_srcdir)/libraries/clib/io/java_io_File.c \
<br> $(top_srcdir)/libraries/clib/io/java_io_VMFile.c \<br> $(top_srcdir)/libraries/clib/native/AccessController.c \<br> $(top_srcdir)/libraries/clib/native/java_lang_ref_Reference.c \<br>@@ -146,12 +146,12 @@
<br> $(top_srcdir)/libraries/clib/native/TimeZone.c \<br> $(top_srcdir)/libraries/clib/native/Class.c \<br> $(top_srcdir)/libraries/clib/native/ClassLoader.c \<br>- $(top_srcdir)/libraries/clib/native/Object.c \
<br>+ $(top_srcdir)/libraries/clib/native/java_lang_Object.c \<br> $(top_srcdir)/libraries/clib/native/Runtime.c \<br> $(top_srcdir)/libraries/clib/native/VMRuntime.c \<br>- $(top_srcdir)/libraries/clib/native/String.c \
<br>+ $(top_srcdir)/libraries/clib/native/java_lang_String.c \<br> $(top_srcdir)/libraries/clib/native/System.c \<br>- $(top_srcdir)/libraries/clib/native/Thread.c \<br>+ $(top_srcdir)/libraries/clib/native/java_lang_Thread.c \
<br> $(top_srcdir)/libraries/clib/native/Throwable.c \<br> $(top_srcdir)/libraries/clib/native/gnu_classpath_VMStackWalker.c \<br> $(top_srcdir)/libraries/clib/native/gnu_classpath_VMSystemProperties.c \
<br>Index: kaffe/kaffe/kaffevm/Makefile.in<br>diff -u kaffe/kaffe/kaffevm/Makefile.in:1.255 kaffe/kaffe/kaffevm/Makefile.in:1.256<br>--- kaffe/kaffe/kaffevm/Makefile.in:1.255 Tue Nov 7 03:37:35 2006<br>+++ kaffe/kaffe/kaffevm/Makefile.in Mon Nov 27 21:47:20 2006
<br>@@ -118,7 +118,7 @@<br> libkaffevm_la-InetAddressImpl.lo \<br> libkaffevm_la-NetworkInterface.lo \<br> libkaffevm_la-PlainDatagramSocketImpl.lo \<br>- libkaffevm_la-PlainSocketImpl.lo libkaffevm_la-
File.lo \<br>+ libkaffevm_la-PlainSocketImpl.lo libkaffevm_la-java_io_File.lo \<br> libkaffevm_la-java_io_VMFile.lo \<br> libkaffevm_la-AccessController.lo \<br> libkaffevm_la-java_lang_ref_Reference.lo \
<br>@@ -126,9 +126,9 @@<br> libkaffevm_la-Constructor.lo libkaffevm_la-Field.lo \<br> libkaffevm_la-Method.lo libkaffevm_la-TimeZone.lo \<br> libkaffevm_la-Class.lo libkaffevm_la-ClassLoader.lo \<br>- libkaffevm_la-
Object.lo libkaffevm_la-Runtime.lo \<br>- libkaffevm_la-VMRuntime.lo libkaffevm_la-String.lo \<br>- libkaffevm_la-System.lo libkaffevm_la-Thread.lo \<br>+ libkaffevm_la-java_lang_Object.lo libkaffevm_la-
Runtime.lo \<br>+ libkaffevm_la-VMRuntime.lo libkaffevm_la-java_lang_String.lo \<br>+ libkaffevm_la-System.lo libkaffevm_la-java_lang_Thread.lo \<br> libkaffevm_la-Throwable.lo \<br> libkaffevm_la-gnu_classpath_VMStackWalker.lo \
<br> libkaffevm_la-gnu_classpath_VMSystemProperties.lo \<br>@@ -488,7 +488,7 @@<br> $(top_srcdir)/libraries/clib/net/NetworkInterface.c \<br> $(top_srcdir)/libraries/clib/net/PlainDatagramSocketImpl.c \
<br> $(top_srcdir)/libraries/clib/net/PlainSocketImpl.c \<br>- $(top_srcdir)/libraries/clib/io/File.c \<br>+ $(top_srcdir)/libraries/clib/io/java_io_File.c \<br> $(top_srcdir)/libraries/clib/io/java_io_VMFile.c \
<br> $(top_srcdir)/libraries/clib/native/AccessController.c \<br> $(top_srcdir)/libraries/clib/native/java_lang_ref_Reference.c \<br>@@ -499,12 +499,12 @@<br> $(top_srcdir)/libraries/clib/native/TimeZone.c \
<br> $(top_srcdir)/libraries/clib/native/Class.c \<br> $(top_srcdir)/libraries/clib/native/ClassLoader.c \<br>- $(top_srcdir)/libraries/clib/native/Object.c \<br>+ $(top_srcdir)/libraries/clib/native/java_lang_Object.c \
<br> $(top_srcdir)/libraries/clib/native/Runtime.c \<br> $(top_srcdir)/libraries/clib/native/VMRuntime.c \<br>- $(top_srcdir)/libraries/clib/native/String.c \<br>+ $(top_srcdir)/libraries/clib/native/java_lang_String.c \
<br> $(top_srcdir)/libraries/clib/native/System.c \<br>- $(top_srcdir)/libraries/clib/native/Thread.c \<br>+ $(top_srcdir)/libraries/clib/native/java_lang_Thread.c \<br> $(top_srcdir)/libraries/clib/native/Throwable.c \
<br> $(top_srcdir)/libraries/clib/native/gnu_classpath_VMStackWalker.c \<br> $(top_srcdir)/libraries/clib/native/gnu_classpath_VMSystemProperties.c \<br>@@ -625,17 +625,13 @@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
ClassLoader.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Constructor.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Field.Plo@am__quote@<br>-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
File.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-InetAddressImpl.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Method.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
NetworkInterface.Plo@am__quote@<br>-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Object.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-PlainDatagramSocketImpl.Plo@am__quote@
<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-PlainSocketImpl.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Runtime.Plo@am__quote@<br>-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
String.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-System.Plo@am__quote@<br>-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-Thread.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
Throwable.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-TimeZone.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-VMRuntime.Plo@am__quote@<br>@@ -662,7 +658,11 @@
<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-hashtab.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-itypes.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
jar.Plo@am__quote@<br>+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_io_File.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_io_VMFile.Plo@am__quote@<br>+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
java_lang_Object.Plo@am__quote@<br>+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_lang_String.Plo@am__quote@<br>+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_lang_Thread.Plo@am
__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_lang_VMDouble.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-java_lang_VMProcess.Plo@am__quote@<br> @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libkaffevm_la-
java_lang_VMSystem.Plo@am__quote@<br>@@ -986,12 +986,12 @@<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -c -o libkaffevm_la-PlainSocketImpl.lo `test -f
'$(top_srcdir)/libraries/clib/net/PlainSocketImpl.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/net/PlainSocketImpl.c<br><br>-libkaffevm_la-File.lo: $(top_srcdir)/libraries/clib/io/File.c<br>-@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT libkaffevm_la-File.lo
-MD -MP -MF $(DEPDIR)/libkaffevm_la-File.Tpo -c -o
libkaffevm_la-File.lo `test -f '$(top_srcdir)/libraries/clib/io/File.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/io/File.c<br>-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-File.Tpo $(DEPDIR)/libkaffevm_la-
File.Plo<br>-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/io/File.c' object='libkaffevm_la-File.lo' libtool=yes @AMDEPBACKSLASH@<br>+libkaffevm_la-java_io_File.lo: $(top_srcdir)/libraries/clib/io/java_io_File.c
<br>+@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-java_io_File.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-java_io_File.Tpo -c -o libkaffevm_la-java_io_File.lo `test -f '$(top_srcdir)/libraries/clib/io/java_io_File.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/io/java_io_File.c
<br>+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-java_io_File.Tpo $(DEPDIR)/libkaffevm_la-java_io_File.Plo<br>+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/io/java_io_File.c' object='libkaffevm_la-java_io_File.lo' libtool=yes @AMDEPBACKSLASH@
<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>-@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-File.lo `test -f
'$(top_srcdir)/libraries/clib/io/File.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/io/File.c<br>+@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-java_io_File.lo
`test -f '$(top_srcdir)/libraries/clib/io/java_io_File.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/io/java_io_File.c<br><br> libkaffevm_la-java_io_VMFile.lo: $(top_srcdir)/libraries/clib/io/java_io_VMFile.c<br>
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -MT libkaffevm_la-java_io_VMFile.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-java_io_VMFile.Tpo -c -o libkaffevm_la-java_io_VMFile.lo `test -f '$(top_srcdir)/libraries/clib/io/java_io_VMFile.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/io/java_io_VMFile.c
<br>@@ -1063,12 +1063,12 @@<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -c -o libkaffevm_la-ClassLoader.lo `test -f
'$(top_srcdir)/libraries/clib/native/ClassLoader.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/ClassLoader.c<br><br>-libkaffevm_la-Object.lo: $(top_srcdir)/libraries/clib/native/Object.c<br>-@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-Object.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-Object.Tpo
-c -o libkaffevm_la-Object.lo `test -f '$(top_srcdir)/libraries/clib/native/Object.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Object.c<br>-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-Object.Tpo $(DEPDIR)/libkaffevm_la-
Object.Plo<br>-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/Object.c' object='libkaffevm_la-Object.lo' libtool=yes @AMDEPBACKSLASH@<br>+libkaffevm_la-java_lang_Object.lo: $(top_srcdir)/libraries/clib/native/java_lang_Object.c
<br>+@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-java_lang_Object.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-java_lang_Object.Tpo -c -o libkaffevm_la-java_lang_Object.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_Object.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_Object.c
<br>+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-java_lang_Object.Tpo $(DEPDIR)/libkaffevm_la-java_lang_Object.Plo<br>+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/java_lang_Object.c' object='libkaffevm_la-java_lang_Object.lo' libtool=yes @AMDEPBACKSLASH@
<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>-@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-Object.lo `test
-f '$(top_srcdir)/libraries/clib/native/Object.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Object.c<br>+@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-java_lang_Object.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_Object.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_Object.c<br><br>
libkaffevm_la-Runtime.lo: $(top_srcdir)/libraries/clib/native/Runtime.c<br>
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -MT libkaffevm_la-Runtime.lo -MD -MP -MF
$(DEPDIR)/libkaffevm_la-Runtime.Tpo -c -o libkaffevm_la-Runtime.lo
`test -f '$(top_srcdir)/libraries/clib/native/Runtime.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Runtime.c<br>@@ -1084,12 +1084,12 @@<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
<br>
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -c -o libkaffevm_la-VMRuntime.lo `test -f
'$(top_srcdir)/libraries/clib/native/VMRuntime.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/VMRuntime.c<br><br>-libkaffevm_la-String.lo: $(top_srcdir)/libraries/clib/native/String.c<br>-@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-String.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-String.Tpo
-c -o libkaffevm_la-String.lo `test -f '$(top_srcdir)/libraries/clib/native/String.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/String.c<br>-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-String.Tpo $(DEPDIR)/libkaffevm_la-
String.Plo<br>-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/String.c' object='libkaffevm_la-String.lo' libtool=yes @AMDEPBACKSLASH@<br>+libkaffevm_la-java_lang_String.lo: $(top_srcdir)/libraries/clib/native/java_lang_String.c
<br>+@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-java_lang_String.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-java_lang_String.Tpo -c -o libkaffevm_la-java_lang_String.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_String.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_String.c
<br>+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-java_lang_String.Tpo $(DEPDIR)/libkaffevm_la-java_lang_String.Plo<br>+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/java_lang_String.c' object='libkaffevm_la-java_lang_String.lo' libtool=yes @AMDEPBACKSLASH@
<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>-@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-String.lo `test
-f '$(top_srcdir)/libraries/clib/native/String.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/String.c<br>+@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-java_lang_String.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_String.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_String.c<br><br>
libkaffevm_la-System.lo: $(top_srcdir)/libraries/clib/native/System.c<br>
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -MT libkaffevm_la-System.lo -MD -MP -MF
$(DEPDIR)/libkaffevm_la-System.Tpo -c -o libkaffevm_la-System.lo `test
-f '$(top_srcdir)/libraries/clib/native/System.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/System.c<br>@@ -1098,12 +1098,12 @@<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
<br>
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -c -o libkaffevm_la-System.lo `test -f
'$(top_srcdir)/libraries/clib/native/System.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/System.c<br><br>-libkaffevm_la-Thread.lo: $(top_srcdir)/libraries/clib/native/Thread.c<br>-@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-Thread.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-Thread.Tpo
-c -o libkaffevm_la-Thread.lo `test -f '$(top_srcdir)/libraries/clib/native/Thread.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Thread.c<br>-@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-Thread.Tpo $(DEPDIR)/libkaffevm_la-
Thread.Plo<br>-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/Thread.c' object='libkaffevm_la-Thread.lo' libtool=yes @AMDEPBACKSLASH@<br>+libkaffevm_la-java_lang_Thread.lo: $(top_srcdir)/libraries/clib/native/java_lang_Thread.c
<br>+@am__fastdepCC_TRUE@
$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile
$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS)
$(CPPFLAGS) $(libkaffevm_la_CFLAGS) $(CFLAGS) -MT
libkaffevm_la-java_lang_Thread.lo -MD -MP -MF $(DEPDIR)/libkaffevm_la-java_lang_Thread.Tpo -c -o libkaffevm_la-java_lang_Thread.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_Thread.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_Thread.c
<br>+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/libkaffevm_la-java_lang_Thread.Tpo $(DEPDIR)/libkaffevm_la-java_lang_Thread.Plo<br>+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$(top_srcdir)/libraries/clib/native/java_lang_Thread.c' object='libkaffevm_la-java_lang_Thread.lo' libtool=yes @AMDEPBACKSLASH@
<br> @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@<br>-@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-Thread.lo `test
-f '$(top_srcdir)/libraries/clib/native/Thread.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Thread.c<br>+@am__fastdepCC_FALSE@ $(LIBTOOL)
--tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC)
$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS)
$(libkaffevm_la_CFLAGS) $(CFLAGS) -c -o libkaffevm_la-java_lang_Thread.lo `test -f '$(top_srcdir)/libraries/clib/native/java_lang_Thread.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/java_lang_Thread.c<br><br>
libkaffevm_la-Throwable.lo: $(top_srcdir)/libraries/clib/native/Throwable.c<br>
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS)
$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES)
$(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libkaffevm_la_CFLAGS)
$(CFLAGS) -MT libkaffevm_la-Throwable.lo -MD -MP -MF
$(DEPDIR)/libkaffevm_la-Throwable.Tpo -c -o libkaffevm_la-Throwable.lo
`test -f '$(top_srcdir)/libraries/clib/native/Throwable.c' || echo '$(srcdir)/'`$(top_srcdir)/libraries/clib/native/Throwable.c<br>===================================================================<br>Checking out kaffe/libraries/clib/io/File.c
<br>RCS: /home/cvs/kaffe/kaffe/libraries/clib/io/Attic/File.c,v<br>VERS: 1.28<br>***************<br>--- kaffe/libraries/clib/io/File.c Mon Nov 27 21:48:20 2006<br>+++ /dev/null Sun Aug 4 19:57:58 2002<br>@@ -1,497 +0,0 @@
<br>-/*<br>- * java.io.File.c<br>- *<br>- * Copyright (c) 1996, 1997, 1998, 1999<br>- * Transvirtual Technologies, Inc. All rights reserved.<br>- * Copyright (c) 2003, 2006<br>- * Kaffe's team.<br>- * Copyright (c) 2006
<br>- * Free Software Foundation, Inc.<br>- *<br>- * See the file "license.terms" for information on usage and redistribution<br>- * of this file.<br>- */<br>-<br>-#include "config.h"<br>-#include "
config-std.h"<br>-#include "config-io.h"<br>-#include "config-mem.h"<br>-#include <stdio.h><br>-#include <stdlib.h><br>-#include <assert.h><br>-#include <native.h><br>-#include <
jsyscall.h><br>-#ifdef HAVE_UTIME_H<br>-#include <utime.h><br>-#endif<br>-#include "defs.h"<br>-#include "files.h"<br>-#include "../../../include/system.h"<br>-#include "jni.h"
<br>-#include "java_io_VMFile.h"<br>-#include "support.h"<br>-#include "stringSupport.h"<br>-<br>-/*<br>- * Is named item a file?<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_isFile (JNIEnv * env,
<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- int r;<br>- struct stat buf;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }
<br>-<br>- r = KSTAT(filename, &buf);<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- if (r == 0 && S_ISREG(buf.st_mode)) {<br>- return (1);<br>- }<br>- else {<br>- return (0);
<br>- }<br>-}<br>-<br>-/*<br>- * Is named item a directory?<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_isDirectory (JNIEnv * env,<br>- jobject
obj __attribute__ ((__unused__)),<br>- jstring
name)<br>-{<br>- const char * filename;<br>- int r;<br>- struct stat buf;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>
- r = KSTAT(filename, &buf);<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- if (r == 0 && S_ISDIR(buf.st_mode)) {<br>- return (1);<br>- }<br>- else {<br>- return (0);<br>- }
<br>-}<br>-<br>-/*<br>- * Does named file exist?<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_exists (JNIEnv * env,<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- int result;<br>- struct stat buf;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }
<br>-<br>- /* A file exists if I can stat it */<br>- result = KSTAT(filename, &buf);<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return result == 0;<br>-}<br>-<br>-/*<br>- * Last modified time on file.
<br>- */<br>-JNIEXPORT jlong JNICALL<br>-Java_java_io_VMFile_lastModified (JNIEnv * env,<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- struct stat buf;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }
<br>-<br>-<br>- r = KSTAT(filename, &buf);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- if (r != 0) {<br>- return ((jlong)0);<br>- }<br>- return ((jlong)buf.st_mtime * (jlong)1000);
<br>-}<br>-<br>-/*<br>- * Can I write to this file?<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_canWrite (JNIEnv * env,<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>- /* XXX make part of jsyscall interface !? */
<br>- r = access(filename, W_OK);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return (r < 0 ? 0 : 1);<br>-}<br>-<br>-/*<br>- * Can I read from this file.<br>- */<br>-JNIEXPORT jboolean JNICALL
<br>-Java_java_io_VMFile_canRead (JNIEnv * env,<br>- jobject
obj __attribute__ ((__unused__)),<br>- jstring
name)<br>-{<br>- const char *filename;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>- /* XXX make part of jsyscall interface !? */
<br>- r = access(filename, R_OK);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return (r < 0 ? 0 : 1);<br>-}<br>-<br>-/*<br>- * Return length of file.<br>- */<br>-JNIEXPORT jlong JNICALL
<br>-Java_java_io_VMFile_length (JNIEnv * env,<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- struct stat buf;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }
<br>-<br>- r = KSTAT(filename, &buf);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- if (r != 0) {<br>- return ((jlong)0);<br>- }<br>- return ((jlong)buf.st_size);<br>-}<br>-<br>-/*
<br>- * Create a directory.<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_mkdir (JNIEnv * env,<br>- jobject
obj __attribute__ ((__unused__)),<br>- jstring
name)<br>-{<br>- const char *filename;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>- r = KMKDIR(filename, 0777);
<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return (r != 0 ? 0 : 1);<br>-}<br>-<br>-/*<br>- * Rename a file.<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_renameTo (JNIEnv * env,
<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring t, jstring d)<br>-{<br>- const char *old_filename, *new_filename;<br>- int r;<br>-<br>- old_filename = (*env)->GetStringUTFChars (env, t, 0);<br>- if (old_filename == NULL)<br>- {<br>- return (0);<br>
- }<br>-<br>- new_filename = (*env)->GetStringUTFChars (env, d, 0);<br>- if (new_filename == NULL)<br>- {<br>- (*env)->ReleaseStringUTFChars (env, t, old_filename);<br>- return (0);<br>- }<br>-<br>
- r = KRENAME(old_filename, new_filename);<br>-<br>- (*env)->ReleaseStringUTFChars (env, t, old_filename);<br>- (*env)->ReleaseStringUTFChars (env, t, new_filename);<br>-<br>- return (r != 0 ? 0 : 1);<br>-}<br>-
<br>-/*<br>- * Delete a file.<br>- */<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_delete (JNIEnv * env,<br>-
jobject obj __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>- r = KREMOVE(filename);
<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return(r != 0 ? 0 : 1);<br>-}<br>-<br>-/*<br>- * Get a directory listing.<br>- */<br>-JNIEXPORT jobjectArray JNICALL<br>-Java_java_io_VMFile_list (JNIEnv * env, jobject obj
<br>-
__attribute__ ((__unused__)), jstring name)<br>-{<br>-#if defined(HAVE_DIRENT_H)<br>- const char *dirname;<br>- DIR* dir;<br>- struct dirent* entry;<br>- struct dentry {<br>- struct dentry* next;<br>- char name[1];
<br>- };<br>- struct dentry* dirlist;<br>- struct dentry* mentry;<br>- struct dentry* lastentry;<br>- HArrayOfObject* array;<br>- int count;<br>- int i;<br>- int oom = 0;<br>-<br>- dirname = (*env)->GetStringUTFChars (env, name, 0);
<br>- if (dirname == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>- /* XXX make part of jsyscall interface !? */<br>- dir = opendir(dirname);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, dirname);
<br>-<br>- if (dir == 0) {<br>- return (NULL);<br>- }<br>-<br>- dirlist = NULL;<br>- lastentry = NULL;<br>- count = 0;<br>- /* XXX make part of jsyscall interface !? */<br>- while ((entry = readdir(dir)) != NULL) {
<br>- /* We skip '.' and '..' */<br>- if (strcmp(".", entry->d_name) == 0 ||<br>- strcmp("..", entry->d_name) == 0) {<br>- continue;<br>- }<br>- mentry = KMALLOC(sizeof(struct dentry) + NAMLEN(entry));
<br>- if (!mentry) {<br>- errorInfo info;<br>-<br>- while (dirlist) {<br>- mentry = dirlist;<br>- dirlist = dirlist->next;<br>- KFREE(mentry);<br>- }<br>- postOutOfMemory(&info);
<br>- throwError(&info);<br>- }<br>- strcpy(mentry->name, entry->d_name);<br>- mentry->next = NULL;<br>- if (count == 0) {<br>- dirlist = mentry;<br>- }<br>- else {<br>- lastentry->next = mentry;
<br>- }<br>- lastentry = mentry;<br>- count++;<br>- }<br>- /* XXX make part of jsyscall interface !? */<br>- closedir(dir);<br>-<br>- array = (HArrayOfObject*)AllocObjectArray(count,<br>-
"Ljava/lang/String;", NULL);<br>- /* XXX: This assert is a noop. If AllocObjectArray throws an<br>- exception, we leak. */<br>- assert(array != NULL);<br>- for (i = 0; i < count; i++) {<br>- mentry = dirlist;
<br>- dirlist = mentry->next;<br>- unhand_array(array)->body[i] =<br>- (Hjava_lang_Object*)checkPtr(stringC2Java(mentry->name));<br>- /* if allocation fails, continue freeing mentries in<br>- this loop. */
<br>- oom |= !unhand_array(array)->body[i];<br>- KFREE(mentry);<br>- }<br>- if (oom) {<br>- errorInfo info;<br>- postOutOfMemory(&info);<br>- throwError(&info);<br>- }<br>-<br>- return (array);
<br>-#else<br>- return (0);<br>-#endif<br>-}<br>-<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_create (JNIEnv * env,<br>-
jclass clazz __attribute__ ((__unused__)),<br>-
jstring name)<br>-{<br>- const char *filename;<br>- int fd;<br>- int rc;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>
- rc = KOPEN(filename, O_EXCL|O_WRONLY|O_BINARY|O_CREAT, 0600, &fd);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- switch (rc) {<br>- case 0:<br>- break;<br>- case EEXIST:<br>- return 0;
<br>- default:<br>- SignalError("java.io.IOException", SYS_ERROR(rc));<br>- }<br>- rc = KCLOSE(fd);<br>- if (rc != 0)<br>- SignalError("java.io.IOException", SYS_ERROR(rc));<br>- return 1;<br>
-}<br>-<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_setLastModified (JNIEnv * env,<br>- jobject
obj __attribute__ ((__unused__)),<br>- jstring
name, jlong newtime)<br>-{<br>-#ifdef HAVE_UTIME_H<br>- const char *filename;<br>- int result;<br>- struct utimbuf ub;<br>-#endif<br>-<br>- if (newtime < 0)<br>- SignalError("java.lang.IllegalArgumentException
", "time < 0");<br>-#ifdef HAVE_UTIME_H<br>-<br>- ub.actime = (time_t)(newtime / 1000);<br>- ub.modtime = ub.actime;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)
<br>- {<br>- return (0);<br>- }<br>-<br>- result = utime(filename, &ub);<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return result >= 0;<br>-#else<br>- return 0;<br>-#endif
<br>-}<br>-<br>-JNIEXPORT jboolean JNICALL<br>-Java_java_io_VMFile_setReadOnly (JNIEnv * env,<br>- jobject
obj __attribute__ ((__unused__)),<br>- jstring
name)<br>-{<br>- const char *filename;<br>- struct stat buf;<br>- int r;<br>-<br>- filename = (*env)->GetStringUTFChars (env, name, 0);<br>- if (filename == NULL)<br>- {<br>- return (0);<br>- }<br>-<br>
- r = KSTAT(filename, &buf);<br>-<br>- if (r == 0)<br>- r = chmod(filename, buf.st_mode & ~(S_IWOTH|S_IWGRP|S_IWUSR));<br>-<br>- (*env)->ReleaseStringUTFChars (env, name, filename);<br>-<br>- return (r == 0);
<br>-}<br>-<br>===================================================================<br>Checking out kaffe/libraries/clib/io/java_io_File.c<br>RCS: /home/cvs/kaffe/kaffe/libraries/clib/io/java_io_File.c,v<br>VERS: 1.1<br>***************
<br>--- /dev/null Sun Aug 4 19:57:58 2002<br>+++ kaffe/libraries/clib/io/java_io_File.c Mon Nov 27 21:48:21 2006<br>@@ -0,0 +1,497 @@<br>+/*<br>+ * java.io.File.c<br>+ *<br>+ * Copyright (c) 1996, 1997, 1998, 1999
<br>+ * Transvirtual Technologies, Inc. All rights reserved.<br>+ * Copyright (c) 2003, 2006<br>+ * Kaffe's team.<br>+ * Copyright (c) 2006<br>+ * Free Software Foundation, Inc.<br>+ *<br>+ * See the file "
license.terms" for information on usage and redistribution<br>+ * of this file.<br>+ */<br>+<br>+#include "config.h"<br>+#include "config-std.h"<br>+#include "config-io.h"<br>+#include "
config-mem.h"<br>+#include <stdio.h><br>+#include <stdlib.h><br>+#include <assert.h><br>+#include <native.h><br>+#include <jsyscall.h><br>+#ifdef HAVE_UTIME_H<br>+#include <utime.h>
<br>+#endif<br>+#include "defs.h"<br>+#include "files.h"<br>+#include "../../../include/system.h"<br>+#include "jni.h"<br>+#include "java_io_VMFile.h"<br>+#include "support.h
"<br>+#include "stringSupport.h"<br>+<br>+/*<br>+ * Is named item a file?<br>+ */<br>+JNIEXPORT jboolean JNICALL<br>+Java_java_io_VMFile_isFile (JNIEnv * env,<br>+
jobject obj __attribute__ ((__unused__)),<br>+
jstring name)<br>+{<br>+ const char *filename;<br>+ int r;<br>+ struct stat buf;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }
<br>+<br>+ r = KSTAT(filename, &buf);<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ if (r == 0 && S_ISREG(buf.st_mode)) {<br>+ return (1);<br>+ }<br>+ else {<br>+ return (0);
<br>+ }<br>+}<br>+<br>+/*<br>+ * Is named item a directory?<br>+ */<br>+JNIEXPORT jboolean JNICALL<br>+Java_java_io_VMFile_isDirectory (JNIEnv * env,<br>+ jobject
obj __attribute__ ((__unused__)),<br>+ jstring
name)<br>+{<br>+ const char * filename;<br>+ int r;<br>+ struct stat buf;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }<br>+<br>
+ r = KSTAT(filename, &buf);<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ if (r == 0 && S_ISDIR(buf.st_mode)) {<br>+ return (1);<br>+ }<br>+ else {<br>+ return (0);<br>+ }
<br>+}<br>+<br>+/*<br>+ * Does named file exist?<br>+ */<br>+JNIEXPORT jboolean JNICALL<br>+Java_java_io_VMFile_exists (JNIEnv * env,<br>+
jobject obj __attribute__ ((__unused__)),<br>+
jstring name)<br>+{<br>+ const char *filename;<br>+ int result;<br>+ struct stat buf;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }
<br>+<br>+ /* A file exists if I can stat it */<br>+ result = KSTAT(filename, &buf);<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ return result == 0;<br>+}<br>+<br>+/*<br>+ * Last modified time on file.
<br>+ */<br>+JNIEXPORT jlong JNICALL<br>+Java_java_io_VMFile_lastModified (JNIEnv * env,<br>+
jobject obj __attribute__ ((__unused__)),<br>+
jstring name)<br>+{<br>+ const char *filename;<br>+ struct stat buf;<br>+ int r;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }
<br>+<br>+<br>+ r = KSTAT(filename, &buf);<br>+<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ if (r != 0) {<br>+ return ((jlong)0);<br>+ }<br>+ return ((jlong)buf.st_mtime * (jlong)1000);
<br>+}<br>+<br>+/*<br>+ * Can I write to this file?<br>+ */<br>+JNIEXPORT jboolean JNICALL<br>+Java_java_io_VMFile_canWrite (JNIEnv * env,<br>+
jobject obj __attribute__ ((__unused__)),<br>+
jstring name)<br>+{<br>+ const char *filename;<br>+ int r;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }<br>+<br>+ /* XXX make part of jsyscall interface !? */
<br>+ r = access(filename, W_OK);<br>+<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ return (r < 0 ? 0 : 1);<br>+}<br>+<br>+/*<br>+ * Can I read from this file.<br>+ */<br>+JNIEXPORT jboolean JNICALL
<br>+Java_java_io_VMFile_canRead (JNIEnv * env,<br>+ jobject
obj __attribute__ ((__unused__)),<br>+ jstring
name)<br>+{<br>+ const char *filename;<br>+ int r;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }<br>+<br>+ /* XXX make part of jsyscall interface !? */
<br>+ r = access(filename, R_OK);<br>+<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ return (r < 0 ? 0 : 1);<br>+}<br>+<br>+/*<br>+ * Return length of file.<br>+ */<br>+JNIEXPORT jlong JNICALL
<br>+Java_java_io_VMFile_length (JNIEnv * env,<br>+
jobject obj __attribute__ ((__unused__)),<br>+
jstring name)<br>+{<br>+ const char *filename;<br>+ struct stat buf;<br>+ int r;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br>+ return (0);<br>+ }
<br>+<br>+ r = KSTAT(filename, &buf);<br>+<br>+ (*env)->ReleaseStringUTFChars (env, name, filename);<br>+<br>+ if (r != 0) {<br>+ return ((jlong)0);<br>+ }<br>+ return ((jlong)buf.st_size);<br>+}<br>+<br>+/*
<br>+ * Create a directory.<br>+ */<br>+JNIEXPORT jboolean JNICALL<br>+Java_java_io_VMFile_mkdir (JNIEnv * env,<br>+ jobject
obj __attribute__ ((__unused__)),<br>+ jstring
name)<br>+{<br>+ const char *filename;<br>+ int r;<br>+<br>+ filename = (*env)->GetStringUTFChars (env, name, 0);<br>+ if (filename == NULL)<br>+ {<br><br>*** Patch too long, truncated ***<br><br><br><br>------------------------------
<br><br>_______________________________________________<br>kaffe mailing list<br><a href="mailto:kaffe@kaffe.org">kaffe@kaffe.org</a><br><a href="http://kaffe.org/cgi-bin/mailman/listinfo/kaffe">http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
</a><br><br><br>End of kaffe Digest, Vol 30, Issue 25<br>*************************************<br></blockquote></div><br>