When I tried to compile and link java application into an exacutable using GCJ 
v3.4.3 in Linux Red Hat 3.4.3-9.EL4, it produces error messages:

[EMAIL PROTECTED]:~/testarea/build$ ./gcjbuild
Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/specs
Reading specs from /usr/lib/gcc/i386-redhat-linux/3.4.3/libgcj.spec
rename spec lib to liborig
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --
infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-
checking --with-system-zlib --enable-__cxa_atexit --disable-libunwind-
exceptions --enable-java-awt=gtk --host=i386-redhat-linux
Thread model: posix
gcc version 3.4.3 20041212 (Red Hat 3.4.3-9.EL4)
 /usr/libexec/gcc/i386-redhat-linux/3.4.3/jc1 /tmp/ccDKDmFrjx -fhash-
synchronization -fno-use-divide-subroutine -fuse-boehm-gc -fnon-call-
exceptions -fkeep-inline-functions -quiet -dumpbase ccDKDmFrjx -auxbase 
ccDKDmFrjx -g1 -version -fjni -
fclasspath=/opt/cloakware/cspmclient_thirdparty/java/jre/lib:/opt/cloakware/csp
mclient_thirdparty/java/jre/lib/jsse.jar:/opt/cloakware/cspmclient_thirdparty/j
etty/lib/javax.servlet.jar:/opt/cloakware/cspmclient_thirdparty/jetty/ext/xmlPa
rserAPIs-2.5.jar -ffilelist-file -o /tmp/ccKdJ5dJ.s
GNU Java version 3.4.3 20041212 (Red Hat 3.4.3-9.EL4) (i386-redhat-linux)
        compiled by GNU C version 3.4.3 20041212 (Red Hat 3.4.3-9.EL4).
GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=129199
Class path starts here:
    /opt/cloakware/cspmclient_thirdparty/java/jre/lib/
    /opt/cloakware/cspmclient_thirdparty/java/jre/lib/jsse.jar/ (zip)
    /opt/cloakware/cspmclient_thirdparty/jetty/lib/javax.servlet.jar/ (zip)
    /opt/cloakware/cspmclient_thirdparty/jetty/ext/xmlParserAPIs-2.5.jar/ (zip)
    /usr/share/java/libgcj-3.4.3.jar/ (system) (zip)
java/awt/Component.java: In class `java.awt.Component':
java/awt/Component.java: In method `java.awt.Component.eventTypeEnabled(int)':
java/awt/Component.java:4709: error: expected type 'int' but stack 
contains 'void'
java/awt/Component.java:4709: error: verification error at PC=327
java/awt/Component.java:4709: error: types could not be merged
java/io/BufferedReader.java:0: confused by earlier errors, bailing out



Looks like one of our jars linked is using the java.awt.* package, which cause 
the problem.

By the way, all our JAVA applications work very well if we don't compile and 
link it into an executable.

Thanks a lot in advance.

Jack rong

-- 
           Summary: gcj link error
           Product: gcc
           Version: 3.4.3
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: libgcj
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jack dot rong at cloakware dot com
                CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
                    dot org


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

Reply via email to