[kaffe] Kaffe's jar and current directory

Ito Kazumitsu ito.kazumitsu at hidec.co.jp
Thu Jun 23 18:27:48 PDT 2005


Hi,

Is this a bug of Kaffe's jar, or am I doing something wrong?

Command to be executed: jar -cf 0.jar -C tmp .

$ ls -al tmp
total 16
drwxrwxr-x    2 ito      ito          4096 Jun 24 10:01 .
drwx------   52 ito      ito          4096 Jun 23 16:08 ..
-rw-rw-r--    1 ito      ito             6 Jun 24 10:01 file1
-rw-rw-r--    1 ito      ito             6 Jun 24 10:01 file2

With Kaffe's jar:
$ /usr/local/kaffe/bin/jar -cf 0.jar -C tmp .
$ /usr/local/kaffe/bin/jar tvf 0.jar
   263 Fri Jun 24 10:03:22 GMT+09:00 2005 META-INF/MANIFEST.MF
     0 Fri Jun 24 10:03:22 GMT+09:00 2005 ./
     6 Fri Jun 24 10:03:22 GMT+09:00 2005 ./file1
     6 Fri Jun 24 10:03:22 GMT+09:00 2005 ./file2

With GCJ's jar:
$ /usr/local/bin/jar -cf 0.jar -C tmp .
$ /usr/local/bin/jar tvf 0.jar
     0 Fri Jun 24 10:04:50 JST 2005 META-INF/
    44 Fri Jun 24 10:04:50 JST 2005 META-INF/MANIFEST.MF
     0 Fri Jun 24 10:01:32 JST 2005 ./
     6 Fri Jun 24 10:01:28 JST 2005 file1
     6 Fri Jun 24 10:01:32 JST 2005 file2

With Sun's jar
$ /cygdrive/c/j2sdk1.4.2_06/bin/jar -cf 0.jar -C tmp .
$ /cygdrive/c/j2sdk1.4.2_06/bin/jar tvf 0.jar
     0 Fri Jun 24 10:07:06 JST 2005 META-INF/
    71 Fri Jun 24 10:07:06 JST 2005 META-INF/MANIFEST.MF
     6 Fri Jun 24 10:01:30 JST 2005 file1
     6 Fri Jun 24 10:01:32 JST 2005 file2

I am afraid that the current directory notation "./" attached to
each file name may be the cause of NoClassDefFoundError when
a kaffe-made jar file is in the classpath.



More information about the kaffe mailing list