Patch to jde-eclipse-compiler-server.el
"Yee Keat Phuah" <[email protected]> Mon, 10 Dec 2007 09:50:41 +0800
| Newsgroups | gmane.emacs.jdee |
|---|---|
| Message-ID | <[email protected]> |
------=_Part_17699_21252725.1197251441449
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
Hi,
After understanding more about the problems that I was facing previously
while using jde-eclipse-compiler-server, realized that the hack it does to
the comint-mode might be causing the problem. I have reverted to use the
one-invocation-per-flymake method, which is documented as the first way to
use jde-eclipse-compiler-server with flymake in the source file.
There's a bug in the first method though, the classpath is not passed into
the ecj.jar correctly, here's a patch that fixed it for me:
--- jde-eclipse-compiler-server.el.orig 2007-12-10 09:43:51.101262700 +0800
+++ jde-eclipse-compiler-server.el 2007-12-10 09:44:58.840156000 +0800
@@ -431,8 +431,8 @@
(local-file (file-relative-name
temp-file
(file-name-directory buffer-file-name))))
- (list "java" (append (jde-compile-classpath-arg
(jde-compile-get-the-compiler))
- (list "-jar" (oref (jde-compile-get-ejc)
path) "-Xemacs")
+ (list "java" (append (list "-jar" (oref (jde-compile-get-ejc)
path) "-Xemacs")
+ (jde-compile-classpath-arg
(jde-compile-get-the-compiler))
jde-ecj-command-line-args
(list local-file))))))
------=_Part_17699_21252725.1197251441449
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
Hi,<br><br>After understanding more about the problems that I was facing previously while using jde-eclipse-compiler-server, realized that the hack it does to the comint-mode might be causing the problem. I have reverted to use the one-invocation-per-flymake method, which is documented as the first way to use jde-eclipse-compiler-server with flymake in the source file.
<br><br>There's a bug in the first method though, the classpath is not passed into the ecj.jar correctly, here's a patch that fixed it for me:<br><br>--- jde-eclipse-compiler-server.el.orig 2007-12-10 09:43:51.101262700
+0800<br>+++ jde-eclipse-compiler-server.el 2007-12-10 09:44:58.840156000 +0800<br>@@ -431,8 +431,8 @@<br> (local-file (file-relative-name<br> temp-file<br> (file-name-directory buffer-file-name))))
<br>- (list "java" (append (jde-compile-classpath-arg (jde-compile-get-the-compiler))<br>- (list "-jar" (oref (jde-compile-get-ejc) path) "-Xemacs")<br>+ (list "java" (append (list "-jar" (oref (jde-compile-get-ejc) path) "-Xemacs")
<br>+ (jde-compile-classpath-arg (jde-compile-get-the-compiler))<br> jde-ecj-command-line-args<br> (list local-file))))))<br><br><br>
------=_Part_17699_21252725.1197251441449--