Re: Ongoing bsh interface problem
"Suraj Acharya" <[email protected]>
| Newsgroups | gmane.emacs.jdee |
|---|---|
| Message-ID | <[email protected]> |
(I forgot to reply to the group earlier.) Glenn, The debian package is definitely broken. The java/lib directory in jde 2.3.5contains the following files: LICENSE.apache RIGHTS.antlr checkstyle-all.jar junit.jar LICENSE.checkstyle bsh.jar jde.jar sun_checks.xml Not having the checkstyle-all.jar in your path shouldn't hurt unless you try to run M-x jde-checkstyle. Suraj On 3/9/06, Glenn Murray <[email protected]> wrote: > > Hi Suraj, > > Thanks for the reply. I created an empty ~/testemacs > directory and put my simple Test.java file into it. > With: > > > testemacs/$ echo $CLASSPATH > .:/usr/share/java/jde.jar > testemacs/$ emacs Test.java & > > > the compilation and syntax completion worked fine. The contents of > the "*JDEE bsh*" buffer are: > > cd /home/glenn/testemacs/ > /usr/lib/j2sdk1.5-sun/bin/java -classpath > /usr/share/emacs21/site-lisp/java/lib/bsh.jar:/usr/share/emacs21/site-lisp/java/bsh-commands:/usr/share/emacs21/site-lisp/java/lib/checkstyle- > all.jar:/usr/share/emacs21/site-lisp/java/lib/jakarta-regexp.jar:/usr/share/emacs21/site-lisp/java/lib/jde.jar:/usr/lib/j2sdk1.5-sun/lib/tools.jar:/home/glenn/testemacs:/usr/share/java/jde.jar > bsh.Interpreter > > BeanShell 2.0b4 - by Pat Niemeyer ([email protected]) > bsh % > > > I then > closed Emacs and: > > > testemacs/$ export CLASSPATH= > testemacs/$ echo $CLASSPATH > > testemacs/$ emacs Test.java & > > > In this case compilation failed; the Messages buffer says: > > ... > Setting customized JDE variables to startup values... > Loading jde-javadoc...done > (No files need saving) > Starting the BeanShell. Please wait... > Beanshell expression evaluation error. > Expression: jde.util.JdeUtilities.setProjectValues("", ""); > Error: // Error: EvalError: Class or variable not found: > jde.util.JdeUtilities : at Line: 1 : in file: <unknown file> > : jde .util .JdeUtilities .setProjectValues ( "" , "" ) > [2 times] > bsh: Beanshell eval error. See messages buffer for details. > > > > and the contents of the *JDEE bsh* buffer: > > > > cd /home/glenn/testemacs/ > /usr/lib/j2sdk1.5-sun/bin/java -classpath > /usr/share/emacs21/site-lisp/java/lib/bsh.jar:/usr/share/emacs21/site-lisp/java/bsh-commands:/usr/share/emacs21/site-lisp/java/lib/checkstyle- > all.jar:/usr/share/emacs21/site-lisp/java/lib/jakarta-regexp.jar:/usr/share/emacs21/site-lisp/java/lib/jde.jar:/usr/lib/j2sdk1.5-sun/lib/tools.jar > bsh.Interpreter > > BeanShell 2.0b4 - by Pat Niemeyer ([email protected]) > bsh % > > > > Now that you've directed my attention to it, I notice that the > bsh.Interpreter is being started with another jde.jar in the > classpath, from /usr/share/emacs21/site-lisp/java/lib/, but: > > > testemacs/$ locate jde.jar > /usr/share/java/jde.jar > testemacs/$ ls /usr/share/emacs21/site-lisp/java/lib/ > bsh.jar@ > testemacs/$ ls -l /usr/share/emacs21/site-lisp/java/lib/ > total 0 > lrwxrwxrwx 1 root root 23 2006-02-02 10:40 bsh.jar -> > /usr/share/java/bsh.jar > > > > So now it looks like everything in the *JDEE bsh* classpath, except > bsh.jar, is being ignored. Possibly this is a Debian install error? > It looks like I need to link /usr/share/emacs21/site-lisp/java/lib/ to > > > testemacs/$ ls /usr/share/java > ant-1.6.jar@ bsh.jar@ > commons-validator-1.1.4.jar mx4j-2.1.1.jar > ant-antlr.jar@ commons-beanutils-1.7.0.jar > commons-validator.jar@ mx4j.jar@ > ant-apache-bcel.jar@ commons-beanutils.jar@ gnu-crypto.jar > mx4j-remote-2.1.1.jar > ant-apache-bsf.jar@ commons-collections-2.1.1.jar > hsqldb-1.8.0.2.jar mx4j-remote.jar@ > ant-apache-log4j.jar@ commons-collections3-3.1.jar hsqldb.jar > @ mx4j-tools-2.1.1.jar > ant-apache-oro.jar@ commons-collections3.jar@ > hsqldbutil-1.8.0.2.jar mx4j-tools.jar@ > ant-apache-regexp.jar@ commons-collections.jar@ hsqldbutil.jar > @ openoffice/ > ant-apache-resolver.jar@ commons-dbcp-1.2.1.jar javax-crypto.jar > oro-2.0.8.jar > ant-bootstrap.jar@ commons-dbcp.jar@ > javax-security.jar oro.jar@ > ant-commons-logging.jar@ commons-digester-1.7.jar jaxp-1.2.jar > regexp-1.4.jar > ant-commons-net.jar@ commons-digester.jar@ jde.jar > regexp.jar@ > ant.jar@ commons-el-1.0.jar jessie.jar > servlet-2.3.jar > ant-javamail.jar@ commons-el.jar@ jline-0.9.1.jar > servlet-api-2.4.jar > ant-jdepend.jar@ commons-fileupload-1.0.jar jline.jar@ > servlet-api.jar@ > ant-jmf.jar@ commons-fileupload.jar@ jsp-api-2.0.jar > struts-1.1.jar@ > ant-jsch.jar@ commons-lang-2.0.jar jsp-api.jar@ > struts-1.2.jar@ > ant-junit.jar@ commons-lang.jar@ jsse.jar > xalan2.jar > ant-launcher.jar@ commons-launcher-1.1.jar junit-3.8.1.1.jar > xerces-1.4.4.jar > antlrall.jar@ commons-launcher.jar@ junit.jar@ > xercesImpl.jar > antlr.debug.jar@ commons-logging-1.0.4.jar > libreadline-java-0.8.0.jar xerces.jar@ > antlr.jar commons-logging-api-1.0.4.jar > libreadline-java.jar@ xml-apis.jar@ > ant-nodeps.jar@ commons-logging-api.jar@ log4j-1.2.13.jar > xmlParserAPIs.jar@ > ant-swing.jar@ commons-logging.jar@ log4j-1.2.jar@ > xt-0.20050823.jar > ant-trax.jar@ commons-modeler-1.1.jar lucene-1.4.3.jar > xt.jar@ > bcel-5.1.jar commons-modeler.jar@ > lucene-demos-1.4.3.jar > bcel.jar@ commons-pool-1.2.jar lucene-demos.jar@ > bsh-2.0b4.jar commons-pool.jar@ lucene.jar@ > > > > However, the items in the *JDEE bsh* classpath, except bsh.jar, are > not here, either. I don't know where "bsh-commands" and > "jakarta-regexp.jar" come from, there are not Debian packages by that > name. I did not have the package checkstyle installed. > > I have just installed the checkstyle package, which depended on the > libcommons-cli-java package, and it puts in a checkstyle.jar > (not "-all") into this directory. It seems that the bsh > command line is not correct for Debian? > > Thanks for your help, > Glenn > > > > On Wed, 8 Mar 2006, Suraj Acharya wrote: > > Glenn, > > > > You shouldn't need to add jde.jar to the CLASSPATH. Can you post the > > contents of the "*JDEE bsh*" buffer? > > > > Part of the problem might also be the fact that you are adding your home > > directory to the classpath. It seems to have a lot of symbolic links > which > > might be confusing the java compiler and JDE's class list code. Try > testing > > out JDE in a subdirectory of your home, something like /home/glenn/test. > > > > Suraj > > > > On 3/8/06, Glenn Murray <[email protected]> wrote: > >> > >> Hi, > >> > >> The jde package on Debian has been more or less broken the last > >> several years and I thought I would have a go at fixing it. > >> > >> The major problem is with bsh. I am using Debian Testing with JDEE > >> 2.3.5 and BeanShell 2.0b4. In a default install, an attempt to > >> compile a "Hello World" program with C-c C-v C-c results in the > >> following error: > >> > >> > >> Starting the BeanShell. Please wait... > >> Beanshell expression evaluation error. > >> Expression: jde.util.JdeUtilities.setProjectValues("", ""); > >> Error: // Error: EvalError: Class or variable not found: > >> jde.util.JdeUtilities : at Line: 1 : in file: <unknown file> : jde > >> .util .JdeUtilities .setProjectValues ( "" , "" ) > >> [2 times] > >> bsh: Beanshell eval error. See messages buffer for details. > >> > >> > >> Thinking this was a classpath error, I did "export > >> CLASSPATH=/usr/share/java/jde.jar" and restarted Emacs. This time C-c > >> C-v C-c gave me a compile buffer which contained: > >> > >> > >> > >> Updating class list for /home/glenn > >> > >> CompileServer output: > >> > >> -classpath /usr/share/java/jde.jar /home/glenn/Test.java Cannot read > >> contents of > >> /home/glenn/.wine/dosdevices/z: /usr/share/wine/skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/f: /skel/dosdevices/f: > >> /skel/dosdevices/f: /skel/dosdevices/z: /var/lib/kdm. > >> Cannot read contents of > >> /home/glenn/.wine/dosdevices/z:/usr/share/wine/skel/dosdev > >> > >> (Repeats with some variations many times) > >> > >> > >> Adding the current directory to the CLASSPATH helps: export > >> CLASSPATH="./:/usr/share/java/jde.jar" will make the compilation > >> worked once, but not again. After it finishes compiling, it says > >> "Updating class list for /home/glenn" and hangs there for some minutes > >> while the hard drive grinds away. A second attempt at compilation > >> gives the repeated error message above. It seems to be traversing the > >> file system. Run it again and get > >> > >> > >> CompileServer output: > >> > >> -classpath /home/glenn/:/usr/share/java/jde.jar /home/glenn/Test.java > >> > >> > >> The system is out of resources. > >> Consult the following stack trace for details. > >> java.lang.OutOfMemoryError: Java heap space > >> > >> Compilation exited abnormally with code 3 at Wed Mar 8 16:49:42 > >> > >> > >> Does anybody have any idea what is going on here? > >> > >> > >> Thanks, > >> Glenn > >> > >> > > >