A simple question
I was trying to do something weird: take one of my PyQt proggies, and compile it into a standalone binary using Jython, koala/qtjava and gjc.
Sadly, it doesn't work :-(
Has anyone ever gotten a rather recent gjc and jython to work together?
The best I can get is this:
[ralsina@monty jython]$ gcj -fjni /usr/lib/lib-org-*.so.* --classpath=/usr/java/j2sdk1.4.2_08/jre/lib/ --main=org.python.util.jython /usr/share/java/dom3-xerces-j2.jar /usr/share/java/ant.jar /usr/share/java/servlet.jar /usr/share/java/oro.jar /usr/share/java/jython.jar -o jython
org/apache/html/dom/HTMLAnchorElementImpl.java:0: error: cannot find file for class org.w3c.dom.events.EventTarget
org/apache/html/dom/HTMLAnchorElementImpl.java:0: error: cannot find file for class org.w3c.dom.TypeInfo
org/apache/html/dom/HTMLAnchorElementImpl.java:0: error: cannot find file for class org.w3c.dom.html.HTMLElement
org/apache/html/dom/HTMLAnchorElementImpl.java:0: error: cannot find file for class org.w3c.dom.html.HTMLAnchorElement
org/apache/html/dom/HTMLAnchorElementImpl.class:0: confused by earlier errors, bailing out
This is using gcc-java-3.4.3-22.1 and jython-2.2-0.a0.2jpp
I mean, this is completely unnecessary, but it would be a nice hack :-)
I suppose either
ant.jar
oro.jar
has references to xerces 1.4.4
However you have added dom3-xerces-j2.jar. That's version 2 of xerces. You can try to download xerces 1.4.4 from http://xml.apache.org/dist/xerces-j/
Or I would prefer download latest versions of Ant and/or Oro.
http://ant.apache.org/bindownload.cgi and
http://jakarta.apache.org/site/downloads/downloads_oro.cgi
Good luck
Mike
With 3.4, the rule is that if you compile a library
you must also compile and link in all its dependencies.
If you can use 4.x, you can switch to the new
"binary compatibility ABI", which is a bit
more friendly here.
I haven't tried jython in a while myself, but
it worked for a long time.