summary refs log tree commit diff
path: root/gnu/packages/java.scm
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2018-02-28 22:13:12 +0100
committerRicardo Wurmus <rekado@elephly.net>2018-02-28 23:05:05 +0100
commitf201b18ed7d7f8ab640f2e571aad765cf3c572dd (patch)
tree0382041a9b0e59d88b2920cfe17528b01feeb5f7 /gnu/packages/java.scm
parentc1cb8576453db450493726ab44f34910dfa10ed7 (diff)
downloadguix-f201b18ed7d7f8ab640f2e571aad765cf3c572dd.tar.gz
gnu: Add java-ecj-3.5.
* gnu/packages/java.scm (java-ecj-3.5): New variable.
Diffstat (limited to 'gnu/packages/java.scm')
-rw-r--r--gnu/packages/java.scm31
1 files changed, 31 insertions, 0 deletions
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 4ea6f4d8c3..7a90bfba00 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2053,6 +2053,37 @@ Main-Class: org.eclipse.jdt.internal.compiler.batch.Main\n"
     (description "This package provides the Eclipse Java core batch compiler.")
     (license license:epl1.0)))
 
+;; This is needed for java-cisd-args4j
+(define-public java-ecj-3.5
+  (package (inherit java-ecj-3)
+    (version "3.5.1")
+    (source (origin
+              (method url-fetch/zipbomb)
+              (uri (string-append "http://archive.eclipse.org/eclipse/"
+                                  "downloads/drops/R-" version
+                                  "-200909170800/ecjsrc-" version ".zip"))
+              (sha256
+               (base32
+                "1vnl2mavisc567bip736xzsvvbjif5279wc4a7pbdik5wlir8qr7"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f ; none included
+       #:jdk ,icedtea-7 ; doesn't build with JDK8+
+       #:build-target "build"
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'fix-manifest
+           (lambda _
+             ;; Record the main class to make ecj executable.
+             (with-atomic-file-replacement "META-INF/MANIFEST.MF"
+               (lambda (in out)
+                 (dump-port in out)
+                 (display "Main-Class: org.eclipse.jdt.internal.compiler.batch.Main\n"
+                          out)))))
+         (replace 'install (install-jars ".")))))
+    (native-inputs
+     `(("unzip" ,unzip)))))
+
 (define-public java-classpathx-servletapi
   (package
     (name "java-classpathx-servletapi")