public inbox for java-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug libgcj/55716] New: [4.8 Regression] gjavah crashes
@ 2012-12-17  9:03 jakub at gcc dot gnu.org
  2012-12-17  9:04 ` [Bug libgcj/55716] " jakub at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-12-17  9:03 UTC (permalink / raw)
  To: java-prs


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

             Bug #: 55716
           Summary: [4.8 Regression] gjavah crashes
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgcj
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jakub@gcc.gnu.org


For redhat/gcc-4_X-branch, I remove all gjavah --cni generated headers (and
*.class files and *.jar files except for libjava.jar testcase), then build with
--enable-java-maintainer-mode.
If I use gcc 4.7.2 gjavah for that (also on the trunk tree), everything works
fine, but with gcc 4.8.0 gjavah it fails.

$ gjavah --cni --all ../../../libjava/classpath/lib
--cmdfile=../../../libjava/headers.txt -d ../../../libjava --force
java.io.IOException: can't find class file
gnu/xml/stream/XMLParser$ContentModel.class in
java.net.URLClassLoader{urls=[file:/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre/lib/rt.jar],
parent=gnu.gcj.runtime.SystemClassLoader{urls=[file:./],
parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}}
    at gnu.classpath.tools.javah.Main.getClass(libgcj-tools.so.14)
    at gnu.classpath.tools.javah.Main.parseClasses(libgcj-tools.so.14)
    at gnu.classpath.tools.javah.Main.parseClasses(libgcj-tools.so.14)
    at gnu.classpath.tools.javah.Main.run(libgcj-tools.so.14)
    at gnu.classpath.tools.javah.Main.main(libgcj-tools.so.14)

Usually I'm using hack like
# If we don't have gjavah in $PATH, try to build it with the old gij            
mkdir java_hacks                                                                
cd java_hacks                                                                   
cp -a ../../libjava/classpath/tools/external external                           
mkdir -p gnu/classpath/tools                                                    
cp -a ../../libjava/classpath/tools/gnu/classpath/tools/{common,javah,getopt}
gnu/classpath/tools/                                                 
cp -a
../../libjava/classpath/tools/resource/gnu/classpath/tools/common/messages.properties
gnu/classpath/tools/common                             
cp -a
../../libjava/classpath/tools/resource/gnu/classpath/tools/getopt/messages.properties
gnu/classpath/tools/getopt                             
cd external/asm; for i in `find . -name \*.java`; do gcj --encoding ISO-8859-1
-C $i -I.; done; cd ../..                                           
for i in `find gnu -name \*.java`; do gcj -C $i -I. -Iexternal/asm/; done       
gcj -findirect-dispatch -O2 -fmain=gnu.classpath.tools.javah.Main -I.
-Iexternal/asm/ `find . -name \*.class` -o gjavah.real                       
cat > gjavah <<EOF                                                              
#!/bin/sh                                                                       
export CLASSPATH=`pwd`${CLASSPATH:+:$CLASSPATH}                                 
exec `pwd`/gjavah.real "\$@"                                                    
EOF                                                                             
chmod +x `pwd`/gjavah                                                           

and prepend that java_hacks/ into $PATH for gcc bootstrap, that method fails
the exact same way.  Initially I thought there would be some issue with this
way
of creating gjavah, but when I've used system gjavah (removed this one),
bootstrapped/regtested it fine, then installed the new gcc + gcc-java/libgcj
etc.,
and using the new (4.8.0) system gjavah it failed the same way.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-12-18 10:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-17  9:03 [Bug libgcj/55716] New: [4.8 Regression] gjavah crashes jakub at gcc dot gnu.org
2012-12-17  9:04 ` [Bug libgcj/55716] " jakub at gcc dot gnu.org
2012-12-17  9:43 ` mark at gcc dot gnu.org
2012-12-17 10:16 ` mark at gcc dot gnu.org
2012-12-17 10:23 ` [Bug libgcj/55716] [4.8 Regression] gjavah throws an exception jakub at gcc dot gnu.org
2012-12-18 10:00 ` aph at gcc dot gnu.org
2012-12-18 10:01 ` aph at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).