From: Phil S. <psu...@es...> - 2002-02-22 14:29:36
|
AFAIK, you can't do what you want to do. You can put the Lib directory into a jar, however the only syntax for accessing it (that I know of) is to add something like this into your python path: some/dirs/your.war/Lib (this works for 2.1, 2.1alpha used !Lib) ...but this means that you'd need to know where the war was being deployed. The solution is to allow jython to load python files from the classpath. The jython developers have been pondering what the right thing to do should be. Classloaders are tricky beasts, especially once you get into the world of j2ee containers. -----Original Message----- From: Gerhard =?unknown-8bit?Q?H=E4ring?= [mailto:gh_...@gm...] Sent: Thursday, February 21, 2002 11:00 PM To: jyt...@li... Subject: [Jython-users] Put Core + Lib in one big .jar I'm currently playing with Jython and the BSF taglib in a web application. The web application is deployed as a .war file. As there is no guarantee that the .war files are ever unpacked (and I prefer them not too), I can't put Jython's Lib/ directory in there, can I? So I've tried to freeze all of Jython like this: ./jythonc -j /tmp/reallybig-jython.jar -C /usr/bin/javac -a Lib/*.py this didn't provide any usable result. Hmm. Is it possible to get rid of all the .py files and pack *everything* into one jar, so that I can still use Jython from the BSF? Gerhard -- mail: gerhard <at> bigfoot <dot> de registered Linux user #64239 web: http://www.cs.fhm.edu/~ifw00065/ OpenPGP public key id 86AB43C0 public key fingerprint: DEC1 1D02 5743 1159 CD20 A4B6 7B22 6575 86AB 43C0 reduce(lambda x,y:x+y,map(lambda x:chr(ord(x)^42),tuple('zS^BED\nX_FOY\x0b'))) _______________________________________________ Jython-users mailing list Jyt...@li... https://lists.sourceforge.net/lists/listinfo/jython-users |