[Bug java/24698] [4.1 regression] Apparent problem getting non-.class files out of jars

2005-11-19 Thread bero at arklinux dot org


--- Comment #1 from bero at arklinux dot org  2005-11-19 15:00 ---
Created an attachment (id=10293)
 -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=10293action=view)
Simplified test case (this will become a jar)

Compile the attached minimalistic test case into a jar file:

tar xzf test.tar.gz
gcj -C org/arklinux/test/testcase.java
fastjar cf test.jar org/arklinux/test/*.class org/arklinux/test/*.properties


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24698



[Bug java/24698] [4.1 regression] Apparent problem getting non-.class files out of jars

2005-11-19 Thread bero at arklinux dot org


--- Comment #2 from bero at arklinux dot org  2005-11-19 15:02 ---
Created an attachment (id=10294)
 -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=10294action=view)
Testcase, part 2

Step 2: Compile something that uses it

CLASSPATH=test.jar gcj -C test1.java


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24698



[Bug java/24698] [4.1 regression] Apparent problem getting non-.class files out of jars

2005-11-19 Thread bero at arklinux dot org


--- Comment #3 from bero at arklinux dot org  2005-11-19 15:03 ---
Step 3: Try running it.

CLASSPATH=test.jar gij test1

Prints Microsoft is crap with gcj 4.0.x, produces a segmentation fault with
today's SVN.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24698



[Bug java/24698] [4.1 regression] Apparent problem getting non-.class files out of jars

2005-11-19 Thread bero at arklinux dot org


--- Comment #4 from bero at arklinux dot org  2005-11-19 15:16 ---
Also try:

gcj -O2 -fPIC -fjni -shared -o libtestcase.so test.jar
gcj -o testcase test1.java --main=test1 -L. -ltestcase
LD_LIBRARY_PATH=. ./testcase

Works as expected in 4.0.x, current SVN acts up: Generating libtestcase.so
doesn't produce an error, but after that things get strange.

$ gcj -o testcase test1.java --main=test1 -L. -ltestcase
test1.java:1: error: Can't find default package 'org.arklinux.test'. Check the
CLASSPATH environment variable and the access to the archives
1 error
test1.java:0: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://gcc.gnu.org/bugs.html for instructions

Similar error if I tell it where to find the jar:
$ CLASSPATH=test.jar gcj -o testcase test1.java --main=test1 -L. -ltestcase
test1.java:3: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://gcc.gnu.org/bugs.html for instructions


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=24698