1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015, 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
3 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
4 ;;; Copyright © 2016, 2017 Roel Janssen <roel@gnu.org>
5 ;;; Copyright © 2017 Carlo Zancanaro <carlo@zancanaro.id.au>
6 ;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu>
7 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
9 ;;; This file is part of GNU Guix.
11 ;;; GNU Guix is free software; you can redistribute it and/or modify it
12 ;;; under the terms of the GNU General Public License as published by
13 ;;; the Free Software Foundation; either version 3 of the License, or (at
14 ;;; your option) any later version.
16 ;;; GNU Guix is distributed in the hope that it will be useful, but
17 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 ;;; GNU General Public License for more details.
21 ;;; You should have received a copy of the GNU General Public License
22 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24 (define-module (gnu packages java)
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (guix packages)
27 #:use-module (guix download)
28 #:use-module (guix hg-download)
29 #:use-module (guix git-download)
30 #:use-module (guix utils)
31 #:use-module (guix build-system ant)
32 #:use-module (guix build-system gnu)
33 #:use-module (guix build-system trivial)
34 #:use-module (gnu packages)
35 #:use-module (gnu packages attr)
36 #:use-module (gnu packages autotools)
37 #:use-module (gnu packages base)
38 #:use-module (gnu packages bash)
39 #:use-module (gnu packages certs)
40 #:use-module (gnu packages cpio)
41 #:use-module (gnu packages cups)
42 #:use-module (gnu packages compression)
43 #:use-module (gnu packages fontutils)
44 #:use-module (gnu packages gawk)
45 #:use-module (gnu packages gettext)
46 #:use-module (gnu packages gcc)
47 #:use-module (gnu packages gl)
48 #:use-module (gnu packages gnuzilla) ;nss
49 #:use-module (gnu packages ghostscript) ;lcms
50 #:use-module (gnu packages gnome)
51 #:use-module (gnu packages gtk)
52 #:use-module (gnu packages guile)
53 #:use-module (gnu packages icu4c)
54 #:use-module (gnu packages image)
55 #:use-module (gnu packages libffi)
56 #:use-module (gnu packages linux) ;alsa
57 #:use-module (gnu packages web)
58 #:use-module (gnu packages wget)
59 #:use-module (gnu packages pkg-config)
60 #:use-module (gnu packages perl)
61 #:use-module (gnu packages popt)
62 #:use-module (gnu packages kerberos)
63 #:use-module (gnu packages xml)
64 #:use-module (gnu packages xorg)
65 #:use-module (gnu packages texinfo)
66 #:use-module ((srfi srfi-1) #:select (fold alist-delete))
67 #:use-module (srfi srfi-11)
68 #:use-module (ice-9 match))
72 ;;; Java bootstrap toolchain.
75 ;; The Java bootstrap begins with Jikes, a Java compiler written in C++. We
76 ;; use it to build the SableVM standard library and virtual machine, which are
77 ;; written in a simpler dialect of Java and C, respectively. This is
78 ;; sufficient to build an older version of Ant, which is needed to build an
79 ;; older version of ECJ, an incremental Java compiler, both of which are
82 ;; ECJ is needed to build the latest release of GNU Classpath (0.99).
83 ;; Classpath (> 0.98) is a requirement for JamVM, a more modern implementation
84 ;; of the Java virtual machine.
86 ;; With JamVM we can build the latest development version of GNU Classpath,
87 ;; which has much more support for Java 1.6 than the latest release. Since
88 ;; the previous build of JamVM is limited by the use of GNU Classpath 0.99 we
89 ;; rebuild it with the latest development version of GNU Classpath.
91 ;; Finally, we use the bootstrap toolchain to build the OpenJDK with the
92 ;; Icedtea 1.x build framework. We then build the more recent JDKs Icedtea
93 ;; 2.x and Icedtea 3.x.
101 (uri (string-append "mirror://sourceforge/jikes/Jikes/"
102 version "/jikes-" version ".tar.bz2"))
105 "1qqldrp74pzpy5ly421srqn30qppmm9cvjiqdngk8hf47dv2rc0c"))))
106 (build-system gnu-build-system)
107 (home-page "http://jikes.sourceforge.net/")
108 (synopsis "Compiler for the Java language")
109 (description "Jikes is a compiler that translates Java source files as
110 defined in The Java Language Specification into the bytecoded instruction set
111 and binary format defined in The Java Virtual Machine Specification.")
112 (license license:ibmpl1.0)))
114 (define sablevm-classpath
116 (name "sablevm-classpath")
120 (uri (string-append "mirror://sourceforge/sablevm/sablevm/"
121 version "/sablevm-classpath-" version ".tar.gz"))
124 "1qyhyfz8idghxdam16hdgpa24r2x4xbg9z8c8asa3chnd79h3zw2"))))
125 (build-system gnu-build-system)
142 ("pkg-config" ,pkg-config)))
143 (home-page "http://sablevm.org/")
144 (synopsis "Java Virtual Machine")
145 (description "SableVM is a clean-room, highly portable and efficient Java
146 virtual machine. Its goals are to be reasonably small, fast, and compliant
147 with the various specifications (JVM specification, JNI, invocation interface,
148 etc.). SableVM is no longer maintained.
150 This package provides the classpath library.")
151 (license license:lgpl2.1+)))
159 (uri (string-append "mirror://sourceforge/sablevm/sablevm/"
160 version "/sablevm-" version ".tar.gz"))
163 "1jyg4bsym6igz94wps5443c7wiwlzinqzkchcw972nz4kf1cql6g"))))
164 (build-system gnu-build-system)
167 (list "--with-internal-libffi=no"
168 "--with-internal-libpopt=no")
170 (modify-phases %standard-phases
171 (add-after 'unpack 'remove-timestamp-for-reproducibility
173 (substitute* "src/sablevm/Makefile.in"
174 (("\\$\\(SVMCOMPILETIME\\)") "(unknown)"))
176 (add-after 'unpack 'link-with-popt
178 (substitute* "src/sablevm/Makefile.in"
179 (("\\$\\(SVMADD\\)" match)
180 (string-append match " -lpopt")))
182 (add-after 'unpack 'patch-path-to-classpath
183 (lambda* (#:key inputs #:allow-other-keys)
184 (substitute* "Makefile.in"
185 (("@datadir@/sablevm-classpath")
186 (string-append (assoc-ref inputs "classpath")
187 "/share/sablevm-classpath")))
188 (substitute* "src/libsablevm/Makefile.in"
189 (("\\$\\(libdir\\)/sablevm-classpath")
190 (string-append (assoc-ref inputs "classpath")
191 "/lib/sablevm-classpath"))
192 (("\\$\\(datadir\\)/sablevm-classpath")
193 (string-append (assoc-ref inputs "classpath")
194 "/share/sablevm-classpath")))
197 `(("classpath" ,sablevm-classpath)
203 `(("libltdl" ,libltdl)))
204 (home-page "http://sablevm.org/")
205 (synopsis "Java Virtual Machine")
206 (description "SableVM is a clean-room, highly portable and efficient Java
207 virtual machine. Its goals are to be reasonably small, fast, and compliant
208 with the various specifications (JVM specification, JNI, invocation interface,
209 etc.). SableVM is no longer maintained.
211 This package provides the virtual machine.")
212 (license license:lgpl2.1+)))
214 (define ant-bootstrap
216 (name "ant-bootstrap")
217 ;; The 1.10.x series requires Java 8. 1.9.0 and later use generics, which
218 ;; are not supported. The 1.8.x series is the last to use only features
219 ;; supported by Jikes, but it cannot seem to be built with sablevm.
223 (uri (string-append "http://archive.apache.org/dist/"
224 "ant/source/apache-ant-"
225 version "-src.tar.bz2"))
228 "19pvqvgkxgpgsqm4lvbki5sm0z84kxmykdqicvfad47gc1r9mi2d"))))
229 (build-system gnu-build-system)
231 `(#:tests? #f ; no "check" target
233 (modify-phases %standard-phases
236 (lambda* (#:key inputs #:allow-other-keys)
238 (string-append (assoc-ref inputs "sablevm")
241 (string-append (assoc-ref inputs "sablevm")
242 "/bin/java-sablevm"))
244 (string-append (assoc-ref inputs "sablevm")
245 "/bin/javac-sablevm"))
247 ;; Use jikes instead of javac for <javac ...> tags in build.xml
248 (setenv "ANT_OPTS" "-Dbuild.compiler=jikes")
250 ;; jikes produces lots of warnings, but they are not very
251 ;; interesting, so we silence them.
252 (setenv "$BOOTJAVAC_OPTS" "-nowarn")
254 ;; Disable tests because we are bootstrapping and thus don't have
255 ;; any of the dependencies required to build and run the tests.
256 (substitute* "build.xml"
257 (("depends=\"jars,test-jar\"") "depends=\"jars\""))
258 (zero? (system* "bash" "bootstrap.sh"
259 (string-append "-Ddist.dir="
260 (assoc-ref %outputs "out"))))))
264 ("sablevm" ,sablevm)))
265 (home-page "http://ant.apache.org")
266 (synopsis "Build tool for Java")
268 "Ant is a platform-independent build tool for Java. It is similar to
269 make but is implemented using the Java language, requires the Java platform,
270 and is best suited to building Java projects. Ant uses XML to describe the
271 build process and its dependencies, whereas Make uses Makefile format.")
272 (license license:asl2.0)))
274 ;; Version 3.2.2 is the last version without a dependency on a full-fledged
275 ;; compiler for Java 1.5.
276 (define ecj-bootstrap
278 (name "ecj-bootstrap")
282 (uri (string-append "http://archive.eclipse.org/eclipse/"
283 "downloads/drops/R-" version
284 "-200702121330/ecjsrc.zip"))
287 "05hj82kxd23qaglsjkaqcj944riisjha7acf7h3ljhrjyljx8307"))))
288 ;; It would be so much easier if we could use the ant-build-system, but we
289 ;; cannot as we don't have ant at this point. We use ecj for
290 ;; bootstrapping the JDK.
291 (build-system gnu-build-system)
293 `(#:modules ((guix build gnu-build-system)
296 #:tests? #f ; there are no tests
298 (modify-phases %standard-phases
300 (lambda* (#:key inputs #:allow-other-keys)
303 (find-files (string-append (assoc-ref inputs "ant-bootstrap")
309 (lambda* (#:key inputs #:allow-other-keys)
310 ;; The unpack phase enters the "org" directory by mistake.
313 ;; Create a simple manifest to make ecj executable.
314 (with-output-to-file "manifest"
316 (display "Manifest-Version: 1.0
317 Main-Class: org.eclipse.jdt.internal.compiler.batch.Main\n")))
320 (and (zero? (apply system* "javac-sablevm"
321 (find-files "." "\\.java$")))
322 (zero? (system* "fastjar" "cvfm"
323 "ecj-bootstrap.jar" "manifest" ".")))))
325 (lambda* (#:key outputs #:allow-other-keys)
326 (let ((share (string-append (assoc-ref outputs "out")
329 (install-file "ecj-bootstrap.jar" share)
332 `(("ant-bootstrap" ,ant-bootstrap)
335 ("fastjar" ,fastjar)))
336 (home-page "https://eclipse.org")
337 (synopsis "Eclipse Java development tools core batch compiler")
338 (description "This package provides the Eclipse Java core batch compiler
339 for bootstrapping purposes. The @dfn{Eclipse compiler for Java} (ecj) is a
340 requirement for all GNU Classpath releases after version 0.93.")
341 (license license:epl1.0)))
343 (define ecj-javac-wrapper
344 (package (inherit ecj-bootstrap)
345 (name "ecj-javac-wrapper")
347 (build-system trivial-build-system)
349 `(#:modules ((guix build utils))
351 (let ((backend 'sablevm))
352 (use-modules (guix build utils))
353 (let* ((bin (string-append (assoc-ref %outputs "out") "/bin"))
354 (target (string-append bin "/javac"))
355 (guile (string-append (assoc-ref %build-inputs "guile")
357 (ecj (string-append (assoc-ref %build-inputs "ecj-bootstrap")
358 "/share/java/ecj-bootstrap.jar"))
361 (string-append (assoc-ref %build-inputs "sablevm")
362 "/lib/sablevm/bin/java"))
364 (string-append (assoc-ref %build-inputs "jamvm")
366 (bootcp (case backend
368 (let ((jvmlib (string-append
369 (assoc-ref %build-inputs "sablevm-classpath")
371 (string-append jvmlib "/jre/lib/rt.jar")))
373 (let ((jvmlib (string-append (assoc-ref %build-inputs "classpath")
374 "/share/classpath")))
375 (string-append jvmlib "/lib/glibj.zip:"
376 jvmlib "/lib/tools.zip"))))))
378 (with-output-to-file target
380 (format #t "#!~a --no-auto-compile\n!#\n" guile)
382 `(begin (use-modules (ice-9 match)
388 '(("-bootclasspath" ,bootcp)
393 (let ((classpath (getenv "CLASSPATH")))
397 (string-append ":" classpath)
399 (receive (vm-args other-args)
400 ;; Separate VM arguments from arguments to ECJ.
401 (partition (cut string-prefix? "-J" <>)
402 (fold (lambda (default acc)
403 (if (member (first default) acc)
404 acc (append default acc)))
408 ;; Remove "-J" prefix
409 (map (cut string-drop <> 2) vm-args)
410 '("org.eclipse.jdt.internal.compiler.batch.Main")
411 (cons "-nowarn" other-args)))))
413 (let ((args (cdr (command-line))))
415 (format (current-error-port) "javac: no arguments given!\n")
420 `(("guile" ,guile-2.2)
421 ("ecj-bootstrap" ,ecj-bootstrap)
423 ("sablevm-classpath" ,sablevm-classpath)))
424 (description "This package provides a wrapper around the @dfn{Eclipse
425 compiler for Java} (ecj) with a command line interface that is compatible with
426 the standard javac executable.")))
428 ;; Note: All the tool wrappers (e.g. for javah, javac, etc) fail with
429 ;; java.lang.UnsupportedClassVersionError. They simply won't run on the old
430 ;; sablevm. We use Classpath 0.99 to build JamVM, on which the Classpath
431 ;; tools do run. Using these Classpath tools on JamVM we can then build the
432 ;; development version of GNU Classpath.
433 (define classpath-on-sablevm
439 (uri (string-append "mirror://gnu/classpath/classpath-"
443 "1j7cby4k66f1nvckm48xcmh352b1d1b33qk7l6hi7dp9i9zjjagr"))))
444 (build-system gnu-build-system)
447 (list (string-append "--with-ecj-jar="
448 (assoc-ref %build-inputs "ecj-bootstrap")
449 "/share/java/ecj-bootstrap.jar")
450 (string-append "JAVAC="
451 (assoc-ref %build-inputs "ecj-javac-wrapper")
453 (string-append "JAVA="
454 (assoc-ref %build-inputs "sablevm")
457 "ac_cv_prog_java_works=yes" ; trust me
461 "--disable-gconf-peer"
467 (modify-phases %standard-phases
468 (add-after 'install 'install-data
469 (lambda _ (zero? (system* "make" "install-data")))))))
471 `(("ecj-bootstrap" ,ecj-bootstrap)
472 ("ecj-javac-wrapper" ,ecj-javac-wrapper)
475 ("sablevm-classpath" ,sablevm-classpath)
477 ("pkg-config" ,pkg-config)))
478 (home-page "https://www.gnu.org/software/classpath/")
479 (synopsis "Essential libraries for Java")
480 (description "GNU Classpath is a project to create core class libraries
481 for use with runtimes, compilers and tools for the Java programming
483 ;; GPLv2 or later, with special linking exception.
484 (license license:gpl2+)))
486 (define jamvm-bootstrap
492 (uri (string-append "mirror://sourceforge/jamvm/jamvm/"
493 "JamVM%20" version "/jamvm-"
497 "1nl0zxz8y5x8gwsrm7n32bry4dx8x70p8z3s9jbdvs8avyb8whkn"))))
498 (build-system gnu-build-system)
501 (list (string-append "--with-classpath-install-dir="
502 (assoc-ref %build-inputs "classpath")))))
504 `(("classpath" ,classpath-on-sablevm)
505 ("ecj-javac-wrapper" ,ecj-javac-wrapper)
507 (home-page "http://jamvm.sourceforge.net/")
508 (synopsis "Small Java Virtual Machine")
509 (description "JamVM is a Java Virtual Machine conforming to the JVM
510 specification edition 2 (blue book). It is extremely small. However, unlike
511 other small VMs it supports the full spec, including object finalisation and
513 (license license:gpl2+)))
515 ;; We need this because the tools provided by the latest release of GNU
516 ;; Classpath don't actually work with sablevm.
517 (define classpath-jamvm-wrappers
518 (package (inherit classpath-on-sablevm)
519 (name "classpath-jamvm-wrappers")
521 (build-system trivial-build-system)
523 `(#:modules ((guix build utils))
526 (use-modules (guix build utils))
527 (let* ((bash (assoc-ref %build-inputs "bash"))
528 (jamvm (assoc-ref %build-inputs "jamvm"))
529 (classpath (assoc-ref %build-inputs "classpath"))
530 (bin (string-append (assoc-ref %outputs "out")
533 (for-each (lambda (tool)
534 (with-output-to-file (string-append bin tool)
536 (format #t "#!~a/bin/sh
537 ~a/bin/jamvm -classpath ~a/share/classpath/tools.zip \
538 gnu.classpath.tools.~a.~a $@"
539 bash jamvm classpath tool
540 (if (string=? "native2ascii" tool)
541 "Native2ASCII" "Main"))))
542 (chmod (string-append bin tool) #o755))
552 ("jamvm" ,jamvm-bootstrap)
553 ("classpath" ,classpath-on-sablevm)))
555 (synopsis "Executables from GNU Classpath")
556 (description "This package provides wrappers around the tools provided by
557 the GNU Classpath library. They are executed by the JamVM virtual
560 (define ecj-javac-on-jamvm-wrapper
561 (package (inherit ecj-javac-wrapper)
562 (name "ecj-javac-on-jamvm-wrapper")
564 `(#:modules ((guix build utils))
566 ;; TODO: This builder is exactly the same as in ecj-javac-wrapper,
567 ;; except that the backend is 'jamvm here. Can we reuse the same
569 (let ((backend 'jamvm))
570 (use-modules (guix build utils))
571 (let* ((bin (string-append (assoc-ref %outputs "out") "/bin"))
572 (target (string-append bin "/javac"))
573 (guile (string-append (assoc-ref %build-inputs "guile")
575 (ecj (string-append (assoc-ref %build-inputs "ecj-bootstrap")
576 "/share/java/ecj-bootstrap.jar"))
579 (string-append (assoc-ref %build-inputs "sablevm")
580 "/lib/sablevm/bin/java"))
582 (string-append (assoc-ref %build-inputs "jamvm")
584 (bootcp (case backend
586 (let ((jvmlib (string-append
587 (assoc-ref %build-inputs "sablevm-classpath")
589 (string-append jvmlib "/jre/lib/rt.jar")))
591 (let ((jvmlib (string-append (assoc-ref %build-inputs "classpath")
592 "/share/classpath")))
593 (string-append jvmlib "/lib/glibj.zip:"
594 jvmlib "/lib/tools.zip"))))))
596 (with-output-to-file target
598 (format #t "#!~a --no-auto-compile\n!#\n" guile)
600 `(begin (use-modules (ice-9 match)
606 '(("-bootclasspath" ,bootcp)
611 (let ((classpath (getenv "CLASSPATH")))
615 (string-append ":" classpath)
617 (receive (vm-args other-args)
618 ;; Separate VM arguments from arguments to ECJ.
619 (partition (cut string-prefix? "-J" <>)
620 (fold (lambda (default acc)
621 (if (member (first default) acc)
622 acc (append default acc)))
626 ;; Remove "-J" prefix
627 (map (cut string-drop <> 2) vm-args)
628 '("org.eclipse.jdt.internal.compiler.batch.Main")
629 (cons "-nowarn" other-args)))))
631 (let ((args (cdr (command-line))))
633 (format (current-error-port) "javac: no arguments given!\n")
638 `(("guile" ,guile-2.2)
639 ("ecj-bootstrap" ,ecj-bootstrap)
640 ("jamvm" ,jamvm-bootstrap)
641 ("classpath" ,classpath-on-sablevm)))
642 (description "This package provides a wrapper around the @dfn{Eclipse
643 compiler for Java} (ecj) with a command line interface that is compatible with
644 the standard javac executable. The tool runs on JamVM instead of SableVM.")))
646 ;; The last release of GNU Classpath is 0.99 and it happened in 2012. Since
647 ;; then Classpath has gained much more support for Java 1.6.
648 (define-public classpath-devel
649 (let ((commit "e7c13ee0cf2005206fbec0eca677f8cf66d5a103")
651 (package (inherit classpath-on-sablevm)
652 (version (string-append "0.99-" revision "." (string-take commit 9)))
656 (url "https://git.savannah.gnu.org/git/classpath.git")
658 (file-name (string-append "classpath-" version "-checkout"))
661 "1v2rww76ww322mpg3s12a1kkc6gkp31bm9gcxs532h0wq285fiw4"))))
664 ;; Ensure that the initial heap size is smaller than the maximum
665 ;; size. By default only Xmx is set, which can lead to invalid
666 ;; memory settings on some machines with a lot of memory.
667 '("JAVAC_MEM_OPT=-J-Xms512M -J-Xmx768M")
669 (list (string-append "--with-ecj-jar="
670 (assoc-ref %build-inputs "ecj-bootstrap")
671 "/share/java/ecj-bootstrap.jar")
672 (string-append "--with-javac="
673 (assoc-ref %build-inputs "ecj-javac-wrapper")
675 (string-append "JAVA="
676 (assoc-ref %build-inputs "jamvm")
679 "ac_cv_prog_java_works=yes" ; trust me
683 "--disable-gconf-peer"
689 (modify-phases %standard-phases
690 (add-after 'unpack 'bootstrap
692 (zero? (system* "autoreconf" "-vif"))))
693 (add-after 'unpack 'remove-unsupported-annotations
695 (substitute* (find-files "java" "\\.java$")
698 (add-after 'install 'install-data
699 (lambda _ (zero? (system* "make" "install-data")))))))
701 `(("autoconf" ,autoconf)
702 ("automake" ,automake)
704 ("gettext" ,gettext-minimal)
706 ("classpath-jamvm-wrappers" ,classpath-jamvm-wrappers) ; for javah
707 ("ecj-bootstrap" ,ecj-bootstrap)
708 ("ecj-javac-wrapper" ,ecj-javac-on-jamvm-wrapper)
710 ("jamvm" ,jamvm-bootstrap)
712 ("pkg-config" ,pkg-config))))))
715 (package (inherit jamvm-bootstrap)
717 `(("classpath" ,classpath-devel)
718 ("ecj-javac-wrapper" ,ecj-javac-on-jamvm-wrapper)
721 (define ecj-javac-on-jamvm-wrapper-final
722 (package (inherit ecj-javac-on-jamvm-wrapper)
724 `(("guile" ,guile-2.2)
725 ("ecj-bootstrap" ,ecj-bootstrap)
727 ("classpath" ,classpath-devel)))))
729 ;; The bootstrap JDK consisting of jamvm, classpath-devel,
730 ;; ecj-javac-on-jamvm-wrapper-final cannot build Icedtea 2.x directly, because
731 ;; it's written in Java 7. It can, however, build the unmaintained Icedtea
732 ;; 1.x, which uses Java 6 only.
733 (define-public icedtea-6
740 "http://icedtea.wildebeest.org/download/source/icedtea6-"
744 "0bg9sb4f7qbq77c0zf9m17p47ga0kf0r9622g9p12ysg26jd1ksg"))
745 (modules '((guix build utils)))
747 '(substitute* "Makefile.in"
748 ;; do not leak information about the build host
749 (("DISTRIBUTION_ID=\"\\$\\(DIST_ID\\)\"")
750 "DISTRIBUTION_ID=\"\\\"guix\\\"\"")))))
751 (build-system gnu-build-system)
752 (outputs '("out" ; Java Runtime Environment
753 "jdk" ; Java Development Kit
754 "doc")) ; all documentation
756 `(;; There are many failing tests and many are known to fail upstream.
759 ;; The DSOs use $ORIGIN to refer to each other, but (guix build
760 ;; gremlin) doesn't support it yet, so skip this phase.
761 #:validate-runpath? #f
763 #:modules ((guix build utils)
764 (guix build gnu-build-system)
768 `("--enable-bootstrap"
771 "--with-parallel-jobs"
772 "--disable-downloading"
774 ,(string-append "--with-ecj="
775 (assoc-ref %build-inputs "ecj")
776 "/share/java/ecj-bootstrap.jar")
777 ,(string-append "--with-jar="
778 (assoc-ref %build-inputs "fastjar")
780 ,(string-append "--with-jdk-home="
781 (assoc-ref %build-inputs "classpath"))
782 ,(string-append "--with-java="
783 (assoc-ref %build-inputs "jamvm")
786 (modify-phases %standard-phases
788 (lambda* (#:key source inputs #:allow-other-keys)
789 (and (zero? (system* "tar" "xvf" source))
791 (chdir (string-append "icedtea6-" ,version))
793 (copy-recursively (assoc-ref inputs "openjdk-src") "openjdk")
794 ;; The convenient OpenJDK source bundle is no longer
795 ;; available for download, so we have to take the sources
796 ;; from the Mercurial repositories and change the Makefile
797 ;; to avoid tests for the OpenJDK zip archive.
798 (with-directory-excursion "openjdk"
799 (for-each (lambda (part)
803 (string-append part "-src"))
805 '("jdk" "hotspot" "corba"
806 "langtools" "jaxp" "jaxws")))
807 (substitute* "Makefile.in"
808 (("echo \"ERROR: No up-to-date OpenJDK zip available\"; exit -1;")
809 "echo \"trust me\";")
810 ;; The contents of the bootstrap directory must be
811 ;; writeable but when copying from the store they are
813 (("mkdir -p lib/rt" line)
814 (string-append line "; chmod -R u+w $(BOOT_DIR)")))
815 (zero? (system* "chmod" "-R" "u+w" "openjdk"))
817 (add-after 'unpack 'use-classpath
818 (lambda* (#:key inputs #:allow-other-keys)
819 (let ((jvmlib (assoc-ref inputs "classpath")))
820 ;; Classpath does not provide rt.jar.
821 (substitute* "Makefile.in"
822 (("\\$\\(SYSTEM_JDK_DIR\\)/jre/lib/rt.jar")
823 (string-append jvmlib "/share/classpath/glibj.zip")))
824 ;; Make sure we can find all classes.
826 (string-append jvmlib "/share/classpath/glibj.zip:"
827 jvmlib "/share/classpath/tools.zip"))
829 (string-append "-cp "
830 jvmlib "/share/classpath/glibj.zip:"
831 jvmlib "/share/classpath/tools.zip")))
833 (add-after 'unpack 'patch-patches
835 ;; shebang in patches so that they apply cleanly
836 (substitute* '("patches/jtreg-jrunscript.patch"
837 "patches/hotspot/hs23/drop_unlicensed_test.patch")
838 (("#!/bin/sh") (string-append "#!" (which "sh"))))
840 (add-after 'unpack 'patch-paths
841 (lambda* (#:key inputs #:allow-other-keys)
842 ;; buildtree.make generates shell scripts, so we need to replace
843 ;; the generated shebang
844 (substitute* '("openjdk/hotspot/make/linux/makefiles/buildtree.make")
845 (("/bin/sh") (which "bash")))
847 (let ((corebin (string-append
848 (assoc-ref inputs "coreutils") "/bin/"))
849 (binbin (string-append
850 (assoc-ref inputs "binutils") "/bin/"))
851 (grepbin (string-append
852 (assoc-ref inputs "grep") "/bin/")))
853 (substitute* '("openjdk/jdk/make/common/shared/Defs-linux.gmk"
854 "openjdk/corba/make/common/shared/Defs-linux.gmk")
855 (("UNIXCOMMAND_PATH = /bin/")
856 (string-append "UNIXCOMMAND_PATH = " corebin))
857 (("USRBIN_PATH = /usr/bin/")
858 (string-append "USRBIN_PATH = " corebin))
859 (("DEVTOOLS_PATH *= */usr/bin/")
860 (string-append "DEVTOOLS_PATH = " corebin))
861 (("COMPILER_PATH *= */usr/bin/")
862 (string-append "COMPILER_PATH = "
863 (assoc-ref inputs "gcc") "/bin/"))
864 (("DEF_OBJCOPY *=.*objcopy")
865 (string-append "DEF_OBJCOPY = " (which "objcopy"))))
867 ;; fix path to alsa header
868 (substitute* "openjdk/jdk/make/common/shared/Sanity.gmk"
869 (("ALSA_INCLUDE=/usr/include/alsa/version.h")
870 (string-append "ALSA_INCLUDE="
871 (assoc-ref inputs "alsa-lib")
872 "/include/alsa/version.h")))
874 ;; fix hard-coded utility paths
875 (substitute* '("openjdk/jdk/make/common/shared/Defs-utils.gmk"
876 "openjdk/corba/make/common/shared/Defs-utils.gmk")
878 (string-append "ECHO = " (which "echo")))
880 (string-append "GREP = " (which "grep")))
882 (string-append "EGREP = " (which "egrep")))
884 (string-append "CPIO = " (which "cpio")))
885 (("READELF *=.*readelf")
886 (string-append "READELF = " (which "readelf")))
888 (string-append "AR = " (which "ar")))
890 (string-append "TAR = " (which "tar")))
892 (string-append "AS = " (which "as")))
894 (string-append "LD = " (which "ld")))
896 (string-append "STRIP = " (which "strip")))
898 (string-append "NM = " (which "nm")))
900 (string-append "SH = " (which "bash")))
902 (string-append "FIND = " (which "find")))
904 (string-append "LDD = " (which "ldd")))
905 (("NAWK *=.*(n|g)awk")
906 (string-append "NAWK = " (which "gawk")))
908 (string-append "XARGS = " (which "xargs")))
910 (string-append "UNZIP = " (which "unzip")))
912 (string-append "ZIPEXE = " (which "zip")))
914 (string-append "SED = " (which "sed"))))
916 ;; Some of these timestamps cause problems as they are more than
917 ;; 10 years ago, failing the build process.
919 "openjdk/jdk/src/share/classes/java/util/CurrencyData.properties"
920 (("AZ=AZM;2005-12-31-20-00-00;AZN") "AZ=AZN")
921 (("MZ=MZM;2006-06-30-22-00-00;MZN") "MZ=MZN")
922 (("RO=ROL;2005-06-30-21-00-00;RON") "RO=RON")
923 (("TR=TRL;2004-12-31-22-00-00;TRY") "TR=TRY"))
925 (add-before 'configure 'set-additional-paths
926 (lambda* (#:key inputs #:allow-other-keys)
928 (string-append (assoc-ref inputs "libxrender")
929 "/include/X11/extensions" ":"
930 (assoc-ref inputs "libxtst")
931 "/include/X11/extensions" ":"
932 (assoc-ref inputs "libxinerama")
933 "/include/X11/extensions" ":"
934 (or (getenv "CPATH") "")))
935 (setenv "ALT_CUPS_HEADERS_PATH"
936 (string-append (assoc-ref inputs "cups")
938 (setenv "ALT_FREETYPE_HEADERS_PATH"
939 (string-append (assoc-ref inputs "freetype")
941 (setenv "ALT_FREETYPE_LIB_PATH"
942 (string-append (assoc-ref inputs "freetype")
946 (lambda* (#:key outputs #:allow-other-keys)
947 (let ((doc (string-append (assoc-ref outputs "doc")
948 "/share/doc/icedtea"))
949 (jre (assoc-ref outputs "out"))
950 (jdk (assoc-ref outputs "jdk")))
951 (copy-recursively "openjdk.build/docs" doc)
952 (copy-recursively "openjdk.build/j2re-image" jre)
953 (copy-recursively "openjdk.build/j2sdk-image" jdk))
956 `(("ant" ,ant-bootstrap)
957 ("alsa-lib" ,alsa-lib)
959 ("classpath" ,classpath-devel)
960 ("coreutils" ,coreutils)
963 ("ecj" ,ecj-bootstrap)
964 ("ecj-javac" ,ecj-javac-on-jamvm-wrapper-final)
966 ("fontconfig" ,fontconfig)
967 ("freetype" ,freetype)
978 ("libxcomposite" ,libxcomposite)
980 ("libxinerama" ,libxinerama)
981 ("libxrender" ,libxrender)
982 ("libxslt" ,libxslt) ;for xsltproc
985 ("mit-krb5" ,mit-krb5)
987 ("nss-certs" ,nss-certs)
989 ("pkg-config" ,pkg-config)
990 ("procps" ,procps) ;for "free", even though I'm not sure we should use it
1000 (url "http://hg.openjdk.java.net/jdk6/jdk6/")
1001 (changeset "jdk6-b41")))
1004 "14q47yfg586fs64w30g8mk92m5dkxsvr36zzh0ra99xk5x0x96mv"))))
1009 (url "http://hg.openjdk.java.net/jdk6/jdk6/jdk/")
1010 (changeset "jdk6-b41")))
1013 "165824nhg1k1dx6zs9dny0j49rmk35jw5b13dmz8c77jfajml4v9"))))
1018 (url "http://hg.openjdk.java.net/jdk6/jdk6/hotspot/")
1019 (changeset "jdk6-b41")))
1022 "07lc1z4k5dj9nrc1wvwmpvxr3xgxrdkdh53xb95skk5ij49yagfd"))))
1027 (url "http://hg.openjdk.java.net/jdk6/jdk6/corba/")
1028 (changeset "jdk6-b41")))
1031 "1p9g1r9dnax2iwp7yb59qx7m4nmshqhwmrb2b8jj8zgbd9dl2i3q"))))
1036 (url "http://hg.openjdk.java.net/jdk6/jdk6/langtools/")
1037 (changeset "jdk6-b41")))
1040 "1x52wd67fynbbd9ild6fb4wvba3f5hhwk03qdjfazd0a1qr37z3d"))))
1045 (url "http://hg.openjdk.java.net/jdk6/jdk6/jaxp/")
1046 (changeset "jdk6-b41")))
1049 "0shlqrvzpr4nrkmv215lbxnby63s3yvbdh1yxcayznsyqwa4nlxm"))))
1054 (url "http://hg.openjdk.java.net/jdk6/jdk6/jaxws/")
1055 (changeset "jdk6-b41")))
1058 "0835lkw8vib1xhp8lxnybhlvzdh699hbi4mclxanydjk63zbpxk0"))))))
1059 (home-page "http://icedtea.classpath.org")
1060 (synopsis "Java development kit")
1062 "This package provides the OpenJDK built with the IcedTea build harness.
1063 This version of the OpenJDK is no longer maintained and is only used for
1064 bootstrapping purposes.")
1065 ;; IcedTea is released under the GPL2 + Classpath exception, which is the
1066 ;; same license as both GNU Classpath and OpenJDK.
1067 (license license:gpl2+)))
1069 (define-public icedtea-7
1070 (let* ((version "2.6.11")
1071 (drop (lambda (name hash)
1075 "http://icedtea.classpath.org/download/drops"
1076 "/icedtea7/" version "/" name ".tar.bz2"))
1077 (sha256 (base32 hash))))))
1084 "http://icedtea.wildebeest.org/download/source/icedtea-"
1088 "1ibp6ybqnf8g7mbs45bkbv44dwz4h2w9gr4rh15yvr1m8lqkq1i0"))
1089 (modules '((guix build utils)))
1091 '(substitute* "Makefile.in"
1092 ;; do not leak information about the build host
1093 (("DISTRIBUTION_ID=\"\\$\\(DIST_ID\\)\"")
1094 "DISTRIBUTION_ID=\"\\\"guix\\\"\"")))))
1095 (build-system gnu-build-system)
1096 (outputs '("out" ; Java Runtime Environment
1097 "jdk" ; Java Development Kit
1098 "doc")) ; all documentation
1100 `(;; There are many test failures. Some are known to
1101 ;; fail upstream, others relate to not having an X
1102 ;; server running at test time, yet others are a
1103 ;; complete mystery to me.
1105 ;; hotspot: passed: 241; failed: 45; error: 2
1106 ;; langtools: passed: 1,934; failed: 26
1110 ;; The DSOs use $ORIGIN to refer to each other, but (guix build
1111 ;; gremlin) doesn't support it yet, so skip this phase.
1112 #:validate-runpath? #f
1114 ;; Apparently, the C locale is needed for some of the tests.
1117 #:modules ((guix build utils)
1118 (guix build gnu-build-system)
1125 ;; TODO: package pcsc and sctp, and add to inputs
1126 `("--disable-system-pcsc"
1127 "--disable-system-sctp"
1128 "--enable-bootstrap"
1131 "--disable-downloading"
1132 "--disable-tests" ;they are run in the check phase instead
1133 "--with-openjdk-src-dir=./openjdk.src"
1134 ,(string-append "--with-jdk-home="
1135 (assoc-ref %build-inputs "jdk")))
1138 (modify-phases %standard-phases
1140 (lambda* (#:key source inputs #:allow-other-keys)
1141 (let ((target (string-append "icedtea-" ,version))
1142 (unpack (lambda* (name #:optional dir)
1144 (string-drop-right name 5))))
1146 (zero? (system* "tar" "xvf"
1147 (assoc-ref inputs name)
1149 "--strip-components=1"))))))
1152 (zero? (system* "tar" "xvf" source
1153 "-C" target "--strip-components=1"))
1155 (unpack "openjdk-src" "openjdk.src")
1156 (with-directory-excursion "openjdk.src"
1158 (filter (cut string-suffix? "-drop" <>)
1163 (add-after 'unpack 'fix-x11-extension-include-path
1164 (lambda* (#:key inputs #:allow-other-keys)
1165 (substitute* "openjdk.src/jdk/make/sun/awt/mawt.gmk"
1166 (((string-append "\\$\\(firstword \\$\\(wildcard "
1167 "\\$\\(OPENWIN_HOME\\)"
1168 "/include/X11/extensions\\).*$"))
1169 (string-append (assoc-ref inputs "libxrender")
1170 "/include/X11/extensions"
1171 " -I" (assoc-ref inputs "libxtst")
1172 "/include/X11/extensions"
1173 " -I" (assoc-ref inputs "libxinerama")
1174 "/include/X11/extensions"))
1175 (("\\$\\(wildcard /usr/include/X11/extensions\\)\\)") ""))
1177 (add-after 'unpack 'patch-paths
1179 ;; buildtree.make generates shell scripts, so we need to replace
1180 ;; the generated shebang
1181 (substitute* '("openjdk.src/hotspot/make/linux/makefiles/buildtree.make")
1182 (("/bin/sh") (which "bash")))
1184 (let ((corebin (string-append
1185 (assoc-ref %build-inputs "coreutils") "/bin/"))
1186 (binbin (string-append
1187 (assoc-ref %build-inputs "binutils") "/bin/"))
1188 (grepbin (string-append
1189 (assoc-ref %build-inputs "grep") "/bin/")))
1190 (substitute* '("openjdk.src/jdk/make/common/shared/Defs-linux.gmk"
1191 "openjdk.src/corba/make/common/shared/Defs-linux.gmk")
1192 (("UNIXCOMMAND_PATH = /bin/")
1193 (string-append "UNIXCOMMAND_PATH = " corebin))
1194 (("USRBIN_PATH = /usr/bin/")
1195 (string-append "USRBIN_PATH = " corebin))
1196 (("DEVTOOLS_PATH *= */usr/bin/")
1197 (string-append "DEVTOOLS_PATH = " corebin))
1198 (("COMPILER_PATH *= */usr/bin/")
1199 (string-append "COMPILER_PATH = "
1200 (assoc-ref %build-inputs "gcc") "/bin/"))
1201 (("DEF_OBJCOPY *=.*objcopy")
1202 (string-append "DEF_OBJCOPY = " (which "objcopy"))))
1204 ;; fix path to alsa header
1205 (substitute* "openjdk.src/jdk/make/common/shared/Sanity.gmk"
1206 (("ALSA_INCLUDE=/usr/include/alsa/version.h")
1207 (string-append "ALSA_INCLUDE="
1208 (assoc-ref %build-inputs "alsa-lib")
1209 "/include/alsa/version.h")))
1211 ;; fix hard-coded utility paths
1212 (substitute* '("openjdk.src/jdk/make/common/shared/Defs-utils.gmk"
1213 "openjdk.src/corba/make/common/shared/Defs-utils.gmk")
1215 (string-append "ECHO = " (which "echo")))
1217 (string-append "GREP = " (which "grep")))
1218 (("EGREP *=.*egrep")
1219 (string-append "EGREP = " (which "egrep")))
1221 (string-append "CPIO = " (which "cpio")))
1222 (("READELF *=.*readelf")
1223 (string-append "READELF = " (which "readelf")))
1225 (string-append "AR = " (which "ar")))
1227 (string-append "TAR = " (which "tar")))
1229 (string-append "AS = " (which "as")))
1231 (string-append "LD = " (which "ld")))
1232 (("STRIP *=.*strip")
1233 (string-append "STRIP = " (which "strip")))
1235 (string-append "NM = " (which "nm")))
1237 (string-append "SH = " (which "bash")))
1239 (string-append "FIND = " (which "find")))
1241 (string-append "LDD = " (which "ldd")))
1242 (("NAWK *=.*(n|g)awk")
1243 (string-append "NAWK = " (which "gawk")))
1244 (("XARGS *=.*xargs")
1245 (string-append "XARGS = " (which "xargs")))
1246 (("UNZIP *=.*unzip")
1247 (string-append "UNZIP = " (which "unzip")))
1249 (string-append "ZIPEXE = " (which "zip")))
1251 (string-append "SED = " (which "sed"))))
1253 ;; Some of these timestamps cause problems as they are more than
1254 ;; 10 years ago, failing the build process.
1256 "openjdk.src/jdk/src/share/classes/java/util/CurrencyData.properties"
1257 (("AZ=AZM;2005-12-31-20-00-00;AZN") "AZ=AZN")
1258 (("MZ=MZM;2006-06-30-22-00-00;MZN") "MZ=MZN")
1259 (("RO=ROL;2005-06-30-21-00-00;RON") "RO=RON")
1260 (("TR=TRL;2004-12-31-22-00-00;TRY") "TR=TRY")))
1262 (add-before 'configure 'set-additional-paths
1263 (lambda* (#:key inputs #:allow-other-keys)
1264 (substitute* "openjdk.src/jdk/make/common/shared/Sanity.gmk"
1265 (("ALSA_INCLUDE=/usr/include/alsa/version.h")
1266 (string-append "ALSA_INCLUDE="
1267 (assoc-ref inputs "alsa-lib")
1268 "/include/alsa/version.h")))
1271 (string-append (assoc-ref inputs "libxcomposite")
1272 "/include/X11/extensions" ":"
1273 (assoc-ref inputs "libxrender")
1274 "/include/X11/extensions" ":"
1275 (assoc-ref inputs "libxtst")
1276 "/include/X11/extensions" ":"
1277 (assoc-ref inputs "libxinerama")
1278 "/include/X11/extensions" ":"
1279 (or (getenv "CPATH") "")))
1280 (setenv "ALT_OBJCOPY" (which "objcopy"))
1281 (setenv "ALT_CUPS_HEADERS_PATH"
1282 (string-append (assoc-ref inputs "cups")
1284 (setenv "ALT_FREETYPE_HEADERS_PATH"
1285 (string-append (assoc-ref inputs "freetype")
1287 (setenv "ALT_FREETYPE_LIB_PATH"
1288 (string-append (assoc-ref inputs "freetype")
1291 (add-before 'check 'fix-test-framework
1293 ;; Fix PATH in test environment
1294 (substitute* "test/jtreg/com/sun/javatest/regtest/Main.java"
1295 (("PATH=/bin:/usr/bin")
1296 (string-append "PATH=" (getenv "PATH"))))
1297 (substitute* "test/jtreg/com/sun/javatest/util/SysEnv.java"
1298 (("/usr/bin/env") (which "env")))
1299 (substitute* "openjdk.src/hotspot/test/test_env.sh"
1300 (("/bin/rm") (which "rm"))
1301 (("/bin/cp") (which "cp"))
1302 (("/bin/mv") (which "mv")))
1304 (add-before 'check 'fix-hotspot-tests
1306 (with-directory-excursion "openjdk.src/hotspot/test/"
1307 (substitute* "jprt.config"
1308 (("PATH=\"\\$\\{path4sdk\\}\"")
1309 (string-append "PATH=" (getenv "PATH")))
1310 (("make=/usr/bin/make")
1311 (string-append "make=" (which "make"))))
1312 (substitute* '("runtime/6626217/Test6626217.sh"
1313 "runtime/7110720/Test7110720.sh")
1314 (("/bin/rm") (which "rm"))
1315 (("/bin/cp") (which "cp"))
1316 (("/bin/mv") (which "mv"))))
1318 (add-before 'check 'fix-jdk-tests
1320 (with-directory-excursion "openjdk.src/jdk/test/"
1321 (substitute* "com/sun/jdi/JdbReadTwiceTest.sh"
1322 (("/bin/pwd") (which "pwd")))
1323 (substitute* "com/sun/jdi/ShellScaffold.sh"
1324 (("/bin/kill") (which "kill")))
1325 (substitute* "start-Xvfb.sh"
1326 ;;(("/usr/bin/X11/Xvfb") (which "Xvfb"))
1327 (("/usr/bin/nohup") (which "nohup")))
1328 (substitute* "javax/security/auth/Subject/doAs/Test.sh"
1329 (("/bin/rm") (which "rm")))
1330 (substitute* "tools/launcher/MultipleJRE.sh"
1331 (("echo \"#!/bin/sh\"")
1332 (string-append "echo \"#!" (which "rm") "\""))
1333 (("/usr/bin/zip") (which "zip")))
1334 (substitute* "com/sun/jdi/OnThrowTest.java"
1335 (("#!/bin/sh") (string-append "#!" (which "sh"))))
1336 (substitute* "java/lang/management/OperatingSystemMXBean/GetSystemLoadAverage.java"
1337 (("/usr/bin/uptime") (which "uptime")))
1338 (substitute* "java/lang/ProcessBuilder/Basic.java"
1339 (("/usr/bin/env") (which "env"))
1340 (("/bin/false") (which "false"))
1341 (("/bin/true") (which "true"))
1342 (("/bin/cp") (which "cp"))
1343 (("/bin/sh") (which "sh")))
1344 (substitute* "java/lang/ProcessBuilder/FeelingLucky.java"
1345 (("/bin/sh") (which "sh")))
1346 (substitute* "java/lang/ProcessBuilder/Zombies.java"
1347 (("/usr/bin/perl") (which "perl"))
1348 (("/bin/ps") (which "ps"))
1349 (("/bin/true") (which "true")))
1350 (substitute* "java/lang/Runtime/exec/ConcurrentRead.java"
1351 (("/usr/bin/tee") (which "tee")))
1352 (substitute* "java/lang/Runtime/exec/ExecWithDir.java"
1353 (("/bin/true") (which "true")))
1354 (substitute* "java/lang/Runtime/exec/ExecWithInput.java"
1355 (("/bin/cat") (which "cat")))
1356 (substitute* "java/lang/Runtime/exec/ExitValue.java"
1357 (("/bin/sh") (which "sh"))
1358 (("/bin/true") (which "true"))
1359 (("/bin/kill") (which "kill")))
1360 (substitute* "java/lang/Runtime/exec/LotsOfDestroys.java"
1361 (("/usr/bin/echo") (which "echo")))
1362 (substitute* "java/lang/Runtime/exec/LotsOfOutput.java"
1363 (("/usr/bin/cat") (which "cat")))
1364 (substitute* "java/lang/Runtime/exec/SleepyCat.java"
1365 (("/bin/cat") (which "cat"))
1366 (("/bin/sleep") (which "sleep"))
1367 (("/bin/sh") (which "sh")))
1368 (substitute* "java/lang/Runtime/exec/StreamsSurviveDestroy.java"
1369 (("/bin/cat") (which "cat")))
1370 (substitute* "java/rmi/activation/CommandEnvironment/SetChildEnv.java"
1371 (("/bin/chmod") (which "chmod")))
1372 (substitute* "java/util/zip/ZipFile/Assortment.java"
1373 (("/bin/sh") (which "sh"))))
1377 ;; The "make check-*" targets always return zero, so we need to
1378 ;; check for errors in the associated log files to determine
1379 ;; whether any tests have failed.
1380 (use-modules (ice-9 rdelim))
1381 (let* ((error-pattern (make-regexp "^(Error|FAILED):.*"))
1382 (checker (lambda (port)
1384 (let ((line (read-line port)))
1386 ((eof-object? line) #t)
1387 ((regexp-exec error-pattern line) #f)
1389 (run-test (lambda (test)
1390 (system* "make" test)
1391 (call-with-input-file
1392 (string-append "test/" test ".log")
1395 (and (run-test "check-hotspot")
1396 (run-test "check-langtools")
1397 (run-test "check-jdk"))))))
1399 (lambda* (#:key outputs #:allow-other-keys)
1400 (let ((doc (string-append (assoc-ref outputs "doc")
1401 "/share/doc/icedtea"))
1402 (jre (assoc-ref outputs "out"))
1403 (jdk (assoc-ref outputs "jdk")))
1404 (copy-recursively "openjdk.build/docs" doc)
1405 (copy-recursively "openjdk.build/j2re-image" jre)
1406 (copy-recursively "openjdk.build/j2sdk-image" jdk))
1408 ;; Some of the libraries in the lib/amd64 folder link to libjvm.so.
1409 ;; But that shared object is located in the server/ folder, so it
1410 ;; cannot be found. This phase creates a symbolic link in the
1411 ;; lib/amd64 folder so that the other libraries can find it.
1414 ;; https://lists.gnu.org/archive/html/guix-devel/2017-10/msg00169.html
1416 ;; FIXME: Find the bug in the build system, so that this symlink is
1418 (add-after 'install 'install-libjvm
1419 (lambda* (#:key inputs outputs #:allow-other-keys)
1420 (let* ((lib-path (string-append (assoc-ref outputs "out")
1422 (symlink (string-append lib-path "/server/libjvm.so")
1423 (string-append lib-path "/libjvm.so")))
1425 ;; By default IcedTea only generates an empty keystore. In order to
1426 ;; be able to use certificates in Java programs we need to generate a
1427 ;; keystore from a set of certificates. For convenience we use the
1428 ;; certificates from the nss-certs package.
1429 (add-after 'install 'install-keystore
1430 (lambda* (#:key inputs outputs #:allow-other-keys)
1431 (let* ((keystore "cacerts")
1432 (certs-dir (string-append (assoc-ref inputs "nss-certs")
1434 (keytool (string-append (assoc-ref outputs "jdk")
1436 (define (extract-cert file target)
1437 (call-with-input-file file
1439 (call-with-output-file target
1441 (let loop ((line (read-line in 'concat))
1444 ((eof-object? line) #t)
1445 ((string-prefix? "-----BEGIN" line)
1447 (loop (read-line in 'concat) #t))
1448 ((string-prefix? "-----END" line)
1452 (when copying? (display line out))
1453 (loop (read-line in 'concat) copying?)))))))))
1454 (define (import-cert cert)
1455 (format #t "Importing certificate ~a\n" (basename cert))
1456 (let ((temp "tmpcert"))
1457 (extract-cert cert temp)
1458 (let ((port (open-pipe* OPEN_WRITE keytool
1460 "-alias" (basename cert)
1461 "-keystore" keystore
1462 "-storepass" "changeit"
1464 (display "yes\n" port)
1465 (when (not (zero? (status:exit-val (close-pipe port))))
1466 (format #t "failed to import ~a\n" cert)))
1467 (delete-file temp)))
1469 ;; This is necessary because the certificate directory contains
1470 ;; files with non-ASCII characters in their names.
1471 (setlocale LC_ALL "en_US.utf8")
1472 (setenv "LC_ALL" "en_US.utf8")
1474 (for-each import-cert (find-files certs-dir "\\.pem$"))
1475 (mkdir-p (string-append (assoc-ref outputs "out")
1477 (mkdir-p (string-append (assoc-ref outputs "jdk")
1478 "/jre/lib/security"))
1480 ;; The cacerts files we are going to overwrite are chmod'ed as
1481 ;; read-only (444) in icedtea-8 (which derives from this
1482 ;; package). We have to change this so we can overwrite them.
1483 (chmod (string-append (assoc-ref outputs "out")
1484 "/lib/security/" keystore) #o644)
1485 (chmod (string-append (assoc-ref outputs "jdk")
1486 "/jre/lib/security/" keystore) #o644)
1488 (install-file keystore
1489 (string-append (assoc-ref outputs "out")
1491 (install-file keystore
1492 (string-append (assoc-ref outputs "jdk")
1493 "/jre/lib/security"))
1498 "1zhr4l9kxnbzghcsgjk3vmih9qpg1wrr9qry7fx04l97svp1ylhd"))
1501 "108v15ncb2rnsyzgzncjlm1f57d1sv60zd9qbpas8kqmvpp8r0gz"))
1504 "0zcpcmm3g1s7m31glrbw3ys7azi97ixcvbyxd40y9xzdja3jyr52"))
1507 "1gkqm0p3sr8d0xpki3fhf7cvmgqxx8ambgl5f3jx2plfnhsg96d2"))
1510 "1d9fjnzdx4m6gwkvmj2n097ag0mvkhm3lldaxjki8x8c6a5clknf"))
1513 "0zscdp9arcq7gr8j7jq4m75gq0w1i3ryxpdnrc8fl0msh4w2s2k5"))
1516 "1y6vnssn5y50x27g4ypdb5wwpmi7zf7jdi8gqbymkwf6n8p5y1d6"))
1517 ("ant" ,ant-bootstrap)
1519 ("coreutils" ,coreutils)
1520 ("diffutils" ,diffutils) ;for tests
1523 ("libtool" ,libtool)
1524 ("pkg-config" ,pkg-config)
1530 ("fastjar" ,fastjar)
1531 ("libxslt" ,libxslt) ;for xsltproc
1532 ("nss-certs" ,nss-certs)
1534 ("procps" ,procps) ;for "free", even though I'm not sure we should use it
1535 ("jdk" ,icedtea-6 "jdk")))
1537 `(("alsa-lib" ,alsa-lib)
1540 ("libxcomposite" ,libxcomposite)
1542 ("libxtst" ,libxtst)
1544 ("libxinerama" ,libxinerama)
1545 ("libxrender" ,libxrender)
1546 ("libjpeg" ,libjpeg)
1548 ("mit-krb5" ,mit-krb5)
1551 ("fontconfig" ,fontconfig)
1552 ("freetype" ,freetype)
1556 (home-page "http://icedtea.classpath.org")
1557 (synopsis "Java development kit")
1559 "This package provides the Java development kit OpenJDK built with the
1560 IcedTea build harness.")
1561 ;; IcedTea is released under the GPL2 + Classpath exception, which is the
1562 ;; same license as both GNU Classpath and OpenJDK.
1563 (license license:gpl2+))))
1565 (define-public icedtea-8
1566 (let* ((version "3.5.1")
1567 (drop (lambda (name hash)
1571 "http://icedtea.classpath.org/download/drops"
1572 "/icedtea8/" version "/" name ".tar.xz"))
1573 (sha256 (base32 hash))))))
1574 (package (inherit icedtea-7)
1579 "http://icedtea.wildebeest.org/download/source/icedtea-"
1583 "1j8iv0cdk9fkh3yb5is7z29m9k3s89w6y9090538j6aa7p4nmalf"))
1584 (modules '((guix build utils)))
1587 (substitute* "acinclude.m4"
1588 ;; Do not embed build time
1589 (("(DIST_ID=\"Custom build).*$" _ prefix)
1590 (string-append prefix "\"\n"))
1591 ;; Do not leak information about the build host
1592 (("DIST_NAME=\"\\$build_os\"")
1593 "DIST_NAME=\"guix\""))
1596 (substitute-keyword-arguments (package-arguments icedtea-7)
1597 ((#:configure-flags flags)
1598 `(let ((jdk (assoc-ref %build-inputs "jdk")))
1599 `(;;"--disable-bootstrap"
1600 "--enable-bootstrap"
1602 "--disable-downloading"
1603 "--disable-system-pcsc"
1604 "--disable-system-sctp"
1605 "--disable-tests" ;they are run in the check phase instead
1606 "--with-openjdk-src-dir=./openjdk.src"
1607 ,(string-append "--with-jdk-home=" jdk))))
1609 `(modify-phases ,phases
1610 (delete 'fix-x11-extension-include-path)
1611 (delete 'patch-paths)
1612 (delete 'set-additional-paths)
1613 (delete 'patch-patches)
1614 (add-after 'unpack 'patch-jni-libs
1615 ;; Hardcode dynamically loaded libraries.
1617 (let* ((library-path (search-path-as-string->list
1618 (getenv "LIBRARY_PATH")))
1619 (find-library (lambda (name)
1622 (string-append "lib" name ".so")))))
1625 (catch 'decoding-error
1628 (("VERSIONED_JNI_LIB_NAME\\(\"(.*)\", \"(.*)\"\\)"
1630 (format #f "\"~a\"" (find-library name)))
1631 (("JNI_LIB_NAME\\(\"(.*)\"\\)" _ name)
1632 (format #f "\"~a\"" (find-library name)))))
1634 ;; Those are safe to skip.
1635 (format (current-error-port)
1636 "warning: failed to substitute: ~a~%"
1638 (find-files "openjdk.src/jdk/src/solaris/native"
1642 (lambda* (#:key outputs #:allow-other-keys)
1643 (let ((doc (string-append (assoc-ref outputs "doc")
1644 "/share/doc/icedtea"))
1645 (jre (assoc-ref outputs "out"))
1646 (jdk (assoc-ref outputs "jdk")))
1647 (copy-recursively "openjdk.build/docs" doc)
1648 (copy-recursively "openjdk.build/images/j2re-image" jre)
1649 (copy-recursively "openjdk.build/images/j2sdk-image" jdk)
1650 ;; Install the nss.cfg file to JRE to enable SSL/TLS
1652 (copy-file (string-append jdk "/jre/lib/security/nss.cfg")
1653 (string-append jre "/lib/security/nss.cfg"))
1656 `(("jdk" ,icedtea-7 "jdk")
1659 "0a6yrq8y1zkzc7hm2l28rm3vzy5izfxhmmhhhvc91lhfclnqcd2q"))
1662 "0cway5a5hcfyh4pzl9zz5xr7lil4gsliy6r5iqbaasd2d9alvqiq"))
1665 "031sc6byd8lqvz3cd07phm13pqrxalxk9f3a2q8pim5n4sbsy0qb"))
1668 "1815jaj0k0w1s0g0jr1ahkajp1jx2qlb08i6l9ha4wyqqyp49a4n"))
1671 "0vh4f85cxhqvabzg86ycpz02519cdzgsn5dr75k22rkmbbxnbbl6"))
1674 "196ycqz4d9kknc6b219q4ib83l1kkl6w6l1cznw9bzaafyynqa35"))
1677 "0ssnadlr5cxhmj06nmni34kdynix1sjhcvjzahm5yzfd7dfllmgy"))
1680 "0f7fxf0s9kadvs80hm5ga72pyp9r0fvl8zm1wmd1wrks8kl79sd6"))
1683 "0m95qgnd4z6p0xp9m06ihss7skx2yrm7xw69jsjsrxpriy1shiwy"))
1686 "0yjlcgp6mldp30hmkfl68mdwlbg3gb0m6xd5y7srczni7cln5f3i"))
1687 ,@(fold alist-delete (package-native-inputs icedtea-7)
1688 '("jdk" "openjdk-src" "corba-drop" "jaxp-drop" "jaxws-drop"
1689 "jdk-drop" "langtools-drop" "hotspot-drop")))))))
1691 (define-public icedtea icedtea-7)
1694 (define-public ant/java8
1695 (package (inherit ant-bootstrap)
1700 (uri (string-append "mirror://apache/ant/source/apache-ant-"
1701 version "-src.tar.gz"))
1704 "10p3dh77lkzzzcy32dk9azljixzadp46fggjfbvgkl8mmb8cxxv8"))
1705 (modules '((guix build utils)))
1708 (for-each delete-file
1709 (find-files "lib/optional" "\\.jar$"))
1712 (substitute-keyword-arguments (package-arguments ant-bootstrap)
1714 `(modify-phases ,phases
1715 (add-after 'unpack 'remove-scripts
1716 ;; Remove bat / cmd scripts for DOS as well as the antRun and runant
1719 (for-each delete-file
1720 (find-files "src/script"
1721 "(.*\\.(bat|cmd)|runant.*|antRun.*)"))
1724 (lambda* (#:key inputs outputs #:allow-other-keys)
1725 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
1727 ;; Disable tests to avoid dependency on hamcrest-core, which needs
1728 ;; Ant to build. This is necessary in addition to disabling the
1729 ;; "check" phase, because the dependency on "test-jar" would always
1730 ;; result in the tests to be run.
1731 (substitute* "build.xml"
1732 (("depends=\"jars,test-jar\"") "depends=\"jars\""))
1733 (zero? (system* "bash" "bootstrap.sh"
1734 (string-append "-Ddist.dir="
1735 (assoc-ref outputs "out"))))))))))
1737 `(("jdk" ,icedtea-8 "jdk")))))
1739 ;; The 1.9.x series is the last that can be built with GCJ. The 1.10.x series
1742 (package (inherit ant/java8)
1746 (uri (string-append "mirror://apache/ant/source/apache-ant-"
1747 version "-src.tar.gz"))
1750 "1k28mka0m3isy9yr8gz84kz1f3f879rwaxrd44vdn9xbfwvwk86n"))))
1752 `(("jdk" ,icedtea-7 "jdk")))))
1754 (define-public clojure
1755 (let* ((remove-archives '(begin
1756 (for-each delete-file
1757 (find-files "." ".*\\.(jar|zip)"))
1759 (submodule (lambda (prefix version hash)
1762 (uri (string-append "https://github.com/clojure/"
1763 prefix version ".tar.gz"))
1764 (sha256 (base32 hash))
1765 (modules '((guix build utils)))
1766 (snippet remove-archives)))))
1774 (string-append "http://repo1.maven.org/maven2/org/clojure/clojure/"
1775 version "/clojure-" version ".zip"))
1777 (base32 "1nip095fz5c492sw15skril60i1vd21ibg6szin4jcvyy3xr6cym"))
1778 (modules '((guix build utils)))
1779 (snippet remove-archives)))
1780 (build-system ant-build-system)
1782 `(#:modules ((guix build ant-build-system)
1788 #:test-target "test"
1790 (modify-phases %standard-phases
1791 (add-after 'unpack 'unpack-submodule-sources
1792 (lambda* (#:key inputs #:allow-other-keys)
1796 (with-directory-excursion name
1797 (or (zero? (system* "tar"
1798 ;; Use xz for repacked tarball.
1802 "--file" (assoc-ref inputs name)
1803 "--strip-components=1"))
1804 (error "failed to unpack tarball" name)))
1805 (copy-recursively (string-append name "/src/main/clojure/")
1807 '("data-generators-src"
1808 "java-classpath-src"
1810 "test-generative-src"
1811 "tools-namespace-src"
1812 "tools-reader-src"))
1814 ;; The javadoc target is not built by default.
1815 (add-after 'build 'build-doc
1817 (zero? (system* "ant" "javadoc"))))
1818 ;; Needed since no install target is provided.
1820 (lambda* (#:key outputs #:allow-other-keys)
1821 (let ((java-dir (string-append (assoc-ref outputs "out")
1823 ;; Install versioned to avoid collisions.
1824 (install-file (string-append "clojure-" ,version ".jar")
1827 ;; Needed since no install-doc target is provided.
1828 (add-after 'install 'install-doc
1829 (lambda* (#:key outputs #:allow-other-keys)
1830 (let ((doc-dir (string-append (assoc-ref outputs "out")
1831 "/share/doc/clojure-"
1833 (copy-recursively "doc/clojure" doc-dir)
1834 (copy-recursively "target/javadoc/"
1835 (string-append doc-dir "javadoc/"))
1836 (for-each (cut install-file <> doc-dir)
1837 (filter (cut string-match
1838 ".*\\.(html|markdown|md|txt)"
1842 ;; The native-inputs below are needed to run the tests.
1844 `(("data-generators-src"
1845 ,(submodule "data.generators/archive/data.generators-"
1847 "0kki093jp4ckwxzfnw8ylflrfqs8b1i1wi9iapmwcsy328dmgzp1"))
1848 ("java-classpath-src"
1849 ,(submodule "java.classpath/archive/java.classpath-"
1851 "0sjymly9xh1lkvwn5ygygpsfwz4dabblnlq0c9bx76rkvq62fyng"))
1853 ,(submodule "test.check/archive/test.check-"
1855 "0p0mnyhr442bzkz0s4k5ra3i6l5lc7kp6ajaqkkyh4c2k5yck1md"))
1856 ("test-generative-src"
1857 ,(submodule "test.generative/archive/test.generative-"
1859 "1pjafy1i7yblc7ixmcpfq1lfbyf3jaljvkgrajn70sws9xs7a9f8"))
1860 ("tools-namespace-src"
1861 ,(submodule "tools.namespace/archive/tools.namespace-"
1863 "10baak8v0hnwz2hr33bavshm7y49mmn9zsyyms1dwjz45p5ymhy0"))
1865 ,(submodule "tools.reader/archive/tools.reader-"
1867 "1lafblmmj4hkg0aqrf19qkdw9wdcsh3qxmn6cbkmnzbhffpyv2lv"))))
1868 (home-page "https://clojure.org/")
1869 (synopsis "Lisp dialect running on the JVM")
1870 (description "Clojure is a dynamic, general-purpose programming language,
1871 combining the approachability and interactive development of a scripting
1872 language with an efficient and robust infrastructure for multithreaded
1873 programming. Clojure is a compiled language, yet remains completely dynamic
1874 – every feature supported by Clojure is supported at runtime. Clojure
1875 provides easy access to the Java frameworks, with optional type hints and type
1876 inference, to ensure that calls to Java can avoid reflection.
1878 Clojure is a dialect of Lisp, and shares with Lisp the code-as-data philosophy
1879 and a powerful macro system. Clojure is predominantly a functional programming
1880 language, and features a rich set of immutable, persistent data structures.
1881 When mutable state is needed, Clojure offers a software transactional memory
1882 system and reactive Agent system that ensure clean, correct, multithreaded
1884 ;; Clojure is licensed under EPL1.0
1885 ;; ASM bytecode manipulation library is licensed under BSD-3
1886 ;; Guava Murmur3 hash implementation is licensed under APL2.0
1887 ;; src/clj/repl.clj is licensed under CPL1.0
1889 ;; See readme.html or readme.txt for details.
1890 (license (list license:epl1.0
1895 (define-public java-classpathx-servletapi
1897 (name "java-classpathx-servletapi")
1901 (uri (string-append "mirror://gnu/classpathx/servletapi/"
1902 "servletapi-" version ".tar.gz"))
1905 "0y9489pk4as9q6x300sk3ycc0psqfxcd4b0xvbmf3rhgli8q1kx3"))))
1906 (build-system ant-build-system)
1908 `(#:tests? #f ; there is no test target
1909 #:build-target "compile"
1910 ;; NOTE: This package does not build with Java 8 because of a type
1912 ;; "source/javax/servlet/jsp/el/ImplicitObjectELResolver.java". It
1913 ;; defines the return value of ScopeMap's "remove" method to be of type
1914 ;; "Object", whereas Map's "remove" method returns boolean.
1916 (list "-Dbuild.compiler=javac1.7"
1917 (string-append "-Ddist=" (assoc-ref %outputs "out")))
1919 (modify-phases %standard-phases
1921 (lambda* (#:key make-flags #:allow-other-keys)
1922 (zero? (apply system* `("ant" "dist" ,@make-flags))))))))
1923 (home-page "https://www.gnu.org/software/classpathx/")
1924 (synopsis "Java servlet API implementation")
1925 (description "This is the GNU servlet API distribution, part of the
1926 ClasspathX project. It provides implementations of version 3.0 of the servlet
1927 API and version 2.1 of the Java ServerPages API.")
1928 (license license:gpl3+)))
1930 (define-public java-swt
1935 ;; The types of many variables and procedures differ in the sources
1936 ;; dependent on whether the target architecture is a 32-bit system or a
1937 ;; 64-bit system. Instead of patching the sources on demand in a build
1938 ;; phase we download either the 32-bit archive (which mostly uses "int"
1939 ;; types) or the 64-bit archive (which mostly uses "long" types).
1940 (let ((hash32 "0jmx1h65wqxsyjzs64i2z6ryiynllxzm13cq90fky2qrzagcw1ir")
1941 (hash64 "0wnd01xssdq9pgx5xqh5lfiy3dmk60dzzqdxzdzf883h13692lgy")
1944 (let-values (((hash file)
1945 (match (or (%current-target-system) (%current-system))
1946 ("x86_64-linux" (values hash64 file64))
1947 (_ (values hash32 file32)))))
1951 "http://ftp-stud.fht-esslingen.de/pub/Mirrors/"
1952 "eclipse/eclipse/downloads/drops4/R-" version
1953 "-201606061100/swt-" version "-gtk-linux-" file ".zip"))
1954 (sha256 (base32 hash))))))
1955 (build-system ant-build-system)
1957 `(#:jar-name "swt.jar"
1958 #:tests? #f ; no "check" target
1960 (modify-phases %standard-phases
1962 (lambda* (#:key source #:allow-other-keys)
1964 (zero? (system* "unzip" source "-d" "swt"))
1967 (zero? (system* "unzip" "src.zip" "-d" "src")))))
1968 ;; The classpath contains invalid icecat jars. Since we don't need
1969 ;; anything other than the JDK on the classpath, we can simply unset
1971 (add-after 'configure 'unset-classpath
1972 (lambda _ (unsetenv "CLASSPATH") #t))
1973 (add-before 'build 'build-native
1974 (lambda* (#:key inputs outputs #:allow-other-keys)
1975 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
1976 ;; Build shared libraries. Users of SWT have to set the system
1977 ;; property swt.library.path to the "lib" directory of this
1980 (setenv "OUTPUT_DIR" lib)
1981 (with-directory-excursion "src"
1982 (zero? (system* "bash" "build.sh"))))))
1983 (add-after 'install 'install-native
1984 (lambda* (#:key outputs #:allow-other-keys)
1985 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
1986 (for-each (lambda (file)
1987 (install-file file lib))
1988 (find-files "." "\\.so$"))
1991 `(("xulrunner" ,icecat)
1993 ("libxtst" ,libxtst)
1998 `(("pkg-config" ,pkg-config)
2000 (home-page "https://www.eclipse.org/swt/")
2001 (synopsis "Widget toolkit for Java")
2003 "SWT is a widget toolkit for Java designed to provide efficient, portable
2004 access to the user-interface facilities of the operating systems on which it
2006 ;; SWT code is licensed under EPL1.0
2007 ;; Gnome and Gtk+ bindings contain code licensed under LGPLv2.1
2008 ;; Cairo bindings contain code under MPL1.1
2009 ;; XULRunner 1.9 bindings contain code under MPL2.0
2014 license:lgpl2.1+))))
2016 (define-public java-xz
2022 (uri (string-append "http://tukaani.org/xz/xz-java-" version ".zip"))
2025 "1z3p1ri1gvl07inxn0agx44ck8n7wrzfmvkz8nbq3njn8r9wba8x"))))
2026 (build-system ant-build-system)
2028 `(#:tests? #f ; There are no tests to run.
2029 #:jar-name ,(string-append "xz-" version ".jar")
2031 (modify-phases %standard-phases
2032 ;; The unpack phase enters the "maven" directory by accident.
2033 (add-after 'unpack 'chdir
2034 (lambda _ (chdir "..") #t)))))
2036 `(("unzip" ,unzip)))
2037 (home-page "http://tukaani.org/xz/java.html")
2038 (synopsis "Implementation of XZ data compression in pure Java")
2039 (description "This library aims to be a complete implementation of XZ data
2040 compression in pure Java. Single-threaded streamed compression and
2041 decompression and random access decompression have been fully implemented.")
2042 (license license:public-domain)))
2044 ;; java-hamcrest-core uses qdox version 1.12. We package this version instead
2045 ;; of the latest release.
2046 (define-public java-qdox-1.12
2052 (uri (string-append "http://central.maven.org/maven2/"
2053 "com/thoughtworks/qdox/qdox/" version
2054 "/qdox-" version "-sources.jar"))
2057 "0hlfbqq2avf5s26wxkksqmkdyk6zp9ggqn37c468m96mjv0n9xfl"))))
2058 (build-system ant-build-system)
2060 `(;; Tests require junit
2062 #:jar-name "qdox.jar"
2064 (modify-phases %standard-phases
2066 (lambda* (#:key source #:allow-other-keys)
2068 (with-directory-excursion "src"
2069 (zero? (system* "jar" "-xf" source)))))
2070 ;; At this point we don't have junit, so we must remove the API
2072 (add-after 'unpack 'delete-tests
2074 (delete-file-recursively "src/com/thoughtworks/qdox/junit")
2076 (home-page "http://qdox.codehaus.org/")
2077 (synopsis "Parse definitions from Java source files")
2079 "QDox is a high speed, small footprint parser for extracting
2080 class/interface/method definitions from source files complete with JavaDoc
2081 @code{@@tags}. It is designed to be used by active code generators or
2082 documentation tools.")
2083 (license license:asl2.0)))
2085 (define-public java-jarjar
2087 (name "java-jarjar")
2092 "https://storage.googleapis.com/google-code-archive-downloads/v2/"
2093 "code.google.com/jarjar/jarjar-src-" version ".zip"))
2096 "1v8irhni9cndcw1l1wxqgry013s2kpj0qqn57lj2ji28xjq8ndjl"))))
2097 (build-system ant-build-system)
2099 `(;; Tests require junit, which ultimately depends on this package.
2101 #:build-target "jar"
2103 (modify-phases %standard-phases
2105 (lambda* (#:key outputs #:allow-other-keys)
2106 (let ((target (string-append (assoc-ref outputs "out")
2108 (install-file (string-append "dist/jarjar-" ,version ".jar")
2112 `(("unzip" ,unzip)))
2113 (home-page "https://code.google.com/archive/p/jarjar/")
2114 (synopsis "Repackage Java libraries")
2116 "Jar Jar Links is a utility that makes it easy to repackage Java
2117 libraries and embed them into your own distribution. Jar Jar Links includes
2118 an Ant task that extends the built-in @code{jar} task.")
2119 (license license:asl2.0)))
2121 (define-public java-hamcrest-core
2123 (name "java-hamcrest-core")
2127 (uri (string-append "https://github.com/hamcrest/JavaHamcrest/"
2128 "archive/hamcrest-java-" version ".tar.gz"))
2131 "11g0s105fmwzijbv08lx8jlb521yravjmxnpgdx08fvg1kjivhva"))
2132 (modules '((guix build utils)))
2135 ;; Delete bundled thirds-party jar archives.
2136 (delete-file-recursively "lib")
2138 (build-system ant-build-system)
2140 `(#:tests? #f ; Tests require junit
2141 #:modules ((guix build ant-build-system)
2144 #:make-flags (list (string-append "-Dversion=" ,version))
2145 #:test-target "unit-test"
2146 #:build-target "core"
2148 (modify-phases %standard-phases
2149 ;; Disable unit tests, because they require junit, which requires
2150 ;; hamcrest-core. We also give a fixed value to the "Built-Date"
2151 ;; attribute from the manifest for reproducibility.
2152 (add-before 'configure 'patch-build.xml
2154 (substitute* "build.xml"
2155 (("unit-test, ") "")
2156 (("\\$\\{build.timestamp\\}") "guix"))
2158 ;; Java's "getMethods()" returns methods in an unpredictable order.
2159 ;; To make the output of the generated code deterministic we must
2160 ;; sort the array of methods.
2161 (add-after 'unpack 'make-method-order-deterministic
2163 (substitute* "hamcrest-generator/src/main/java/org/hamcrest/generator/ReflectiveFactoryReader.java"
2164 (("import java\\.util\\.Iterator;" line)
2165 (string-append line "\n"
2166 "import java.util.Arrays; import java.util.Comparator;"))
2167 (("allMethods = cls\\.getMethods\\(\\);" line)
2168 (string-append "_" line
2170 private Method[] getSortedMethods() {
2171 Arrays.sort(_allMethods, new Comparator<Method>() {
2173 public int compare(Method a, Method b) {
2174 return a.toString().compareTo(b.toString());
2180 private Method[] allMethods = getSortedMethods();")))))
2181 (add-before 'build 'do-not-use-bundled-qdox
2182 (lambda* (#:key inputs #:allow-other-keys)
2183 (substitute* "build.xml"
2184 (("lib/generator/qdox-1.12.jar")
2185 (string-append (assoc-ref inputs "java-qdox-1.12")
2186 "/share/java/qdox.jar")))
2188 ;; build.xml searches for .jar files in this directoy, which
2189 ;; we remove from the source archive.
2190 (add-before 'build 'create-dummy-directories
2192 (mkdir-p "lib/integration")
2195 (lambda* (#:key outputs #:allow-other-keys)
2196 (let* ((target (string-append (assoc-ref outputs "out")
2198 (version-suffix ,(string-append "-" version ".jar"))
2199 (install-without-version-suffix
2202 (string-append target
2203 (basename jar version-suffix)
2207 install-without-version-suffix
2210 (and (string-suffix? ".jar" name)
2211 (not (string-suffix? "-sources.jar" name)))))))
2214 `(("java-qdox-1.12" ,java-qdox-1.12)
2215 ("java-jarjar" ,java-jarjar)))
2216 (home-page "http://hamcrest.org/")
2217 (synopsis "Library of matchers for building test expressions")
2219 "This package provides a library of matcher objects (also known as
2220 constraints or predicates) allowing @code{match} rules to be defined
2221 declaratively, to be used in other frameworks. Typical scenarios include
2222 testing frameworks, mocking libraries and UI validation rules.")
2223 (license license:bsd-2)))
2225 (define-public java-junit
2231 (uri (string-append "https://github.com/junit-team/junit/"
2232 "archive/r" version ".tar.gz"))
2233 (file-name (string-append name "-" version ".tar.gz"))
2236 "090dn5v1vs0b3acyaqc0gjf6p8lmd2h24wfzsbq7sly6b214anws"))
2237 (modules '((guix build utils)))
2240 ;; Delete bundled jar archives.
2241 (delete-file-recursively "lib")
2243 (build-system ant-build-system)
2245 `(#:tests? #f ; no tests
2246 #:jar-name "junit.jar"))
2248 `(("java-hamcrest-core" ,java-hamcrest-core)))
2249 (home-page "http://junit.org/")
2250 (synopsis "Test framework for Java")
2252 "JUnit is a simple framework to write repeatable tests for Java projects.
2253 JUnit provides assertions for testing expected results, test fixtures for
2254 sharing common test data, and test runners for running tests.")
2255 (license license:epl1.0)))
2257 (define-public java-plexus-utils
2259 (name "java-plexus-utils")
2263 (uri (string-append "https://github.com/codehaus-plexus/"
2264 "plexus-utils/archive/plexus-utils-"
2268 "1mlwpc6fms24slygv5yvi6fi9hcha2fh0v73p5znpi78bg36i2js"))))
2269 (build-system ant-build-system)
2270 ;; FIXME: The default build.xml does not include a target to install
2273 `(#:jar-name "plexus-utils.jar"
2274 #:source-dir "src/main"
2276 (modify-phases %standard-phases
2277 (add-after 'unpack 'fix-reference-to-/bin-and-/usr
2279 (substitute* "src/main/java/org/codehaus/plexus/util/\
2280 cli/shell/BourneShell.java"
2281 (("/bin/sh") (which "sh"))
2282 (("/usr/") (getcwd)))
2284 (add-after 'unpack 'fix-or-disable-broken-tests
2286 (with-directory-excursion "src/test/java/org/codehaus/plexus/util"
2287 (substitute* '("cli/CommandlineTest.java"
2288 "cli/shell/BourneShellTest.java")
2289 (("/bin/sh") (which "sh"))
2290 (("/bin/echo") (which "echo")))
2292 ;; This test depends on MavenProjectStub, but we don't have
2293 ;; a package for Maven.
2294 (delete-file "introspection/ReflectionValueExtractorTest.java")
2296 ;; FIXME: The command line tests fail, maybe because they use
2298 (delete-file "cli/CommandlineTest.java"))
2301 `(("java-junit" ,java-junit)))
2302 (home-page "http://codehaus-plexus.github.io/plexus-utils/")
2303 (synopsis "Common utilities for the Plexus framework")
2304 (description "This package provides various Java utility classes for the
2305 Plexus framework to ease working with strings, files, command lines, XML and
2307 (license license:asl2.0)))
2309 (define-public java-plexus-interpolation
2311 (name "java-plexus-interpolation")
2315 (uri (string-append "https://github.com/codehaus-plexus/"
2316 "plexus-interpolation/archive/"
2317 "plexus-interpolation-" version ".tar.gz"))
2320 "03377yzlx5q440m6sxxgv6a5qb8fl30zzcgxgc0hxk5qgl2z1jjn"))))
2321 (build-system ant-build-system)
2323 `(#:jar-name "plexus-interpolation.jar"
2324 #:source-dir "src/main"))
2326 `(("java-junit" ,java-junit)
2327 ("java-hamcrest-core" ,java-hamcrest-core)))
2328 (home-page "http://codehaus-plexus.github.io/plexus-interpolation/")
2329 (synopsis "Java components for interpolating ${} strings and the like")
2330 (description "Plexus interpolator is a modular, flexible interpolation
2331 framework for the expression language style commonly seen in Maven, Plexus,
2332 and other related projects.
2334 It has its foundation in the @code{org.codehaus.plexus.utils.interpolation}
2335 package within @code{plexus-utils}, but has been separated in order to allow
2336 these two libraries to vary independently of one another.")
2337 (license license:asl2.0)))
2339 (define-public java-asm
2345 (uri (string-append "http://download.forge.ow2.org/asm/"
2346 "asm-" version ".tar.gz"))
2349 "0kxvmv5275rnjl7jv0442k3wjnq03ngkb7sghs78avf45pzm4qgr"))))
2350 (build-system ant-build-system)
2352 `(#:build-target "compile"
2353 ;; The tests require an old version of Janino, which no longer compiles
2356 ;; We don't need these extra ant tasks, but the build system asks us to
2357 ;; provide a path anyway.
2358 #:make-flags (list (string-append "-Dobjectweb.ant.tasks.path=foo"))
2360 (modify-phases %standard-phases
2361 (add-before 'install 'build-jars
2362 (lambda* (#:key make-flags #:allow-other-keys)
2363 ;; We cannot use the "jar" target because it depends on a couple
2364 ;; of unpackaged, complicated tools.
2366 (zero? (system* "jar"
2367 "-cf" (string-append "dist/asm-" ,version ".jar")
2368 "-C" "output/build/tmp" "."))))
2370 (install-jars "dist")))))
2372 `(("java-junit" ,java-junit)))
2373 (home-page "http://asm.ow2.org/")
2374 (synopsis "Very small and fast Java bytecode manipulation framework")
2375 (description "ASM is an all purpose Java bytecode manipulation and
2376 analysis framework. It can be used to modify existing classes or dynamically
2377 generate classes, directly in binary form. The provided common
2378 transformations and analysis algorithms allow to easily assemble custom
2379 complex transformations and code analysis tools.")
2380 (license license:bsd-3)))
2382 (define-public java-cglib
2389 "https://github.com/cglib/cglib/archive/RELEASE_"
2390 (string-map (lambda (c) (if (char=? c #\.) #\_ c)) version)
2392 (file-name (string-append "cglib-" version ".tar.gz"))
2395 "162dvd4fln76ai8prfharf66pn6r56p3sxx683j5vdyccrd5hi1q"))))
2396 (build-system ant-build-system)
2398 `(;; FIXME: tests fail because junit runs
2399 ;; "net.sf.cglib.transform.AbstractTransformTest", which does not seem
2400 ;; to describe a test at all.
2402 #:jar-name "cglib.jar"
2404 (modify-phases %standard-phases
2405 (add-after 'unpack 'chdir
2406 (lambda _ (chdir "cglib") #t)))))
2408 `(("java-asm" ,java-asm)
2409 ("java-junit" ,java-junit)))
2410 (home-page "https://github.com/cglib/cglib/")
2411 (synopsis "Java byte code generation library")
2412 (description "The byte code generation library CGLIB is a high level API
2413 to generate and transform Java byte code.")
2414 (license license:asl2.0)))
2416 (define-public java-objenesis
2418 (name "java-objenesis")
2422 (uri (string-append "https://github.com/easymock/objenesis/"
2423 "archive/" version ".tar.gz"))
2424 (file-name (string-append "objenesis-" version ".tar.gz"))
2427 "1va5qz1i2wawwavhnxfzxnfgrcaflz9p1pg03irrjh4nd3rz8wh6"))))
2428 (build-system ant-build-system)
2430 `(#:jar-name "objenesis.jar"
2431 #:source-dir "main/src/"
2432 #:test-dir "main/src/test/"))
2434 `(("java-junit" ,java-junit)
2435 ("java-hamcrest-core" ,java-hamcrest-core)))
2436 (home-page "http://objenesis.org/")
2437 (synopsis "Bypass the constructor when creating an object")
2438 (description "Objenesis is a small Java library that serves one purpose:
2439 to instantiate a new object of a particular class. It is common to see
2440 restrictions in libraries stating that classes must require a default
2441 constructor. Objenesis aims to overcome these restrictions by bypassing the
2442 constructor on object instantiation.")
2443 (license license:asl2.0)))
2445 (define-public java-easymock
2447 (name "java-easymock")
2451 (uri (string-append "https://github.com/easymock/easymock/"
2452 "archive/easymock-" version ".tar.gz"))
2455 "1yzg0kv256ndr57gpav46cyv4a1ns5sj722l50zpxk3j6sk9hnmi"))))
2456 (build-system ant-build-system)
2458 `(#:jar-name "easymock.jar"
2459 #:source-dir "core/src/main"
2460 #:test-dir "core/src/test"
2462 (modify-phases %standard-phases
2463 ;; FIXME: Android support requires the following packages to be
2464 ;; available: com.google.dexmaker.stock.ProxyBuilder
2465 (add-after 'unpack 'delete-android-support
2467 (with-directory-excursion "core/src/main/java/org/easymock/internal"
2468 (substitute* "MocksControl.java"
2469 (("AndroidSupport.isAndroid\\(\\)") "false")
2470 (("return classProxyFactory = new AndroidClassProxyFactory\\(\\);") ""))
2471 (delete-file "AndroidClassProxyFactory.java"))
2473 (add-after 'unpack 'delete-broken-tests
2475 (with-directory-excursion "core/src/test/java/org/easymock"
2476 ;; This test depends on dexmaker.
2477 (delete-file "tests2/ClassExtensionHelperTest.java")
2479 ;; This is not a test.
2480 (delete-file "tests/BaseEasyMockRunnerTest.java")
2482 ;; This test should be executed with a different runner...
2483 (delete-file "tests2/EasyMockAnnotationsTest.java")
2484 ;; ...but deleting it means that we also have to delete these
2486 (delete-file "tests2/EasyMockRunnerTest.java")
2487 (delete-file "tests2/EasyMockRuleTest.java")
2489 ;; This test fails because the file "easymock.properties" does
2491 (delete-file "tests2/EasyMockPropertiesTest.java"))
2494 `(("java-asm" ,java-asm)
2495 ("java-cglib" ,java-cglib)
2496 ("java-objenesis" ,java-objenesis)))
2498 `(("java-junit" ,java-junit)
2499 ("java-hamcrest-core" ,java-hamcrest-core)))
2500 (home-page "http://easymock.org")
2501 (synopsis "Java library providing mock objects for unit tests")
2502 (description "EasyMock is a Java library that provides an easy way to use
2503 mock objects in unit testing.")
2504 (license license:asl2.0)))
2506 (define-public java-jmock-1
2512 (uri (string-append "https://github.com/jmock-developers/"
2513 "jmock-library/archive/" version ".tar.gz"))
2514 (file-name (string-append "jmock-" version ".tar.gz"))
2517 "0xmrlhq0fszldkbv281k9463mv496143vvmqwpxp62yzjvdkx9w0"))))
2518 (build-system ant-build-system)
2520 `(#:build-target "jars"
2521 #:test-target "run.tests"
2523 (modify-phases %standard-phases
2524 (replace 'install (install-jars "build")))))
2525 (home-page "http://www.jmock.org")
2526 (synopsis "Mock object library for test-driven development")
2527 (description "JMock is a library that supports test-driven development of
2528 Java code with mock objects. Mock objects help you design and test the
2529 interactions between the objects in your programs.
2534 @item makes it quick and easy to define mock objects
2535 @item lets you precisely specify the interactions between
2536 your objects, reducing the brittleness of your tests
2537 @item plugs into your favourite test framework
2538 @item is easy to extend.
2540 (license license:bsd-3)))
2542 (define-public java-jmock
2544 (inherit java-jmock-1)
2549 (uri (string-append "https://github.com/jmock-developers/"
2550 "jmock-library/archive/" version ".tar.gz"))
2551 (file-name (string-append name "-" version ".tar.gz"))
2554 "18650a9g8xffcsdb6w91pbswa7f40fp2sh6s3nclkclz5dbzq8f0"))))
2556 `(("java-hamcrest-all" ,java-hamcrest-all)
2557 ("java-asm" ,java-asm)
2558 ("java-bsh" ,java-bsh)
2559 ("java-junit" ,java-junit)))
2561 `(("cglib" ,java-cglib)))
2563 `(#:jar-name "java-jmock.jar"
2564 #:source-dir "jmock/src/main/java"
2565 #:test-dir "jmock/src/test"))))
2567 (define-public java-jmock-junit4
2569 (inherit java-jmock)
2570 (name "java-jmock-junit4")
2572 `(#:jar-name "java-jmock-junit4.jar"
2573 #:source-dir "jmock-junit4/src/main/java"
2574 #:test-dir "jmock-junit4/src/test"))
2576 `(("java-hamcrest-all" ,java-hamcrest-all)
2577 ("java-asm" ,java-asm)
2578 ("java-bsh" ,java-bsh)
2579 ("java-jmock" ,java-jmock)
2580 ("java-jumit" ,java-junit)))))
2582 (define-public java-jmock-legacy
2584 (inherit java-jmock)
2585 (name "java-jmock-legacy")
2587 `(#:jar-name "java-jmock-legacy.jar"
2588 #:source-dir "jmock-legacy/src/main/java"
2589 #:test-dir "jmock-legacy/src/test"
2591 (modify-phases %standard-phases
2592 (add-before 'check 'copy-tests
2594 ;; This file is a dependancy of some tests
2595 (let ((file "org/jmock/test/acceptance/PackageProtectedType.java"))
2596 (copy-file (string-append "jmock/src/test/java/" file)
2597 (string-append "jmock-legacy/src/test/java/" file))
2600 `(("java-hamcrest-all" ,java-hamcrest-all)
2601 ("java-objenesis" ,java-objenesis)
2602 ("java-cglib" ,java-cglib)
2603 ("java-jmock" ,java-jmock)
2604 ("java-asm" ,java-asm)
2605 ("java-bsh" ,java-bsh)
2606 ("java-junit" ,java-junit)))
2608 `(("java-jmock-junit4" ,java-jmock-junit4)))))
2610 (define-public java-hamcrest-all
2611 (package (inherit java-hamcrest-core)
2612 (name "java-hamcrest-all")
2614 (substitute-keyword-arguments (package-arguments java-hamcrest-core)
2615 ;; FIXME: a unit test fails because org.hamcrest.SelfDescribing is not
2616 ;; found, although it is part of the hamcrest-core library that has
2619 ;; Fixing this one test is insufficient, though, and upstream confirmed
2620 ;; that the latest hamcrest release fails its unit tests when built
2621 ;; with Java 7. See https://github.com/hamcrest/JavaHamcrest/issues/30
2623 ((#:build-target _) "bigjar")
2625 `(modify-phases ,phases
2626 ;; Some build targets override the classpath, so we need to patch
2627 ;; the build.xml to ensure that required dependencies are on the
2629 (add-after 'unpack 'patch-classpath-for-integration
2630 (lambda* (#:key inputs #:allow-other-keys)
2631 (substitute* "build.xml"
2632 ((" build/hamcrest-library-\\$\\{version\\}.jar" line)
2636 (find-files (assoc-ref inputs "java-hamcrest-core") "\\.jar$")
2637 (find-files (assoc-ref inputs "java-junit") "\\.jar$")
2638 (find-files (assoc-ref inputs "java-jmock") "\\.jar$")
2639 (find-files (assoc-ref inputs "java-easymock") "\\.jar$")))
2643 `(("java-junit" ,java-junit)
2644 ("java-jmock" ,java-jmock-1)
2645 ("java-easymock" ,java-easymock)
2646 ("java-hamcrest-core" ,java-hamcrest-core)
2647 ,@(package-inputs java-hamcrest-core)))))
2649 (define-public java-jopt-simple
2651 (name "java-jopt-simple")
2655 (uri (string-append "http://repo1.maven.org/maven2/"
2656 "net/sf/jopt-simple/jopt-simple/"
2657 version "/jopt-simple-"
2658 version "-sources.jar"))
2661 "1v8bzmwmw6qq20gm42xyay6vrd567dra4vqwhgjnqqjz1gs9f8qa"))))
2662 (build-system ant-build-system)
2664 `(#:tests? #f ; there are no tests
2665 #:jar-name "jopt-simple.jar"))
2666 (home-page "https://pholser.github.io/jopt-simple/")
2667 (synopsis "Java library for parsing command line options")
2668 (description "JOpt Simple is a Java library for parsing command line
2669 options, such as those you might pass to an invocation of @code{javac}. In
2670 the interest of striving for simplicity, as closely as possible JOpt Simple
2671 attempts to honor the command line option syntaxes of POSIX @code{getopt} and
2672 GNU @code{getopt_long}. It also aims to make option parser configuration and
2673 retrieval of options and their arguments simple and expressive, without being
2675 (license license:expat)))
2677 (define-public java-commons-math3
2679 (name "java-commons-math3")
2683 (uri (string-append "mirror://apache/commons/math/source/"
2684 "commons-math3-" version "-src.tar.gz"))
2687 "19l6yp44qc5g7wg816nbn5z3zq3xxzwimvbm4a8pczgvpi4i85s6"))))
2688 (build-system ant-build-system)
2690 `(#:build-target "jar"
2691 #:test-target "test"
2693 (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
2694 (junit (assoc-ref %build-inputs "java-junit")))
2695 (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
2696 (string-append "-Dhamcrest.jar=" hamcrest
2697 "/share/java/hamcrest-core.jar")))
2699 (modify-phases %standard-phases
2700 ;; We want to build the jar in the build phase and run the tests
2701 ;; later in a separate phase.
2702 (add-after 'unpack 'untangle-targets
2704 (substitute* "build.xml"
2705 (("name=\"jar\" depends=\"test\"")
2706 "name=\"jar\" depends=\"compile\""))
2708 ;; There is no install target.
2710 (install-jars "target")))))
2712 `(("java-junit" ,java-junit)
2713 ("java-hamcrest-core" ,java-hamcrest-core)))
2714 (home-page "http://commons.apache.org/math/")
2715 (synopsis "Apache Commons mathematics library")
2716 (description "Commons Math is a library of lightweight, self-contained
2717 mathematics and statistics components addressing the most common problems not
2718 available in the Java programming language or Commons Lang.")
2719 (license license:asl2.0)))
2721 (define-public java-jmh
2728 (url "http://hg.openjdk.java.net/code-tools/jmh/")
2729 (changeset version)))
2730 (file-name (string-append name "-" version "-checkout"))
2733 "1fxyxhg9famwcg1prc4cgwb5wzyxqavn3cjm5vz8605xz7x5k084"))))
2734 (build-system ant-build-system)
2736 `(#:jar-name "jmh-core.jar"
2737 #:source-dir "jmh-core/src/main"
2738 #:test-dir "jmh-core/src/test"
2740 (modify-phases %standard-phases
2741 ;; This seems to be a bug in the JDK. It may not be necessary in
2742 ;; future versions of the JDK.
2743 (add-after 'unpack 'fix-bug
2745 (with-directory-excursion
2746 "jmh-core/src/main/java/org/openjdk/jmh/runner/options"
2747 (substitute* '("IntegerValueConverter.java"
2748 "ThreadsValueConverter.java")
2749 (("public Class<Integer> valueType")
2750 "public Class<? extends Integer> valueType")))
2753 `(("java-jopt-simple" ,java-jopt-simple)
2754 ("java-commons-math3" ,java-commons-math3)))
2756 `(("java-junit" ,java-junit)
2757 ("java-hamcrest-core" ,java-hamcrest-core)))
2758 (home-page "http://openjdk.java.net/projects/code-tools/jmh/")
2759 (synopsis "Benchmark harness for the JVM")
2760 (description "JMH is a Java harness for building, running, and analysing
2761 nano/micro/milli/macro benchmarks written in Java and other languages
2762 targetting the JVM.")
2764 (license license:gpl2)))
2766 (define-public java-commons-collections4
2768 (name "java-commons-collections4")
2772 (uri (string-append "mirror://apache/commons/collections/source/"
2773 "commons-collections4-" version "-src.tar.gz"))
2776 "1krfhvggympq4avk7gh6qafzf6b9ip6r1m4lmacikyx04039m0wl"))))
2777 (build-system ant-build-system)
2779 `(#:test-target "test"
2781 (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
2782 (junit (assoc-ref %build-inputs "java-junit"))
2783 (easymock (assoc-ref %build-inputs "java-easymock")))
2784 (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
2785 (string-append "-Dhamcrest.jar=" hamcrest
2786 "/share/java/hamcrest-core.jar")
2787 (string-append "-Deasymock.jar=" easymock
2788 "/share/java/easymock.jar")))
2790 (modify-phases %standard-phases
2792 (install-jars "target")))))
2794 `(("java-junit" ,java-junit)
2795 ("java-hamcrest-core" ,java-hamcrest-core)
2796 ("java-easymock" ,java-easymock)))
2797 (home-page "http://commons.apache.org/collections/")
2798 (synopsis "Collections framework")
2799 (description "The Java Collections Framework is the recognised standard
2800 for collection handling in Java. Commons-Collections seek to build upon the
2801 JDK classes by providing new interfaces, implementations and utilities. There
2802 are many features, including:
2805 @item @code{Bag} interface for collections that have a number of copies of
2807 @item @code{BidiMap} interface for maps that can be looked up from value to
2808 key as well and key to value
2809 @item @code{MapIterator} interface to provide simple and quick iteration over
2811 @item Transforming decorators that alter each object as it is added to the
2813 @item Composite collections that make multiple collections look like one
2814 @item Ordered maps and sets that retain the order elements are added in,
2815 including an LRU based map
2816 @item Reference map that allows keys and/or values to be garbage collected
2818 @item Many comparator implementations
2819 @item Many iterator implementations
2820 @item Adapter classes from array and enumerations to collections
2821 @item Utilities to test or create typical set-theory properties of collections
2822 such as union, intersection, and closure.
2824 (license license:asl2.0)))
2826 (define-public java-commons-io
2828 (name "java-commons-io")
2833 (uri (string-append "mirror://apache/commons/io/source/"
2834 "commons-io-" version "-src.tar.gz"))
2837 "0q5y41jrcjvx9hzs47x5kdhnasdy6rm4bzqd2jxl02w717m7a7v3"))))
2838 (build-system ant-build-system)
2839 (outputs '("out" "doc"))
2841 `(#:test-target "test"
2843 (list (string-append "-Djunit.jar="
2844 (assoc-ref %build-inputs "java-junit")
2845 "/share/java/junit.jar"))
2847 (modify-phases %standard-phases
2848 (add-after 'build 'build-javadoc ant-build-javadoc)
2849 (replace 'install (install-jars "target"))
2850 (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
2852 `(("java-junit" ,java-junit)
2853 ("java-hamcrest-core" ,java-hamcrest-core)))
2854 (home-page "http://commons.apache.org/io/")
2855 (synopsis "Common useful IO related classes")
2856 (description "Commons-IO contains utility classes, stream implementations,
2857 file filters and endian classes.")
2858 (license license:asl2.0)))
2860 (define-public java-commons-lang
2862 (name "java-commons-lang")
2867 (uri (string-append "mirror://apache/commons/lang/source/"
2868 "commons-lang-" version "-src.tar.gz"))
2870 (base32 "1mxwagqadzx1b2al7i0z1v0r235aj2njdyijf02szq0vhmqrfiq5"))))
2871 (build-system ant-build-system)
2872 (outputs '("out" "doc"))
2874 `(#:test-target "test"
2876 (modify-phases %standard-phases
2877 (add-after 'build 'build-javadoc ant-build-javadoc)
2878 (add-before 'check 'disable-failing-test
2880 ;; Disable a failing test
2881 (substitute* "src/test/java/org/apache/commons/lang/\
2882 time/FastDateFormatTest.java"
2883 (("public void testFormat\\(\\)")
2884 "public void disabled_testFormat()"))
2886 (replace 'install (install-jars "target"))
2887 (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
2889 `(("java-junit" ,java-junit)))
2890 (home-page "http://commons.apache.org/lang/")
2891 (synopsis "Extension of the java.lang package")
2892 (description "The Commons Lang components contains a set of Java classes
2893 that provide helper methods for standard Java classes, especially those found
2894 in the @code{java.lang} package in the Sun JDK. The following classes are
2898 @item StringUtils - Helper for @code{java.lang.String}.
2899 @item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets
2900 of characters such as @code{[a-z]} and @code{[abcdez]}.
2901 @item RandomStringUtils - Helper for creating randomised strings.
2902 @item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
2903 @item NumberRange - A range of numbers with an upper and lower bound.
2904 @item ObjectUtils - Helper for @code{java.lang.Object}.
2905 @item SerializationUtils - Helper for serializing objects.
2906 @item SystemUtils - Utility class defining the Java system properties.
2907 @item NestedException package - A sub-package for the creation of nested
2909 @item Enum package - A sub-package for the creation of enumerated types.
2910 @item Builder package - A sub-package for the creation of @code{equals},
2911 @code{hashCode}, @code{compareTo} and @code{toString} methods.
2913 (license license:asl2.0)))
2915 (define-public java-commons-lang3
2917 (name "java-commons-lang3")
2922 (uri (string-append "mirror://apache/commons/lang/source/"
2923 "commons-lang3-" version "-src.tar.gz"))
2925 (base32 "0xpshb9spjhplq5a7mr0y1bgfw8190ik4xj8f569xidfcki1d6kg"))))
2926 (build-system ant-build-system)
2927 (outputs '("out" "doc"))
2929 `(#:test-target "test"
2931 (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-all"))
2932 (junit (assoc-ref %build-inputs "java-junit"))
2933 (easymock (assoc-ref %build-inputs "java-easymock"))
2934 (io (assoc-ref %build-inputs "java-commons-io")))
2935 (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
2936 (string-append "-Dhamcrest.jar=" hamcrest
2937 "/share/java/hamcrest-all.jar")
2938 (string-append "-Dcommons-io.jar=" io
2939 "/share/java/commons-io-"
2940 ,(package-version java-commons-io)
2942 (string-append "-Deasymock.jar=" easymock
2943 "/share/java/easymock.jar")))
2945 (modify-phases %standard-phases
2946 (add-after 'build 'build-javadoc ant-build-javadoc)
2947 (replace 'install (install-jars "target"))
2948 (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
2950 `(("java-junit" ,java-junit)
2951 ("java-commons-io" ,java-commons-io)
2952 ("java-hamcrest-all" ,java-hamcrest-all)
2953 ("java-easymock" ,java-easymock)))
2954 (home-page "http://commons.apache.org/lang/")
2955 (synopsis "Extension of the java.lang package")
2956 (description "The Commons Lang components contains a set of Java classes
2957 that provide helper methods for standard Java classes, especially those found
2958 in the @code{java.lang} package. The following classes are included:
2961 @item StringUtils - Helper for @code{java.lang.String}.
2962 @item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets of
2963 characters such as @code{[a-z]} and @code{[abcdez]}.
2964 @item RandomStringUtils - Helper for creating randomised strings.
2965 @item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
2966 @item NumberRange - A range of numbers with an upper and lower bound.
2967 @item ObjectUtils - Helper for @code{java.lang.Object}.
2968 @item SerializationUtils - Helper for serializing objects.
2969 @item SystemUtils - Utility class defining the Java system properties.
2970 @item NestedException package - A sub-package for the creation of nested
2972 @item Enum package - A sub-package for the creation of enumerated types.
2973 @item Builder package - A sub-package for the creation of @code{equals},
2974 @code{hashCode}, @code{compareTo} and @code{toString} methods.
2976 (license license:asl2.0)))
2978 (define-public java-jsr305
2980 (name "java-jsr305")
2984 (uri (string-append "https://repo1.maven.org/maven2/"
2985 "com/google/code/findbugs/"
2986 "jsr305/" version "/jsr305-"
2987 version "-sources.jar"))
2990 "1rh6jin9v7jqpq3kf1swl868l8i94r636n03pzpsmgr8v0lh9j2n"))))
2991 (build-system ant-build-system)
2993 `(#:tests? #f ; no tests included
2994 #:jar-name "jsr305.jar"))
2995 (home-page "http://findbugs.sourceforge.net/")
2996 (synopsis "Annotations for the static analyzer called findbugs")
2997 (description "This package provides annotations for the findbugs package.
2998 It provides packages in the @code{javax.annotations} namespace.")
2999 (license license:asl2.0)))
3001 (define-public java-guava
3004 ;; This is the last release of Guava that can be built with Java 7.
3008 (uri (string-append "https://github.com/google/guava/"
3009 "releases/download/v" version
3010 "/guava-" version "-sources.jar"))
3013 "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
3014 (build-system ant-build-system)
3016 `(#:tests? #f ; no tests included
3017 #:jar-name "guava.jar"
3019 (modify-phases %standard-phases
3020 (add-after 'unpack 'trim-sources
3022 (with-directory-excursion "src/com/google/common"
3023 ;; Remove annotations to avoid extra dependencies:
3024 ;; * "j2objc" annotations are used when converting Java to
3026 ;; * "errorprone" annotations catch common Java mistakes at
3028 ;; * "IgnoreJRERequirement" is used for Android.
3029 (substitute* (find-files "." "\\.java$")
3030 (("import com.google.j2objc.*") "")
3031 (("import com.google.errorprone.annotation.*") "")
3032 (("import org.codehaus.mojo.animal_sniffer.*") "")
3033 (("@CanIgnoreReturnValue") "")
3036 (("@RetainedWith") "")
3038 (("@ForOverride") "")
3039 (("@J2ObjCIncompatible") "")
3040 (("@IgnoreJRERequirement") "")))
3043 `(("java-jsr305" ,java-jsr305)))
3044 (home-page "https://github.com/google/guava")
3045 (synopsis "Google core libraries for Java")
3046 (description "Guava is a set of core libraries that includes new
3047 collection types (such as multimap and multiset), immutable collections, a
3048 graph library, functional types, an in-memory cache, and APIs/utilities for
3049 concurrency, I/O, hashing, primitives, reflection, string processing, and much
3051 (license license:asl2.0)))
3053 ;; The java-commons-logging package provides adapters to many different
3054 ;; logging frameworks. To avoid an excessive dependency graph we try to build
3055 ;; it with only a minimal set of adapters.
3056 (define-public java-commons-logging-minimal
3058 (name "java-commons-logging-minimal")
3062 (uri (string-append "mirror://apache/commons/logging/source/"
3063 "commons-logging-" version "-src.tar.gz"))
3066 "10bwcy5w8d7y39n0krlwhnp8ds3kj5zhmzj0zxnkw0qdlsjmsrj9"))))
3067 (build-system ant-build-system)
3069 `(#:tests? #f ; avoid dependency on logging frameworks
3070 #:jar-name "commons-logging-minimal.jar"
3072 (modify-phases %standard-phases
3073 (add-after 'unpack 'delete-adapters-and-tests
3075 ;; Delete all adapters except for NoOpLog, SimpleLog, and
3076 ;; LogFactoryImpl. NoOpLog is required to build; LogFactoryImpl
3077 ;; is used by applications; SimpleLog is the only actually usable
3078 ;; implementation that does not depend on another logging
3082 (delete-file (string-append
3083 "src/main/java/org/apache/commons/logging/impl/" file)))
3084 (list "Jdk13LumberjackLogger.java"
3085 "WeakHashtable.java"
3087 "ServletContextCleaner.java"
3090 "LogKitLogger.java"))
3091 (delete-file-recursively "src/test")
3093 (home-page "http://commons.apache.org/logging/")
3094 (synopsis "Common API for logging implementations")
3095 (description "The Logging package is a thin bridge between different
3096 logging implementations. A library that uses the commons-logging API can be
3097 used with any logging implementation at runtime.")
3098 (license license:asl2.0)))
3100 ;; This is the last release of the 1.x series.
3101 (define-public java-mockito-1
3103 (name "java-mockito")
3107 (uri (string-append "http://repo1.maven.org/maven2/"
3108 "org/mockito/mockito-core/" version
3109 "/mockito-core-" version "-sources.jar"))
3112 "0vmiwnwpf83g2q7kj1rislmja8fpvqkixjhawh7nxnygx6pq11kc"))))
3113 (build-system ant-build-system)
3115 `(#:jar-name "mockito.jar"
3116 #:tests? #f ; no tests included
3117 ;; FIXME: patch-and-repack does not support jars, so we have to apply
3118 ;; patches in build phases.
3120 (modify-phases %standard-phases
3121 ;; Mockito was developed against a different version of hamcrest,
3122 ;; which does not require matcher implementations to provide an
3123 ;; implementation of the "describeMismatch" method. We add this
3124 ;; simple definition to pass the build with our version of hamcrest.
3125 (add-after 'unpack 'fix-hamcrest-build-error
3127 (substitute* "src/org/mockito/internal/matchers/LocalizedMatcher.java"
3128 (("public Matcher getActualMatcher\\(\\) .*" line)
3130 public void describeMismatch(Object item, Description description) {
3131 actualMatcher.describeMismatch(item, description);
3135 ;; Mockito bundles cglib. We have a cglib package, so let's use
3137 (add-after 'unpack 'use-system-libraries
3139 (with-directory-excursion "src/org/mockito/internal/creation/cglib"
3140 (substitute* '("CGLIBHacker.java"
3141 "CglibMockMaker.java"
3142 "ClassImposterizer.java"
3143 "DelegatingMockitoMethodProxy.java"
3144 "MethodInterceptorFilter.java"
3145 "MockitoNamingPolicy.java"
3146 "SerializableMockitoMethodProxy.java"
3147 "SerializableNoOp.java")
3148 (("import org.mockito.cglib") "import net.sf.cglib")))
3151 `(("java-junit" ,java-junit)
3152 ("java-objenesis" ,java-objenesis)
3153 ("java-cglib" ,java-cglib)
3154 ("java-hamcrest-core" ,java-hamcrest-core)))
3155 (home-page "http://mockito.org")
3156 (synopsis "Mockito is a mock library for Java")
3157 (description "Mockito is a mocking library for Java which lets you write
3158 tests with a clean and simple API. It generates mocks using reflection, and
3159 it records all mock invocations, including methods arguments.")
3160 (license license:asl2.0)))
3162 (define-public java-httpcomponents-httpcore
3164 (name "java-httpcomponents-httpcore")
3168 (uri (string-append "mirror://apache//httpcomponents/httpcore/"
3169 "source/httpcomponents-core-"
3170 version "-src.tar.gz"))
3173 "02bwcf38y4vgwq7kj2s6q7qrmma641r5lacivm16kgxvb2j6h1vy"))))
3174 (build-system ant-build-system)
3176 `(#:jar-name "httpcomponents-httpcore.jar"
3178 (modify-phases %standard-phases
3179 (add-after 'unpack 'chdir
3180 (lambda _ (chdir "httpcore") #t)))))
3182 `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
3183 ("java-commons-lang3" ,java-commons-lang3)))
3185 `(("java-junit" ,java-junit)
3186 ("java-mockito" ,java-mockito-1)))
3187 (home-page "https://hc.apache.org/httpcomponents-core-4.4.x/index.html")
3188 (synopsis "Low level HTTP transport components")
3189 (description "HttpCore is a set of low level HTTP transport components
3190 that can be used to build custom client and server side HTTP services with a
3191 minimal footprint. HttpCore supports two I/O models: blocking I/O model based
3192 on the classic Java I/O and non-blocking, event driven I/O model based on Java
3195 This package provides the blocking I/O model library.")
3196 (license license:asl2.0)))
3198 (define-public java-httpcomponents-httpcore-nio
3199 (package (inherit java-httpcomponents-httpcore)
3200 (name "java-httpcomponents-httpcore-nio")
3202 `(#:jar-name "httpcomponents-httpcore-nio.jar"
3204 (modify-phases %standard-phases
3205 (add-after 'unpack 'chdir
3206 (lambda _ (chdir "httpcore-nio") #t)))))
3208 `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
3209 ("java-hamcrest-core" ,java-hamcrest-core)
3210 ,@(package-inputs java-httpcomponents-httpcore)))
3211 (description "HttpCore is a set of low level HTTP transport components
3212 that can be used to build custom client and server side HTTP services with a
3213 minimal footprint. HttpCore supports two I/O models: blocking I/O model based
3214 on the classic Java I/O and non-blocking, event driven I/O model based on Java
3217 This package provides the non-blocking I/O model library based on Java
3220 (define-public java-httpcomponents-httpcore-ab
3221 (package (inherit java-httpcomponents-httpcore)
3222 (name "java-httpcomponents-httpcore-ab")
3224 `(#:jar-name "httpcomponents-httpcore-ab.jar"
3226 (modify-phases %standard-phases
3227 (add-after 'unpack 'chdir
3228 (lambda _ (chdir "httpcore-ab") #t)))))
3230 `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
3231 ("java-commons-cli" ,java-commons-cli)
3232 ("java-hamcrest-core" ,java-hamcrest-core)
3233 ,@(package-inputs java-httpcomponents-httpcore)))
3234 (synopsis "Apache HttpCore benchmarking tool")
3235 (description "This package provides the HttpCore benchmarking tool. It is
3236 an Apache AB clone based on HttpCore.")))
3238 (define-public java-httpcomponents-httpclient
3240 (name "java-httpcomponents-httpclient")
3244 (uri (string-append "mirror://apache/httpcomponents/httpclient/"
3245 "source/httpcomponents-client-"
3246 version "-src.tar.gz"))
3249 "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
3250 (build-system ant-build-system)
3252 `(#:jar-name "httpcomponents-httpclient.jar"
3254 (modify-phases %standard-phases
3255 (add-after 'unpack 'chdir
3256 (lambda _ (chdir "httpclient") #t)))))
3258 `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
3259 ("java-commons-codec" ,java-commons-codec)
3260 ("java-hamcrest-core" ,java-hamcrest-core)
3261 ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
3262 ("java-mockito" ,java-mockito-1)
3263 ("java-junit" ,java-junit)))
3264 (home-page "https://hc.apache.org/httpcomponents-client-ga/")
3265 (synopsis "HTTP client library for Java")
3266 (description "Although the @code{java.net} package provides basic
3267 functionality for accessing resources via HTTP, it doesn't provide the full
3268 flexibility or functionality needed by many applications. @code{HttpClient}
3269 seeks to fill this void by providing an efficient, up-to-date, and
3270 feature-rich package implementing the client side of the most recent HTTP
3271 standards and recommendations.")
3272 (license license:asl2.0)))
3274 (define-public java-httpcomponents-httpmime
3275 (package (inherit java-httpcomponents-httpclient)
3276 (name "java-httpcomponents-httpmime")
3278 `(#:jar-name "httpcomponents-httpmime.jar"
3280 (modify-phases %standard-phases
3281 (add-after 'unpack 'chdir
3282 (lambda _ (chdir "httpmime") #t)))))
3284 `(("java-httpcomponents-httpclient" ,java-httpcomponents-httpclient)
3285 ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
3286 ("java-junit" ,java-junit)
3287 ("java-hamcrest-core" ,java-hamcrest-core)))))
3289 (define-public java-commons-net
3291 (name "java-commons-net")
3295 (uri (string-append "mirror://apache/commons/net/source/"
3296 "commons-net-" version "-src.tar.gz"))
3299 "0n0cmnddk9qdqhjvka8pc6hd9mn2qi3166f1s6xk32h7rfy1adxr"))))
3300 (build-system ant-build-system)
3302 `(;; FIXME: MainTest.java tries to read "examples.properties" (which
3303 ;; should be "resources/examples/examples.properties"), but gets "null"
3306 #:jar-name "commons-net.jar"))
3308 `(("java-junit" ,java-junit)
3309 ("java-hamcrest-core" ,java-hamcrest-core)))
3310 (home-page "http://commons.apache.org/net/")
3311 (synopsis "Client library for many basic Internet protocols")
3312 (description "The Apache Commons Net library implements the client side of
3313 many basic Internet protocols. The purpose of the library is to provide
3314 fundamental protocol access, not higher-level abstractions.")
3315 (license license:asl2.0)))
3317 (define-public java-jsch
3323 (uri (string-append "mirror://sourceforge/jsch/jsch/"
3324 version "/jsch-" version ".zip"))
3327 "029rdddyq1mh3ghryh3ki99kba1xkf1d1swjv2vi6lk6zzjy2wdb"))))
3328 (build-system ant-build-system)
3330 `(#:build-target "dist"
3331 #:tests? #f ; no tests included
3333 (modify-phases %standard-phases
3334 (replace 'install (install-jars "dist")))))
3336 `(("unzip" ,unzip)))
3337 (home-page "http://www.jcraft.com/jsch/")
3338 (synopsis "Pure Java implementation of SSH2")
3339 (description "JSch is a pure Java implementation of SSH2. JSch allows you
3340 to connect to an SSH server and use port forwarding, X11 forwarding, file
3341 transfer, etc., and you can integrate its functionality into your own Java
3343 (license license:bsd-3)))
3345 (define-public java-commons-compress
3347 (name "java-commons-compress")
3351 (uri (string-append "mirror://apache/commons/compress/source/"
3352 "commons-compress-" version "-src.tar.gz"))
3355 "1vjqvavrn0babffn1kciz6v52ibwq2vwhzlb95hazis3lgllnxc8"))))
3356 (build-system ant-build-system)
3358 `(#:jar-name "commons-compress.jar"
3360 (modify-phases %standard-phases
3361 (add-after 'unpack 'delete-bad-tests
3363 (with-directory-excursion "src/test/java/org/apache/commons/compress/"
3364 ;; FIXME: These tests really should not fail. Maybe they are
3365 ;; indicative of problems with our Java packaging work.
3367 ;; This test fails with a null pointer exception.
3368 (delete-file "archivers/sevenz/SevenZOutputFileTest.java")
3369 ;; This test fails to open test resources.
3370 (delete-file "archivers/zip/ExplodeSupportTest.java")
3372 ;; FIXME: This test adds a dependency on powermock, which is hard to
3373 ;; package at this point.
3374 ;; https://github.com/powermock/powermock
3375 (delete-file "archivers/sevenz/SevenZNativeHeapTest.java"))
3378 `(("java-junit" ,java-junit)
3379 ("java-hamcrest-core" ,java-hamcrest-core)
3380 ("java-mockito" ,java-mockito-1)
3381 ("java-xz" ,java-xz)))
3382 (home-page "https://commons.apache.org/proper/commons-compress/")
3383 (synopsis "Java library for working with compressed files")
3384 (description "The Apache Commons Compress library defines an API for
3385 working with compressed files such as ar, cpio, Unix dump, tar, zip, gzip, XZ,
3386 Pack200, bzip2, 7z, arj, lzma, snappy, DEFLATE, lz4 and Z files.")
3387 (license license:asl2.0)))
3389 (define-public java-commons-net
3391 (name "java-commons-net")
3395 (uri (string-append "mirror://apache/commons/net/source/"
3396 "commons-net-" version "-src.tar.gz"))
3399 "0n0cmnddk9qdqhjvka8pc6hd9mn2qi3166f1s6xk32h7rfy1adxr"))))
3400 (build-system ant-build-system)
3402 `(;; FIXME: MainTest.java tries to read "examples.properties" (which
3403 ;; should be "resources/examples/examples.properties"), but gets "null"
3406 #:jar-name "commons-net.jar"))
3408 `(("java-junit" ,java-junit)
3409 ("java-hamcrest-core" ,java-hamcrest-core)))
3410 (home-page "http://commons.apache.org/net/")
3411 (synopsis "Client library for many basic Internet protocols")
3412 (description "The Apache Commons Net library implements the client side of
3413 many basic Internet protocols. The purpose of the library is to provide
3414 fundamental protocol access, not higher-level abstractions.")
3415 (license license:asl2.0)))
3417 (define-public java-osgi-annotation
3419 (name "java-osgi-annotation")
3423 (uri (string-append "https://repo1.maven.org/maven2/"
3424 "org/osgi/org.osgi.annotation/" version "/"
3425 "org.osgi.annotation-" version "-sources.jar"))
3428 "1q718mb7gqg726rh6pc2hcisn8v50nv35abbir0jypmffhiii85w"))))
3429 (build-system ant-build-system)
3431 `(#:tests? #f ; no tests
3432 #:jar-name "osgi-annotation.jar"))
3433 (home-page "http://www.osgi.org")
3434 (synopsis "Annotation module of OSGi framework")
3436 "OSGi, for Open Services Gateway initiative framework, is a module system
3437 and service platform for the Java programming language. This package contains
3438 the OSGi annotation module, providing additional services to help dynamic
3440 (license license:asl2.0)))
3442 (define-public java-osgi-core
3444 (name "java-osgi-core")
3448 (uri (string-append "https://repo1.maven.org/maven2/"
3449 "org/osgi/org.osgi.core/" version "/"
3450 "org.osgi.core-" version "-sources.jar"))
3453 "19bpf5jx32jq9789gyhin35q5v7flmw0p9mk7wbgqpxqfmxyiabv"))))
3454 (build-system ant-build-system)
3456 `(#:tests? #f ; no tests
3457 #:jar-name "osgi-core.jar"))
3459 `(("java-osgi-annotation" ,java-osgi-annotation)))
3460 (home-page "http://www.osgi.org")
3461 (synopsis "Core module of OSGi framework")
3463 "OSGi, for Open Services Gateway initiative framework, is a module system
3464 and service platform for the Java programming language. This package contains
3465 the OSGi Core module.")
3466 (license license:asl2.0)))
3468 (define-public java-osgi-service-event
3470 (name "java-osgi-service-event")
3474 (uri (string-append "https://repo1.maven.org/maven2/"
3475 "org/osgi/org.osgi.service.event/"
3476 version "/org.osgi.service.event-"
3477 version "-sources.jar"))
3480 "1nyhlgagwym75bycnjczwbnpymv2iw84zbhvvzk84g9q736i6qxm"))))
3481 (build-system ant-build-system)
3483 `(#:tests? #f ; no tests
3484 #:jar-name "osgi-service-event.jar"))
3486 `(("java-osgi-annotation" ,java-osgi-annotation)
3487 ("java-osgi-core" ,java-osgi-core)))
3488 (home-page "http://www.osgi.org")
3489 (synopsis "OSGi service event module")
3491 "OSGi, for Open Services Gateway initiative framework, is a module system
3492 and service platform for the Java programming language. This package contains
3493 the OSGi @code{org.osgi.service.event} module.")
3494 (license license:asl2.0)))
3496 (define-public java-eclipse-osgi
3498 (name "java-eclipse-osgi")
3502 (uri (string-append "https://repo1.maven.org/maven2/"
3503 "org/eclipse/platform/org.eclipse.osgi/"
3504 version "/org.eclipse.osgi-"
3505 version "-sources.jar"))
3508 "00cqc6lb29n0zv68b4l842vzkwawvbr7gshfdygsk8sicvcq2c7b"))))
3509 (build-system ant-build-system)
3511 `(#:tests? #f ; no tests included
3512 #:jar-name "eclipse-equinox-osgi.jar"))
3514 `(("java-osgi-annotation" ,java-osgi-annotation)))
3515 (home-page "http://www.eclipse.org/equinox/")
3516 (synopsis "Eclipse Equinox OSGi framework")
3517 (description "This package provides an implementation of the OSGi Core
3519 (license license:epl1.0)))
3521 (define-public java-eclipse-equinox-common
3523 (name "java-eclipse-equinox-common")
3527 (uri (string-append "https://repo1.maven.org/maven2/"
3528 "org/eclipse/platform/org.eclipse.equinox.common/"
3529 version "/org.eclipse.equinox.common-"
3530 version "-sources.jar"))
3533 "12aazpkgw46r1qj0pr421jzwhbmsizd97r37krd7njnbrdgfzksc"))))
3534 (build-system ant-build-system)
3536 `(#:tests? #f ; no tests included
3537 #:jar-name "eclipse-equinox-common.jar"))
3539 `(("java-eclipse-osgi" ,java-eclipse-osgi)))
3540 (home-page "http://www.eclipse.org/equinox/")
3541 (synopsis "Common Eclipse runtime")
3542 (description "This package provides the common Eclipse runtime.")
3543 (license license:epl1.0)))
3545 (define-public java-eclipse-core-jobs
3547 (name "java-eclipse-core-jobs")
3551 (uri (string-append "https://repo1.maven.org/maven2/"
3552 "org/eclipse/platform/org.eclipse.core.jobs/"
3553 version "/org.eclipse.core.jobs-"
3554 version "-sources.jar"))
3557 "0395b8lh0km8vhzjnchvs1rii1qz48hyvb2wqfaq4yhklbwihq4b"))))
3558 (build-system ant-build-system)
3560 `(#:tests? #f ; no tests included
3561 #:jar-name "eclipse-core-jobs.jar"))
3563 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3564 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3565 (home-page "http://www.eclipse.org/equinox/")
3566 (synopsis "Eclipse jobs mechanism")
3567 (description "This package provides the Eclipse jobs mechanism.")
3568 (license license:epl1.0)))
3570 (define-public java-eclipse-equinox-registry
3572 (name "java-eclipse-equinox-registry")
3576 (uri (string-append "https://repo1.maven.org/maven2/"
3577 "org/eclipse/platform/org.eclipse.equinox.registry/"
3578 version "/org.eclipse.equinox.registry-"
3579 version "-sources.jar"))
3582 "1i9sgymh2fy5vdgk5y7s3qvrlbgh4l93ddqi3v4zmca7hwrlhf9k"))))
3583 (build-system ant-build-system)
3585 `(#:tests? #f ; no tests included
3586 #:jar-name "eclipse-equinox-registry.jar"))
3588 `(("java-eclipse-core-jobs" ,java-eclipse-core-jobs)
3589 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3590 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3591 (home-page "http://www.eclipse.org/equinox/")
3592 (synopsis "Eclipse extension registry support")
3593 (description "This package provides support for the Eclipse extension
3595 (license license:epl1.0)))
3597 (define-public java-eclipse-equinox-app
3599 (name "java-eclipse-equinox-app")
3603 (uri (string-append "https://repo1.maven.org/maven2/"
3604 "org/eclipse/platform/org.eclipse.equinox.app/"
3605 version "/org.eclipse.equinox.app-"
3606 version "-sources.jar"))
3609 "0nhvbp93y203ar7y59gb0mz3w2d3jlqhr0c9hii9bcfpmr7imdab"))))
3610 (build-system ant-build-system)
3612 `(#:tests? #f ; no tests included
3613 #:jar-name "eclipse-equinox-app.jar"))
3615 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3616 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3617 ("java-eclipse-osgi" ,java-eclipse-osgi)
3618 ("java-osgi-service-event" ,java-osgi-service-event)))
3619 (home-page "http://www.eclipse.org/equinox/")
3620 (synopsis "Equinox application container")
3621 (description "This package provides the Equinox application container for
3623 (license license:epl1.0)))
3625 (define-public java-eclipse-equinox-preferences
3627 (name "java-eclipse-equinox-preferences")
3631 (uri (string-append "https://repo1.maven.org/maven2/"
3632 "org/eclipse/platform/org.eclipse.equinox.preferences/"
3633 version "/org.eclipse.equinox.preferences-"
3634 version "-sources.jar"))
3637 "0k7w6c141sqym4fy3af0qkwpy4pdh2vsjpjba6rp5fxyqa24v0a2"))))
3638 (build-system ant-build-system)
3640 `(#:tests? #f ; no tests included
3641 #:jar-name "eclipse-equinox-preferences.jar"))
3643 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3644 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3645 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3646 (home-page "http://www.eclipse.org/equinox/")
3647 (synopsis "Eclipse preferences mechanism")
3648 (description "This package provides the Eclipse preferences mechanism with
3649 the module @code{org.eclipse.equinox.preferences}.")
3650 (license license:epl1.0)))
3652 (define-public java-eclipse-core-contenttype
3654 (name "java-eclipse-core-contenttype")
3658 (uri (string-append "https://repo1.maven.org/maven2/"
3659 "org/eclipse/platform/org.eclipse.core.contenttype/"
3660 version "/org.eclipse.core.contenttype-"
3661 version "-sources.jar"))
3664 "1wcqcv7ijwv5rh748vz3x9pkmjl9w1r0k0026k56n8yjl4rrmspi"))))
3665 (build-system ant-build-system)
3667 `(#:tests? #f ; no tests included
3668 #:jar-name "eclipse-core-contenttype.jar"))
3670 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3671 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3672 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3673 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3674 (home-page "http://www.eclipse.org/")
3675 (synopsis "Eclipse content mechanism")
3676 (description "This package provides the Eclipse content mechanism in the
3677 @code{org.eclipse.core.contenttype} module.")
3678 (license license:epl1.0)))
3680 (define-public java-eclipse-core-runtime
3682 (name "java-eclipse-core-runtime")
3686 (uri (string-append "https://repo1.maven.org/maven2/"
3687 "org/eclipse/platform/org.eclipse.core.runtime/"
3688 version "/org.eclipse.core.runtime-"
3689 version "-sources.jar"))
3692 "16mkf8jgj35pgzms7w1gyfq0gfm4ixw6c5xbbxzdj1la56c758ya"))))
3693 (build-system ant-build-system)
3695 `(#:tests? #f ; no tests included
3696 #:jar-name "eclipse-core-runtime.jar"))
3698 `(("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
3699 ("java-eclipse-core-jobs" ,java-eclipse-core-jobs)
3700 ("java-eclipse-equinox-app" ,java-eclipse-equinox-app)
3701 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3702 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3703 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3704 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3705 (home-page "https://www.eclipse.org/")
3706 (synopsis "Eclipse core runtime")
3707 (description "This package provides the Eclipse core runtime with the
3708 module @code{org.eclipse.core.runtime}.")
3709 (license license:epl1.0)))
3711 (define-public java-eclipse-core-filesystem
3713 (name "java-eclipse-core-filesystem")
3717 (uri (string-append "https://repo1.maven.org/maven2/"
3718 "org/eclipse/platform/org.eclipse.core.filesystem/"
3719 version "/org.eclipse.core.filesystem-"
3720 version "-sources.jar"))
3723 "0km1bhwjim4rfy3pkvjhvy31kgsyf2ncx0mlkmbf5n6g57pphdyj"))))
3724 (build-system ant-build-system)
3726 `(#:tests? #f ; no tests included
3727 #:jar-name "eclipse-core-filesystem.jar"))
3729 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3730 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3731 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3732 (home-page "https://www.eclipse.org/")
3733 (synopsis "Eclipse core file system")
3734 (description "This package provides the Eclipse core file system with the
3735 module @code{org.eclipse.core.filesystem}.")
3736 (license license:epl1.0)))
3738 (define-public java-eclipse-core-expressions
3740 (name "java-eclipse-core-expressions")
3744 (uri (string-append "https://repo1.maven.org/maven2/"
3745 "org/eclipse/platform/org.eclipse.core.expressions/"
3746 version "/org.eclipse.core.expressions-"
3747 version "-sources.jar"))
3750 "18bw2l875gmygvpagpgk9l24qzbdjia4ag12nw6fi8v8yaq4987f"))))
3751 (build-system ant-build-system)
3753 `(#:tests? #f ; no tests included
3754 #:jar-name "eclipse-core-expressions.jar"))
3756 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3757 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3758 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3759 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3760 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3761 (home-page "https://www.eclipse.org/")
3762 (synopsis "Eclipse core expression language")
3763 (description "This package provides the Eclipse core expression language
3764 with the @code{org.eclipse.core.expressions} module.")
3765 (license license:epl1.0)))
3767 (define-public java-eclipse-core-variables
3769 (name "java-eclipse-core-variables")
3773 (uri (string-append "https://repo1.maven.org/maven2/"
3774 "org/eclipse/platform/org.eclipse.core.variables/"
3775 version "/org.eclipse.core.variables-"
3776 version "-sources.jar"))
3779 "12dirh03zi4n5x5cj07vzrhkmnqy6h9q10h9j605pagmpmifyxmy"))))
3780 (build-system ant-build-system)
3782 `(#:tests? #f ; no tests included
3783 #:jar-name "eclipse-core-variables.jar"))
3785 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3786 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3787 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3788 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3789 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3790 (home-page "https://www.eclipse.org/platform")
3791 (synopsis "Eclipse core variables")
3792 (description "This package provides the Eclipse core variables module
3793 @code{org.eclipse.core.variables}.")
3794 (license license:epl1.0)))
3796 (define-public java-eclipse-ant-core
3798 (name "java-eclipse-ant-core")
3802 (uri (string-append "https://repo1.maven.org/maven2/"
3803 "org/eclipse/platform/org.eclipse.ant.core/"
3804 version "/org.eclipse.ant.core-"
3805 version "-sources.jar"))
3808 "11g3if794qjlk98mz9zch22rr56sd7z63vn4i7k2icr8cq5bfqg7"))))
3809 (build-system ant-build-system)
3811 `(#:tests? #f ; no tests included
3812 #:jar-name "eclipse-ant-core.jar"))
3814 `(("java-eclipse-equinox-app" ,java-eclipse-equinox-app)
3815 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3816 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3817 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3818 ("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
3819 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3820 ("java-eclipse-core-variables" ,java-eclipse-core-variables)
3821 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3822 (home-page "https://www.eclipse.org/platform")
3823 (synopsis "Ant build tool core libraries")
3824 (description "This package provides the ant build tool core libraries with
3825 the module @code{org.eclipse.ant.core}.")
3826 (license license:epl1.0)))
3828 (define-public java-eclipse-core-resources
3830 (name "java-eclipse-core-resources")
3834 (uri (string-append "https://repo1.maven.org/maven2/"
3835 "org/eclipse/platform/org.eclipse.core.resources/"
3836 version "/org.eclipse.core.resources-"
3837 version "-sources.jar"))
3840 "1hrfxrll6cpcagfksk2na1ypvkcnsp0fk6n3vcsrn97qayf9mx9l"))))
3841 (build-system ant-build-system)
3843 `(#:tests? #f ; no tests included
3844 #:jar-name "eclipse-core-resources.jar"))
3846 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3847 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3848 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3849 ("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
3850 ("java-eclipse-core-expressions" ,java-eclipse-core-expressions)
3851 ("java-eclipse-core-filesystem" ,java-eclipse-core-filesystem)
3852 ("java-eclipse-core-jobs" ,java-eclipse-core-jobs)
3853 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3854 ("java-eclipse-ant-core" ,java-eclipse-ant-core)
3855 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3856 (home-page "https://www.eclipse.org/")
3857 (synopsis "Eclipse core resource management")
3858 (description "This package provides the Eclipse core resource management
3859 module @code{org.eclipse.core.resources}.")
3860 (license license:epl1.0)))
3862 (define-public java-eclipse-compare-core
3864 (name "java-eclipse-compare-core")
3868 (uri (string-append "https://repo1.maven.org/maven2/"
3869 "org/eclipse/platform/org.eclipse.compare.core/"
3870 version "/org.eclipse.compare.core-"
3871 version "-sources.jar"))
3874 "10g37r0pbiffyv2wk35c6g5lwzkdipkl0kkjp41v84dln46xm4dg"))))
3875 (build-system ant-build-system)
3877 `(#:tests? #f ; no tests included
3878 #:jar-name "eclipse-compare-core.jar"))
3880 `(("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3881 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3882 ("java-eclipse-osgi" ,java-eclipse-osgi)
3883 ("java-icu4j" ,java-icu4j)))
3884 (home-page "https://www.eclipse.org/")
3885 (synopsis "Eclipse core compare support")
3886 (description "This package provides the Eclipse core compare support
3887 module @code{org.eclipse.compare.core}.")
3888 (license license:epl1.0)))
3890 (define-public java-eclipse-team-core
3892 (name "java-eclipse-team-core")
3896 (uri (string-append "https://repo1.maven.org/maven2/"
3897 "org/eclipse/platform/org.eclipse.team.core/"
3898 version "/org.eclipse.team.core-"
3899 version "-sources.jar"))
3902 "02j2jzqgb26zx2d5ahxmvijw6j4r0la90zl5c3i65x6z19ciyam7"))))
3903 (build-system ant-build-system)
3905 `(#:tests? #f ; no tests included
3906 #:jar-name "eclipse-team-core.jar"))
3908 `(("java-eclipse-compare-core" ,java-eclipse-compare-core)
3909 ("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
3910 ("java-eclipse-core-filesystem" ,java-eclipse-core-filesystem)
3911 ("java-eclipse-core-jobs" ,java-eclipse-core-jobs)
3912 ("java-eclipse-core-resources" ,java-eclipse-core-resources)
3913 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
3914 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3915 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
3916 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
3917 ("java-eclipse-osgi" ,java-eclipse-osgi)))
3918 (home-page "https://www.eclipse.org/platform")
3919 (synopsis "Eclipse team support core")
3920 (description "This package provides the Eclipse team support core module
3921 @code{org.eclipse.team.core}.")
3922 (license license:epl1.0)))
3924 (define-public java-eclipse-core-commands
3926 (name "java-eclipse-core-commands")
3930 (uri (string-append "https://repo1.maven.org/maven2/"
3931 "org/eclipse/platform/org.eclipse.core.commands/"
3932 version "/org.eclipse.core.commands-"
3933 version "-sources.jar"))
3936 "0yjn482qndcfrsq3jd6vnhcylp16420f5aqkrwr8spsprjigjcr9"))))
3937 (build-system ant-build-system)
3939 `(#:tests? #f ; no tests included
3940 #:jar-name "eclipse-core-commands.jar"))
3942 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)))
3943 (home-page "https://www.eclipse.org/platform")
3944 (synopsis "Eclipse core commands")
3945 (description "This package provides Eclipse core commands in the module
3946 @code{org.eclipse.core.commands}.")
3947 (license license:epl1.0)))
3949 (define-public java-eclipse-text
3951 (name "java-eclipse-text")
3955 (uri (string-append "https://repo1.maven.org/maven2/"
3956 "org/eclipse/platform/org.eclipse.text/"
3957 version "/org.eclipse.text-"
3958 version "-sources.jar"))
3961 "0scz70vzz5qs5caji9f5q01vkqnvip7dpri1q07l8wbbdcxn4cq1"))))
3962 (build-system ant-build-system)
3964 `(#:tests? #f ; no tests included
3965 #:jar-name "eclipse-text.jar"
3967 (modify-phases %standard-phases
3968 ;; When creating a new category we must make sure that the new list
3969 ;; matches List<Position>. By default it seems to be too generic
3970 ;; (ArrayList<Object>), so we specialize it to ArrayList<Position>.
3971 ;; Without this we get this error:
3973 ;; [javac] .../src/org/eclipse/jface/text/AbstractDocument.java:376:
3974 ;; error: method put in interface Map<K,V> cannot be applied to given types;
3975 ;; [javac] fPositions.put(category, new ArrayList<>());
3977 ;; [javac] required: String,List<Position>
3978 ;; [javac] found: String,ArrayList<Object>
3979 ;; [javac] reason: actual argument ArrayList<Object> cannot be converted
3980 ;; to List<Position> by method invocation conversion
3981 ;; [javac] where K,V are type-variables:
3982 ;; [javac] K extends Object declared in interface Map
3983 ;; [javac] V extends Object declared in interface Map
3985 ;; I don't know if this is a good fix. I suspect it is not, but it
3987 (add-after 'unpack 'fix-compilation-error
3989 (substitute* "src/org/eclipse/jface/text/AbstractDocument.java"
3990 (("Positions.put\\(category, new ArrayList<>\\(\\)\\);")
3991 "Positions.put(category, new ArrayList<Position>());"))
3994 `(("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
3995 ("java-eclipse-core-commands" ,java-eclipse-core-commands)
3996 ("java-icu4j" ,java-icu4j)))
3997 (home-page "http://www.eclipse.org/platform")
3998 (synopsis "Eclipse text library")
3999 (description "Platform Text is part of the Platform UI project and
4000 provides the basic building blocks for text and text editors within Eclipse
4001 and contributes the Eclipse default text editor.")
4002 (license license:epl1.0)))
4004 (define-public java-eclipse-jdt-core
4006 (name "java-eclipse-jdt-core")
4010 (uri (string-append "https://repo1.maven.org/maven2/"
4011 "org/eclipse/jdt/org.eclipse.jdt.core/"
4012 version "/org.eclipse.jdt.core-"
4013 version "-sources.jar"))
4016 "191xw4lc7mjjkprh4ji5vnpjvr5r4zvbpwkriy4bvsjqrz35vh1j"))))
4017 (build-system ant-build-system)
4019 `(#:tests? #f ; no tests included
4020 #:jar-name "eclipse-jdt-core.jar"))
4022 `(("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
4023 ("java-eclipse-core-filesystem" ,java-eclipse-core-filesystem)
4024 ("java-eclipse-core-jobs" ,java-eclipse-core-jobs)
4025 ("java-eclipse-core-resources" ,java-eclipse-core-resources)
4026 ("java-eclipse-core-runtime" ,java-eclipse-core-runtime)
4027 ("java-eclipse-equinox-app" ,java-eclipse-equinox-app)
4028 ("java-eclipse-equinox-common" ,java-eclipse-equinox-common)
4029 ("java-eclipse-equinox-preferences" ,java-eclipse-equinox-preferences)
4030 ("java-eclipse-equinox-registry" ,java-eclipse-equinox-registry)
4031 ("java-eclipse-osgi" ,java-eclipse-osgi)
4032 ("java-eclipse-text" ,java-eclipse-text)))
4033 (home-page "https://www.eclipse.org/jdt")
4034 (synopsis "Java development tools core libraries")
4035 (description "This package provides the core libraries of the Eclipse Java
4036 development tools.")
4037 (license license:epl1.0)))
4039 (define-public java-javax-mail
4041 (name "java-javax-mail")
4045 (uri (string-append "https://repo1.maven.org/maven2/"
4046 "com/sun/mail/javax.mail/"
4047 version "/javax.mail-"
4048 version "-sources.jar"))
4051 "0sdlfgsc2b5s89xv1261y8i0jijcja019k2x1c8ngfn582w4jly9"))))
4052 (build-system ant-build-system)
4054 `(#:tests? #f ; no tests
4055 #:jar-name "javax-mail.jar"))
4056 (home-page "https://javamail.java.net")
4057 (synopsis "Reference implementation of the JavaMail API")
4059 "This package provides versions of the JavaMail API implementation, IMAP,
4060 SMTP, and POP3 service providers, some examples, and documentation for the
4062 ;; GPLv2 only with "classpath exception".
4063 (license license:gpl2)))
4065 (define-public java-log4j-api
4067 (name "java-log4j-api")
4071 (uri (string-append "mirror://apache/logging/log4j/" version
4072 "/apache-log4j-" version "-src.tar.gz"))
4075 "0j5p9gik0jysh37nlrckqbky12isy95cpwg2gv5fas1rcdqbraxd"))))
4076 (build-system ant-build-system)
4078 `(#:tests? #f ; tests require unpackaged software
4079 #:jar-name "log4j-api.jar"
4081 (list (string-append "-Ddist.dir=" (assoc-ref %outputs "out")
4084 (modify-phases %standard-phases
4085 (add-after 'unpack 'enter-dir
4086 (lambda _ (chdir "log4j-api") #t))
4087 ;; FIXME: The tests require additional software that has not been
4088 ;; packaged yet, such as
4089 ;; * org.apache.maven
4090 ;; * org.apache.felix
4091 (add-after 'enter-dir 'delete-tests
4092 (lambda _ (delete-file-recursively "src/test") #t)))))
4094 `(("java-osgi-core" ,java-osgi-core)
4095 ("java-hamcrest-core" ,java-hamcrest-core)
4096 ("java-junit" ,java-junit)))
4097 (home-page "http://logging.apache.org/log4j/2.x/")
4098 (synopsis "API module of the Log4j logging framework for Java")
4100 "This package provides the API module of the Log4j logging framework for
4102 (license license:asl2.0)))
4104 (define-public java-commons-cli
4106 (name "java-commons-cli")
4110 (uri (string-append "mirror://apache/commons/cli/source/"
4111 "commons-cli-" version "-src.tar.gz"))
4114 "1fkjn552i12vp3xxk21ws4p70fi0lyjm004vzxsdaz7gdpgyxxyl"))))
4115 (build-system ant-build-system)
4118 `(#:jar-name "commons-cli.jar"))
4120 `(("java-junit" ,java-junit)
4121 ("java-hamcrest-core" ,java-hamcrest-core)))
4122 (home-page "http://commons.apache.org/cli/")
4123 (synopsis "Command line arguments and options parsing library")
4124 (description "The Apache Commons CLI library provides an API for parsing
4125 command line options passed to programs. It is also able to print help
4126 messages detailing the options available for a command line tool.
4128 Commons CLI supports different types of options:
4131 @item POSIX like options (ie. tar -zxvf foo.tar.gz)
4132 @item GNU like long options (ie. du --human-readable --max-depth=1)
4133 @item Java like properties (ie. java -Djava.awt.headless=true Foo)
4134 @item Short options with value attached (ie. gcc -O2 foo.c)
4135 @item long options with single hyphen (ie. ant -projecthelp)
4138 This is a part of the Apache Commons Project.")
4139 (license license:asl2.0)))
4141 (define-public java-commons-codec
4143 (name "java-commons-codec")
4147 (uri (string-append "mirror://apache/commons/codec/source/"
4148 "commons-codec-" version "-src.tar.gz"))
4151 "1w9qg30y4s0x8gnmr2fgj4lyplfn788jqxbcz27lf5kbr6n8xr65"))))
4152 (build-system ant-build-system)
4153 (outputs '("out" "doc"))
4155 `(#:test-target "test"
4157 (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
4158 (junit (assoc-ref %build-inputs "java-junit")))
4159 (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
4160 (string-append "-Dhamcrest.jar=" hamcrest
4161 "/share/java/hamcrest-core.jar")
4162 ;; Do not append version to jar.
4163 "-Dfinal.name=commons-codec"))
4165 (modify-phases %standard-phases
4166 (add-after 'build 'build-javadoc ant-build-javadoc)
4167 (replace 'install (install-jars "dist"))
4168 (add-after 'install 'install-doc (install-javadoc "dist/docs/api")))))
4170 `(("java-junit" ,java-junit)
4171 ("java-hamcrest-core" ,java-hamcrest-core)))
4172 (home-page "http://commons.apache.org/codec/")
4173 (synopsis "Common encoders and decoders such as Base64, Hex, Phonetic and URLs")
4174 (description "The codec package contains simple encoder and decoders for
4175 various formats such as Base64 and Hexadecimal. In addition to these widely
4176 used encoders and decoders, the codec package also maintains a collection of
4177 phonetic encoding utilities.
4179 This is a part of the Apache Commons Project.")
4180 (license license:asl2.0)))
4182 (define-public java-commons-daemon
4184 (name "java-commons-daemon")
4188 (uri (string-append "mirror://apache/commons/daemon/source/"
4189 "commons-daemon-" version "-src.tar.gz"))
4192 "0ci46kq8jpz084ccwq0mmkahcgsmh20ziclp2jf5i0djqv95gvhi"))))
4193 (build-system ant-build-system)
4195 `(#:test-target "test"
4197 (modify-phases %standard-phases
4198 (add-after 'build 'build-javadoc ant-build-javadoc)
4199 (replace 'install (install-jars "dist"))
4200 (add-after 'install 'install-doc (install-javadoc "dist/docs/api")))))
4202 `(("java-junit" ,java-junit)))
4203 (home-page "http://commons.apache.org/daemon/")
4204 (synopsis "Library to launch Java applications as daemons")
4205 (description "The Daemon package from Apache Commons can be used to
4206 implement Java applications which can be launched as daemons. For example the
4207 program will be notified about a shutdown so that it can perform cleanup tasks
4208 before its process of execution is destroyed by the operation system.
4210 This package contains the Java library. You will also need the actual binary
4211 for your architecture which is provided by the jsvc package.
4213 This is a part of the Apache Commons Project.")
4214 (license license:asl2.0)))
4216 (define-public java-javaewah
4218 (name "java-javaewah")
4222 (uri (string-append "https://github.com/lemire/javaewah/"
4223 "archive/JavaEWAH-" version ".tar.gz"))
4226 "1n7j1r1h24wlhwv9zdcj6yqjrhma2ixwyzm15l5vrv6yqjs6753b"))))
4227 (build-system ant-build-system)
4228 (arguments `(#:jar-name "javaewah.jar"))
4230 `(("java-junit" ,java-junit)
4231 ("java-hamcrest-core" ,java-hamcrest-core)))
4232 (home-page "https://github.com/lemire/javaewah")
4233 (synopsis "Compressed alternative to the Java @code{BitSet} class")
4234 (description "This is a word-aligned compressed variant of the Java
4235 @code{Bitset} class. It provides both a 64-bit and a 32-bit RLE-like
4236 compression scheme. It can be used to implement bitmap indexes.
4238 The goal of word-aligned compression is not to achieve the best compression,
4239 but rather to improve query processing time. Hence, JavaEWAH tries to save CPU
4240 cycles, maybe at the expense of storage. However, the EWAH scheme is always
4241 more efficient storage-wise than an uncompressed bitmap (as implemented in the
4242 @code{BitSet} class by Sun).")
4243 ;; GPL2.0 derivates are explicitly allowed.
4244 (license license:asl2.0)))
4246 (define-public java-slf4j-api
4248 (name "java-slf4j-api")
4252 (uri (string-append "https://www.slf4j.org/dist/slf4j-"
4256 "13j51sgzmhhdrfa74gkal5zpip7r1440dh7zsi2c8bpb2zs1v8kb"))
4257 (modules '((guix build utils)))
4258 ;; Delete bundled jars.
4261 (for-each delete-file (find-files "." "\\.jar$"))
4263 (build-system ant-build-system)
4265 `(#:jar-name "slf4j-api.jar"
4266 #:source-dir "slf4j-api/src/main"
4267 #:test-dir "slf4j-api/src/test"
4269 (modify-phases %standard-phases
4270 (add-after 'build 'regenerate-jar
4272 ;; pom.xml ignores these files in the jar creation process. If we don't,
4273 ;; we get the error "This code should have never made it into slf4j-api.jar"
4274 (delete-file-recursively "build/classes/org/slf4j/impl")
4275 (zero? (system* "jar" "-cf" "build/jar/slf4j-api.jar" "-C"
4276 "build/classes" "."))))
4277 (add-before 'check 'dont-test-abstract-classes
4279 ;; abstract classes are not meant to be run with junit
4280 (substitute* "build.xml"
4281 (("<include name=\"\\*\\*/\\*Test.java\" />")
4282 (string-append "<include name=\"**/*Test.java\" />"
4283 "<exclude name=\"**/MultithreadedInitializationTest"
4284 ".java\" />"))))))))
4286 `(("java-junit" ,java-junit)
4287 ("java-hamcrest-core" ,java-hamcrest-core)))
4288 (home-page "https://www.slf4j.org/")
4289 (synopsis "Simple logging facade for Java")
4290 (description "The Simple Logging Facade for Java (SLF4J) serves as a
4291 simple facade or abstraction for various logging
4292 frameworks (e.g. @code{java.util.logging}, @code{logback}, @code{log4j})
4293 allowing the end user to plug in the desired logging framework at deployment
4295 (license license:expat)))
4297 (define-public java-slf4j-simple
4299 (name "java-slf4j-simple")
4301 (source (package-source java-slf4j-api))
4302 (build-system ant-build-system)
4304 `(#:jar-name "slf4j-simple.jar"
4305 #:source-dir "slf4j-simple/src/main"
4306 #:test-dir "slf4j-simple/src/test"
4308 (modify-phases %standard-phases
4309 ;; The tests need some test classes from slf4j-api
4310 (add-before 'check 'build-slf4j-api-test-helpers
4312 ;; Add current dir to CLASSPATH ...
4314 (string-append (getcwd) ":" (getenv "CLASSPATH")))
4315 ;; ... and build test helper classes here:
4319 ,@(find-files "slf4j-api/src/test" ".*\\.java")))))))))
4321 `(("java-junit" ,java-junit)
4322 ("java-hamcrest-core" ,java-hamcrest-core)
4323 ("java-slf4j-api" ,java-slf4j-api)))
4324 (home-page "https://www.slf4j.org/")
4325 (synopsis "Simple implementation of simple logging facade for Java")
4326 (description "SLF4J binding for the Simple implementation, which outputs
4327 all events to System.err. Only messages of level INFO and higher are
4329 (license license:expat)))
4331 (define-public antlr2
4337 (uri (string-append "http://www.antlr2.org/download/antlr-"
4341 "1ffvcwdw73id0dk6pj2mlxjvbg0662qacx4ylayqcxgg381fnfl5"))
4342 (modules '((guix build utils)))
4345 (delete-file "antlr.jar")
4346 (substitute* "lib/cpp/antlr/CharScanner.hpp"
4350 "#define EOF (-1)\n"
4351 "#include <strings.h>")))
4352 (substitute* "configure"
4355 (build-system gnu-build-system)
4357 `(#:tests? #f ; no test target
4358 #:imported-modules ((guix build ant-build-system)
4359 (guix build syscalls)
4360 ,@%gnu-build-system-modules)
4361 #:modules (((guix build ant-build-system) #:prefix ant:)
4362 (guix build gnu-build-system)
4365 (modify-phases %standard-phases
4366 (add-after 'install 'strip-jar-timestamps
4367 (assoc-ref ant:%standard-phases 'strip-jar-timestamps))
4368 (add-after 'configure 'fix-bin-ls
4370 (substitute* (find-files "." "Makefile")
4376 ("java" ,icedtea "jdk")))
4378 `(("java" ,icedtea)))
4379 (home-page "http://www.antlr2.org")
4380 (synopsis "Framework for constructing recognizers, compilers, and translators")
4381 (description "ANTLR, ANother Tool for Language Recognition, (formerly PCCTS)
4382 is a language tool that provides a framework for constructing recognizers,
4383 compilers, and translators from grammatical descriptions containing Java, C#,
4384 C++, or Python actions. ANTLR provides excellent support for tree construction,
4385 tree walking, and translation.")
4386 (license license:public-domain)))
4388 (define-public java-stringtemplate-3
4390 (name "java-stringtemplate")
4394 (uri (string-append "https://github.com/antlr/website-st4/raw/"
4395 "gh-pages/download/stringtemplate-"
4399 "086yj68np1vqhkj7483diz3km6s6y4gmwqswa7524a0ca6vxn2is"))))
4400 (build-system ant-build-system)
4402 `(#:jar-name (string-append ,name "-" ,version ".jar")
4404 #:modules ((guix build ant-build-system)
4408 (modify-phases %standard-phases
4409 (add-before 'check 'fix-tests
4411 (substitute* "build.xml"
4412 (("\\$\\{test.home\\}/java")
4413 "${test.home}/org"))
4415 (add-before 'build 'generate-grammar
4417 (with-directory-excursion "src/org/antlr/stringtemplate/language/"
4418 (every (lambda (file)
4419 (format #t "~a\n" file)
4420 (zero? (system* "antlr" file)))
4421 '("template.g" "angle.bracket.template.g" "action.g"
4422 "eval.g" "group.g" "interface.g"))))))))
4425 ("java-junit" ,java-junit)))
4426 (home-page "http://www.stringtemplate.org")
4427 (synopsis "Template engine to generate formatted text output")
4428 (description "StringTemplate is a java template engine (with ports for C#,
4429 Objective-C, JavaScript, Scala) for generating source code, web pages, emails,
4430 or any other formatted text output. StringTemplate is particularly good at
4431 code generators, multiple site skins, and internationalization / localization.
4432 StringTemplate also powers ANTLR.")
4433 (license license:bsd-3)))
4435 ;; antlr3 is partially written using antlr3 grammar files. It also depends on
4436 ;; ST4 (stringtemplate4), which is also partially written using antlr3 grammar
4437 ;; files and uses antlr3 at runtime. The latest version requires a recent version
4438 ;; of antlr3 at runtime.
4439 ;; Fortunately, ST4 4.0.6 can be built with an older antlr3, and we use antlr3.3.
4440 ;; This version of ST4 is sufficient for the latest antlr3.
4441 ;; We use ST4 4.0.6 to build a boostrap antlr3 (latest version), and build
4442 ;; the latest ST4 with it. Then we build our final antlr3 that will be linked
4443 ;; against the latest ST4.
4444 ;; antlr3.3 still depends on antlr3 to generate some files, so we use an
4445 ;; even older version, antlr3.1, to generate them. Fortunately antlr3.1 uses
4446 ;; only grammar files with the antlr2 syntax.
4447 ;; So we build antlr3.1 -> antlr3.3 -> ST4.0.6 -> antlr3-bootstrap -> ST4 -> antlr3.
4449 (define-public java-stringtemplate
4450 (package (inherit java-stringtemplate-3)
4451 (name "java-stringtemplate")
4455 (uri (string-append "https://github.com/antlr/stringtemplate4/archive/"
4457 (file-name (string-append name "-" version ".tar.gz"))
4460 "1pri8hqa95rfdkjy55icl5q1m09zwp5k67ib14abas39s4v3w087"))))
4461 (build-system ant-build-system)
4463 `(#:jar-name (string-append ,name "-" ,version ".jar")
4464 #:tests? #f ; FIXME: tests fail for unknown reasons
4466 #:modules ((guix build ant-build-system)
4470 (modify-phases %standard-phases
4471 (add-before 'check 'fix-test-target
4473 (substitute* "build.xml"
4474 (("\\$\\{test.home\\}/java") "${test.home}/")
4475 (("\\*Test.java") "Test*.java"))
4477 (add-before 'build 'generate-grammar
4479 (with-directory-excursion "src/org/stringtemplate/v4/compiler/"
4480 (every (lambda (file)
4481 (format #t "~a\n" file)
4482 (zero? (system* "antlr3" file)))
4483 '("STParser.g" "Group.g" "CodeGenerator.g"))))))))
4485 `(("antlr3" ,antlr3-bootstrap)
4487 ("java-stringtemplate" ,java-stringtemplate-3)
4488 ("java-junit" ,java-junit)))))
4490 (define java-stringtemplate-4.0.6
4491 (package (inherit java-stringtemplate)
4492 (name "java-stringtemplate")
4496 (uri (string-append "https://github.com/antlr/stringtemplate4/archive/ST-"
4498 (file-name (string-append name "-" version ".tar.gz"))
4501 "0hjmh1ahdsh3w825i67mli9l4nncc4l6hdbf9ma91jvlj590sljp"))))
4503 `(("antlr3" ,antlr3-3.3)
4505 ("java-stringtemplate" ,java-stringtemplate-3)))))
4507 (define-public antlr3
4513 (uri (string-append "https://github.com/antlr/antlr3/archive/"
4515 (file-name (string-append name "-" version ".tar.gz"))
4518 "0218v683081lg54z9hvjxinhxd4dqp870jx6n39gslm0bkyi4vd6"))))
4519 (build-system ant-build-system)
4521 `(#:jar-name (string-append ,name "-" ,version ".jar")
4522 #:source-dir "tool/src/main/java:runtime/Java/src/main/java:tool/src/main/antlr3"
4525 (modify-phases %standard-phases
4526 (add-after 'install 'bin-install
4527 (lambda* (#:key inputs outputs #:allow-other-keys)
4528 (let ((jar (string-append (assoc-ref outputs "out") "/share/java"))
4529 (bin (string-append (assoc-ref outputs "out") "/bin")))
4531 (with-output-to-file (string-append bin "/antlr3")
4534 (string-append "#!" (which "sh") "\n"
4535 "java -cp " jar "/" ,name "-" ,version ".jar:"
4537 (find-files (assoc-ref inputs "stringtemplate")
4541 (find-files (assoc-ref inputs "stringtemplate4")
4545 (find-files (string-append
4546 (assoc-ref inputs "antlr")
4549 " org.antlr.Tool $*"))))
4550 (chmod (string-append bin "/antlr3") #o755))))
4551 (add-before 'build 'generate-grammar
4553 (chdir "tool/src/main/antlr3/org/antlr/grammar/v3/")
4554 (for-each (lambda (file)
4557 (system* "antlr3" file))
4558 '("ANTLR.g" "ANTLRTreePrinter.g" "ActionAnalysis.g"
4559 "AssignTokenTypesWalker.g"
4560 "ActionTranslator.g" "TreeToNFAConverter.g"
4561 "ANTLRv3.g" "ANTLRv3Tree.g" "LeftRecursiveRuleWalker.g"
4562 "CodeGenTreeWalker.g" "DefineGrammarItemsWalker.g"))
4563 (substitute* "ANTLRParser.java"
4564 (("public Object getTree") "public GrammarAST getTree"))
4565 (substitute* "ANTLRv3Parser.java"
4566 (("public Object getTree") "public CommonTree getTree"))
4567 (chdir "../../../../../java")
4568 (system* "antlr" "-o" "org/antlr/tool"
4569 "org/antlr/tool/serialize.g")
4570 (substitute* "org/antlr/tool/LeftRecursiveRuleAnalyzer.java"
4571 (("import org.antlr.grammar.v3.\\*;") "import org.antlr.grammar.v3.*;
4572 import org.antlr.grammar.v3.ANTLRTreePrinter;"))
4573 (substitute* "org/antlr/tool/ErrorManager.java"
4574 (("case NO_SUCH_ATTRIBUTE_PASS_THROUGH:") ""))
4575 (chdir "../../../..")))
4576 (add-before 'build 'fix-build-xml
4578 (substitute* "build.xml"
4579 (("<exec") "<copy todir=\"${classes.dir}\">
4580 <fileset dir=\"tool/src/main/resources\">
4581 <include name=\"**/*.stg\"/>
4582 <include name=\"**/*.st\"/>
4583 <include name=\"**/*.sti\"/>
4584 <include name=\"**/STLexer.tokens\"/>
4586 </copy><exec")))))))
4589 ("antlr3" ,antlr3-bootstrap)))
4591 `(("junit" ,java-junit)
4592 ("stringtemplate" ,java-stringtemplate-3)
4593 ("stringtemplate4" ,java-stringtemplate)))
4595 `(("stringtemplate" ,java-stringtemplate-3)
4597 ("stringtemplate4" ,java-stringtemplate-4.0.6)))
4598 (home-page "http://www.antlr3.org")
4599 (synopsis "Framework for constructing recognizers, compilers, and translators")
4600 (description "ANTLR, ANother Tool for Language Recognition, (formerly PCCTS)
4601 is a language tool that provides a framework for constructing recognizers,
4602 compilers, and translators from grammatical descriptions containing Java, C#,
4603 C++, or Python actions. ANTLR provides excellent support for tree construction,
4604 tree walking, and translation.")
4605 (license license:bsd-3)))
4607 (define antlr3-bootstrap
4610 (name "antlr3-bootstrap")
4613 ("antlr3" ,antlr3-3.3)))
4615 `(("junit" ,java-junit)))))
4624 (uri (string-append "https://github.com/antlr/website-antlr3/raw/"
4625 "gh-pages/download/antlr-"
4629 "0qgg5vgsm4l1d6dj9pfbaa25dpv2ry2gny8ajy4vvgvfklw97b3m"))))
4631 `(#:jar-name (string-append ,name "-" ,version ".jar")
4632 #:source-dir (string-append "tool/src/main/java:runtime/Java/src/main/java:"
4633 "tool/src/main/antlr2:tool/src/main/antlr3")
4636 (modify-phases %standard-phases
4637 (add-after 'install 'bin-install
4638 (lambda* (#:key inputs outputs #:allow-other-keys)
4639 (let ((jar (string-append (assoc-ref outputs "out") "/share/java"))
4640 (bin (string-append (assoc-ref outputs "out") "/bin")))
4642 (with-output-to-file (string-append bin "/antlr3")
4645 (string-append "#!" (which "sh") "\n"
4646 "java -cp " jar "/antlr3-3.3.jar:"
4648 (find-files (assoc-ref inputs "java-stringtemplate")
4652 (find-files (string-append
4653 (assoc-ref inputs "antlr")
4656 " org.antlr.Tool $*"))))
4657 (chmod (string-append bin "/antlr3") #o755))))
4658 (add-before 'build 'generate-grammar
4660 (let ((dir "tool/src/main/antlr2/org/antlr/grammar/v2/"))
4661 (for-each (lambda (file)
4664 (system* "antlr" "-o" dir (string-append dir file)))
4665 '("antlr.g" "antlr.print.g" "assign.types.g"
4666 "buildnfa.g" "codegen.g" "define.g")))
4667 (chdir "tool/src/main/antlr3/org/antlr/grammar/v3/")
4668 (for-each (lambda (file)
4671 (system* "antlr3" file))
4672 '("ActionAnalysis.g" "ActionTranslator.g" "ANTLRv3.g"
4674 (chdir "../../../../../../../..")
4675 (substitute* "tool/src/main/java/org/antlr/tool/Grammar.java"
4676 (("import org.antlr.grammar.v2.\\*;")
4677 "import org.antlr.grammar.v2.*;\n
4678 import org.antlr.grammar.v2.TreeToNFAConverter;\n
4679 import org.antlr.grammar.v2.DefineGrammarItemsWalker;\n
4680 import org.antlr.grammar.v2.ANTLRTreePrinter;"))))
4681 (add-before 'build 'fix-build-xml
4683 (substitute* "build.xml"
4684 (("<exec") "<copy todir=\"${classes.dir}\">
4685 <fileset dir=\"tool/src/main/resources\">
4686 <include name=\"**/*.stg\"/>
4687 <include name=\"**/*.st\"/>
4688 <include name=\"**/*.sti\"/>
4689 <include name=\"**/STLexer.tokens\"/>
4691 </copy><exec")))))))
4694 ("antlr3" ,antlr3-3.1)))
4696 `(("junit" ,java-junit)))
4698 `(("java-stringtemplate" ,java-stringtemplate-3)
4700 ("antlr3" ,antlr3-3.1)))))
4709 (uri (string-append "https://github.com/antlr/website-antlr3/raw/"
4710 "gh-pages/download/antlr-"
4714 "0sfimc9cpbgrihz4giyygc8afgpma2c93yqpwb951giriri6x66z"))))
4716 `(#:jar-name (string-append ,name "-" ,version ".jar")
4717 #:source-dir "src:runtime/Java/src"
4720 (modify-phases %standard-phases
4721 (add-after 'install 'bin-install
4722 (lambda* (#:key inputs outputs #:allow-other-keys)
4723 (let ((jar (string-append (assoc-ref outputs "out") "/share/java"))
4724 (bin (string-append (assoc-ref outputs "out") "/bin")))
4726 (with-output-to-file (string-append bin "/antlr3")
4729 (string-append "#!" (which "sh") "\n"
4730 "java -cp " jar "/antlr3-3.1-3.1.jar:"
4732 (find-files (assoc-ref inputs "stringtemplate")
4736 (find-files (string-append
4737 (assoc-ref inputs "antlr")
4740 " org.antlr.Tool $*"))))
4741 (chmod (string-append bin "/antlr3") #o755))))
4742 (add-before 'build 'generate-grammar
4744 (let ((dir "src/org/antlr/tool/"))
4745 (for-each (lambda (file)
4748 (system* "antlr" "-o" dir (string-append dir file)))
4749 '("antlr.g" "antlr.print.g" "assign.types.g"
4750 "buildnfa.g" "define.g")))
4751 (format #t "codegen.g\n")
4752 (system* "antlr" "-o" "src/org/antlr/codegen"
4753 "src/org/antlr/codegen/codegen.g")))
4754 (add-before 'build 'fix-build-xml
4756 (substitute* "build.xml"
4757 (("<exec") "<copy todir=\"${classes.dir}\">
4758 <fileset dir=\"src\">
4759 <include name=\"**/*.stg\"/>
4760 <include name=\"**/*.st\"/>
4761 <include name=\"**/*.sti\"/>
4762 <include name=\"**/STLexer.tokens\"/>
4764 </copy><exec")))))))
4766 `(("antlr" ,antlr2)))
4768 `(("junit" ,java-junit)))
4770 `(("stringtemplate" ,java-stringtemplate-3)))))
4772 (define-public java-asm
4778 (uri (string-append "http://download.forge.ow2.org/asm/"
4779 "asm-" version ".tar.gz"))
4782 "0kxvmv5275rnjl7jv0442k3wjnq03ngkb7sghs78avf45pzm4qgr"))))
4783 (build-system ant-build-system)
4785 `(#:build-target "compile"
4786 #:test-target "test"
4787 ;; The tests require an old version of Janino, which no longer compiles
4790 ;; We don't need these extra ant tasks, but the build system asks us to
4791 ;; provide a path anyway.
4792 #:make-flags (list (string-append "-Dobjectweb.ant.tasks.path=foo"))
4794 (modify-phases %standard-phases
4795 (add-before 'install 'build-jars
4796 (lambda* (#:key make-flags #:allow-other-keys)
4797 ;; We cannot use the "jar" target because it depends on a couple
4798 ;; of unpackaged, complicated tools.
4800 (zero? (system* "jar"
4801 "-cf" (string-append "dist/asm-" ,version ".jar")
4802 "-C" "output/build/tmp" "."))))
4804 (install-jars "dist")))))
4806 `(("java-junit" ,java-junit)))
4807 (home-page "http://asm.ow2.org/")
4808 (synopsis "Very small and fast Java bytecode manipulation framework")
4809 (description "ASM is an all purpose Java bytecode manipulation and
4810 analysis framework. It can be used to modify existing classes or dynamically
4811 generate classes, directly in binary form. The provided common
4812 transformations and analysis algorithms allow to easily assemble custom
4813 complex transformations and code analysis tools.")
4814 (license license:bsd-3)))
4816 (define-public java-commons-cli-1.2
4817 ;; This is a bootstrap dependency for Maven2.
4819 (inherit java-commons-cli)
4823 (uri (string-append "mirror://apache/commons/cli/source/"
4824 "commons-cli-" version "-src.tar.gz"))
4827 "0rvfgzgv2pc1m091dfj3ih9ddsjjppr1f1wf0qmc3bk6b1kwv2dm"))))
4829 `(#:jar-name "commons-cli.jar"
4831 (modify-phases %standard-phases
4832 (add-before 'check 'fix-build-xml
4833 (lambda* (#:key inputs #:allow-other-keys)
4834 (substitute* "build.xml"
4835 (("dir=\"\\$\\{test.home\\}/java\"")
4836 "dir=\"${test.home}\""))
4839 `(("java-junit" ,java-junit)))))
4841 (define-public java-microemulator-cldc
4843 (name "java-microemulator-cldc")
4847 (uri (string-append "https://github.com/barteo/microemu/archive/"
4849 (string-map (lambda (c) (if (char=? c #\.) #\_ c))
4852 (file-name (string-append name "-" version ".tar.gz"))
4855 "1x1apmz38gkppxnwnygwmi12j54v4p258v8ddzn6dldkk7vak1ll"))))
4856 (build-system ant-build-system)
4858 `(#:jar-name "microemulator-cldc.jar"
4859 #:source-dir "microemu-cldc/src/main/java"
4860 #:tests? #f)); Requires even older software
4861 (home-page "https://github.com/barteo/microemu")
4862 (synopsis "J2ME CLDC emulator")
4863 (description "Microemulator is a Java 2 Micro Edition (J2ME) CLDC/MIDP
4864 Emulator. It allows to demonstrate MIDlet based applications in web browser
4865 applet and can be run as a standalone java application.")
4866 (license (list license:asl2.0
4868 license:lgpl2.1+))))
4870 (define-public java-datanucleus-javax-persistence
4872 (name "java-datanucleus-javax-persistence")
4876 (uri (string-append "https://github.com/datanucleus/"
4877 "javax.persistence/archive/javax.persistence-"
4878 version "-release.tar.gz"))
4881 "11jx0fjwgc2hhbqqgdd6m1pf2fplf9vslppygax0y1z5csnqjhpx"))))
4882 (build-system ant-build-system)
4884 `(#:jar-name "java-datanucleus-javax-persistence.jar"
4886 #:source-dir "src/main/java"
4887 #:tests? #f)); no tests
4888 (home-page "https://github.com/datanucleus/javax.persistence")
4889 (synopsis "JPA API")
4890 (description "This package contains a clean definition of JPA API intended
4891 for use with DataNucleus JPA since the JCP haven't provided an official JPA API
4892 jar. See @url{http://java.net/projects/jpa-spec/downloads} for the specification
4893 used to generate this API.")
4894 (license (list license:edl1.0 license:epl1.0))))
4896 (define-public java-osgi-cmpn
4898 (name "java-osgi-cmpn")
4902 (uri (string-append "http://central.maven.org/maven2/"
4903 "org/osgi/osgi.cmpn/" version "/osgi.cmpn-"
4904 version "-sources.jar"))
4907 "1lmb6xyrmkqdhv1kayf0514rlwq6ypvs4m44ibrck3snp8241wys"))))
4908 (build-system ant-build-system)
4910 `(#:jar-name "osgi-cmpn.jar"
4911 #:tests? #f)); no tests
4913 `(("annotation" ,java-osgi-annotation)
4914 ("core" ,java-osgi-core)
4915 ("java-datanucleus-javax-persistence" ,java-datanucleus-javax-persistence)
4916 ("microemulator" ,java-microemulator-cldc)
4917 ("servlet" ,java-classpathx-servletapi)))
4918 (home-page "http://www.osgi.org")
4919 (synopsis "Compendium specification module of OSGi framework")
4921 "OSGi, for Open Services Gateway initiative framework, is a module system
4922 and service platform for the Java programming language. This package contains
4923 the compendium specification module, providing interfaces and classes for use
4924 in compiling bundles.")
4925 (license license:asl2.0)))
4927 (define-public java-osgi-service-component-annotations
4929 (name "java-osgi-service-component-annotations")
4933 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
4934 "org.osgi.service.component.annotations/"
4935 version "/org.osgi.service.component.annotations-"
4936 version "-sources.jar"))
4939 "15rq9cmp4fpn74q44m4j35qsqmjf5lx3hcrk6pzvbhc08igic2f0"))))
4940 (build-system ant-build-system)
4942 `(#:jar-name "osgi-service-component-annotations.jar"
4943 #:tests? #f)); no tests
4945 `(("annotation" ,java-osgi-annotation)))
4946 (home-page "http://www.osgi.org")
4947 (synopsis "Support annotations for osgi-service-component")
4949 "OSGi, for Open Services Gateway initiative framework, is a module system
4950 and service platform for the Java programming language. This package contains
4951 the support annotations for osgi-service-component.")
4952 (license license:asl2.0)))
4954 (define-public java-osgi-dto
4956 (name "java-osgi-dto")
4960 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
4961 "org.osgi.dto/" version "/org.osgi.dto-"
4962 version "-sources.jar"))
4965 "0f4bqjzadn0hwk6sd3h5gvbyfp3yci1s6r0v770cc15p0pg627yr"))))
4966 (build-system ant-build-system)
4968 `(#:jar-name "osgi-dto.jar"
4969 #:tests? #f)); no tests
4971 `(("annotation" ,java-osgi-annotation)))
4972 (home-page "http://www.osgi.org")
4973 (synopsis "Data Transfer Objects")
4975 "OSGi, for Open Services Gateway initiative framework, is a module system
4976 and service platform for the Java programming language. This package contains
4977 the Data Transfer Objects. It is easily serializable having only public fields
4978 of primitive types and their wrapper classes, Strings, and DTOs. List, Set,
4979 Map and array aggregates may also be used. The aggregates must only hold
4980 objects of the listed types or aggregates.")
4981 (license license:asl2.0)))
4983 (define-public java-osgi-resource
4985 (name "java-osgi-resource")
4989 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
4990 "org.osgi.resource/"
4991 version "/org.osgi.resource-"
4992 version "-sources.jar"))
4995 "0hi0fsc5v99q22bd7lrkvpz1y0ds4w9arjldpwsrcpqvz2js7q2d"))))
4996 (build-system ant-build-system)
4998 `(#:jar-name "osgi-resource.jar"
4999 #:tests? #f)); no tests
5001 `(("annotation" ,java-osgi-annotation)
5002 ("dto" ,java-osgi-dto)))
5003 (home-page "http://www.osgi.org")
5004 (synopsis "OSGI Resource")
5006 "OSGi, for Open Services Gateway initiative framework, is a module system
5007 and service platform for the Java programming language. This package contains
5008 the definition of common types in osgi packages.")
5009 (license license:asl2.0)))
5011 (define-public java-osgi-namespace-contract
5013 (name "java-osgi-namespace-contract")
5017 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5018 "org.osgi.namespace.contract/"
5019 version "/org.osgi.namespace.contract-"
5020 version "-sources.jar"))
5023 "1iz4f2i0fvqrlq90ki9nfzcfpvy2av434ri25bglywqssx8mmp36"))))
5024 (build-system ant-build-system)
5026 `(("resource" ,java-osgi-resource)
5027 ("annotation" ,java-osgi-annotation)))
5029 `(#:jar-name "osgi-namespace-contract.jar"
5030 #:tests? #f)); no tests
5031 (home-page "http://www.osgi.org")
5032 (synopsis "Contract Capability and Requirement Namespace")
5034 "OSGi, for Open Services Gateway initiative framework, is a module system
5035 and service platform for the Java programming language. This package contains
5036 the names for the attributes and directives for a namespace with contracts.")
5037 (license license:asl2.0)))
5039 (define-public java-osgi-namespace-extender
5041 (name "java-osgi-namespace-extender")
5045 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5046 "org.osgi.namespace.extender/"
5047 version "/org.osgi.namespace.extender-"
5048 version "-sources.jar"))
5051 "0jgqiak2i05qv6j3gd33xlaifzzc0ylxxk376v2x0apfg3vvixmz"))))
5052 (build-system ant-build-system)
5054 `(("resource" ,java-osgi-resource)
5055 ("annotation" ,java-osgi-annotation)))
5057 `(#:jar-name "osgi-namespace-extendent.jar"
5058 #:tests? #f)); no tests
5059 (home-page "http://www.osgi.org")
5060 (synopsis "Extender Capability and Requirement Namespace")
5062 "OSGi, for Open Services Gateway initiative framework, is a module system
5063 and service platform for the Java programming language. This package contains
5064 the names for the attributes and directives for an extender namespace.")
5065 (license license:asl2.0)))
5067 (define-public java-osgi-namespace-service
5069 (name "java-osgi-namespace-service")
5073 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5074 "org.osgi.namespace.service/"
5075 version "/org.osgi.namespace.service-"
5076 version "-sources.jar"))
5079 "0qmw8n2449nkmm56d1znz9zhazb6ya3vsimd5bf5jg23zzhgl8c8"))))
5080 (build-system ant-build-system)
5082 `(("resource" ,java-osgi-resource)
5083 ("annotation" ,java-osgi-annotation)))
5085 `(#:jar-name "osgi-namespace-service.jar"
5086 #:tests? #f)); no tests
5087 (home-page "http://www.osgi.org")
5088 (synopsis "Service Capability and Requirement Namespace")
5090 "OSGi, for Open Services Gateway initiative framework, is a module system
5091 and service platform for the Java programming language. This package contains
5092 the names for the attributes and directives for a service namespace.")
5093 (license license:asl2.0)))
5095 (define-public java-osgi-util-function
5097 (name "java-osgi-util-function")
5101 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5102 "org.osgi.util.function/"
5103 version "/org.osgi.util.function-"
5104 version "-sources.jar"))
5107 "04l7j3hwmmj28w23m7paca0afzncs42j2mdr3liqq8kvp548sc6x"))))
5108 (build-system ant-build-system)
5110 `(#:jar-name "osgi-util-function.jar"
5111 #:tests? #f)); no tests
5113 `(("annotation" ,java-osgi-annotation)))
5114 (home-page "http://www.osgi.org")
5115 (synopsis "OSGI Util Function")
5117 "OSGi, for Open Services Gateway initiative framework, is a module system
5118 and service platform for the Java programming language. This package contains
5119 an interface for a function that accepts a single argument and produces a result.")
5120 (license license:asl2.0)))
5122 (define-public java-osgi-util-promise
5124 (name "java-osgi-util-promise")
5128 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5129 "org.osgi.util.promise/"
5130 version "/org.osgi.util.promise-"
5131 version "-sources.jar"))
5134 "0y34dwiflg1c4ahvkswpf9z02xph2sr9fm04ia5493x3lshpw22c"))))
5135 (build-system ant-build-system)
5137 `(#:jar-name "osgi-util-promise.jar"
5138 #:tests? #f)); no tests
5140 `(("annotation" ,java-osgi-annotation)
5141 ("function" ,java-osgi-util-function)))
5142 (home-page "http://www.osgi.org")
5143 (synopsis "Promise of a value")
5145 "OSGi, for Open Services Gateway initiative framework, is a module system
5146 and service platform for the Java programming language. This package contains
5147 an interface and utilitary classes for promises. A Promise represents a future
5148 value. It handles the interactions for asynchronous processing.")
5149 (license license:asl2.0)))
5151 (define-public java-osgi-service-metatype-annotations
5153 (name "java-osgi-service-metatype-annotations")
5157 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5158 "org.osgi.service.metatype.annotations/"
5159 version "/org.osgi.service.metatype.annotations-"
5160 version "-sources.jar"))
5163 "12rwm3349wk80vm88rcdgs4435m4jxkpkj5mrx326skkz2c6hyw6"))))
5164 (build-system ant-build-system)
5166 `(#:jar-name "osgi-service-metatype-annotations.jar"
5167 #:tests? #f)); no tests
5169 `(("annotation" ,java-osgi-annotation)))
5170 (home-page "http://www.osgi.org")
5171 (synopsis "Support annotations for metatype")
5173 "OSGi, for Open Services Gateway initiative framework, is a module system
5174 and service platform for the Java programming language. This package contains
5175 the support annotations for metatype.")
5176 (license license:asl2.0)))
5178 (define-public java-osgi-service-repository
5180 (name "java-osgi-service-repository")
5184 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5185 "org.osgi.service.repository/"
5186 version "/org.osgi.service.repository-"
5187 version "-sources.jar"))
5190 "1k41mhg7b58pd8nsghr2qwcjrxdnf1p9spsw9v11k4257g6rl06n"))))
5191 (build-system ant-build-system)
5193 `(#:jar-name "osgi-service-repository.jar"
5194 #:tests? #f)); no tests
5196 `(("annotation" ,java-osgi-annotation)
5197 ("promise" ,java-osgi-util-promise)
5198 ("resource" ,java-osgi-resource)))
5199 (home-page "http://www.osgi.org")
5200 (synopsis "OSGI service repository")
5202 "OSGi, for Open Services Gateway initiative framework, is a module system
5203 and service platform for the Java programming language. This package contains
5204 a repository service that contains resources.")
5205 (license license:asl2.0)))
5207 (define-public java-osgi-framework
5209 (name "java-osgi-framework")
5213 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5214 "org.osgi.framework/" version "/org.osgi.framework-"
5215 version "-sources.jar"))
5218 "1lwp2zfad3rybcc6q9bwz8xsgkc92ypzy5p6x54387f1qj65m73s"))))
5219 (build-system ant-build-system)
5221 `(#:jar-name "osgi-framework.jar"
5222 #:tests? #f)); no tests
5224 `(("annotation" ,java-osgi-annotation)
5225 ("resource" ,java-osgi-resource)
5226 ("dto" ,java-osgi-dto)))
5227 (home-page "http://www.osgi.org")
5228 (synopsis "OSGi framework")
5230 "OSGi, for Open Services Gateway initiative framework, is a module system
5231 and service platform for the Java programming language.")
5232 (license license:asl2.0)))
5234 (define-public java-osgi-service-log
5236 (name "java-osgi-service-log")
5240 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5241 "org.osgi.service.log/"
5242 version "/org.osgi.service.log-"
5243 version "-sources.jar"))
5246 "1029j30dzcwializzca0j3fkhwwz08kmmsha5agw1iccscimj6r0"))))
5247 (build-system ant-build-system)
5249 `(#:jar-name "osgi-service-log.jar"
5250 #:tests? #f)); no tests
5252 `(("java-osgi-framework" ,java-osgi-framework)))
5253 (home-page "http://www.osgi.org")
5254 (synopsis "Provides methods for bundles to write messages to the log")
5256 "OSGi, for Open Services Gateway initiative framework, is a module system
5257 and service platform for the Java programming language. This package contains
5259 (license license:asl2.0)))
5261 (define-public java-osgi-service-jdbc
5263 (name "java-osgi-service-jdbc")
5267 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5268 "org.osgi.service.jdbc/"
5269 version "/org.osgi.service.jdbc-"
5270 version "-sources.jar"))
5273 "11iln5v7bk469cgb9ddkrz9sa95b3733gqgaqw9xf5g6wq652yjz"))))
5274 (build-system ant-build-system)
5276 `(#:jar-name "osgi-service-jdbc.jar"
5277 #:tests? #f)); no tests
5278 (home-page "http://www.osgi.org")
5279 (synopsis "Factory for JDBC connection factories")
5281 "OSGi, for Open Services Gateway initiative framework, is a module system
5282 and service platform for the Java programming language. This package contains
5283 a factory for JDBC connection factories. There are 3 preferred connection
5284 factories for getting JDBC connections:
5287 @item @code{javax.sql.DataSource};
5288 @item @code{javax.sql.ConnectionPoolDataSource};
5289 @item @code{javax.sql.XADataSource}.
5291 (license license:asl2.0)))
5293 (define-public java-osgi-service-resolver
5295 (name "java-osgi-service-resolver")
5299 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5300 "org.osgi.service.resolver/"
5301 version "/org.osgi.service.resolver-"
5302 version "-sources.jar"))
5305 "1dzqn1ryfi2rq4zwsgp44bmj2wlfydjg1qbxw2b0z4xdjjy55vxd"))))
5306 (build-system ant-build-system)
5308 `(#:jar-name "osgi-service-resolver.jar"
5309 #:tests? #f)); no tests
5311 `(("annotation" ,java-osgi-annotation)
5312 ("resource" ,java-osgi-resource)))
5313 (home-page "http://www.osgi.org")
5314 (synopsis "OSGI Resolver service")
5316 "OSGi, for Open Services Gateway initiative framework, is a module system
5317 and service platform for the Java programming language. This package contains
5318 a resolver service that resolves the specified resources in the context supplied
5320 (license license:asl2.0)))
5322 (define-public java-osgi-util-tracker
5324 (name "java-osgi-util-tracker")
5328 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5329 "org.osgi.util.tracker/"
5330 version "/org.osgi.util.tracker-"
5331 version "-sources.jar"))
5334 "0c4fh9vxwzsx59r8dygda0gq2gx3z5vfhc3jsphlqwf5w0h403lz"))))
5335 (build-system ant-build-system)
5337 `(#:jar-name "osgi-util-tracker.jar"
5338 #:tests? #f)); no tests
5340 `(("framework" ,java-osgi-framework)
5341 ("annotation" ,java-osgi-annotation)))
5342 (home-page "http://www.osgi.org")
5343 (synopsis "Bundle tracking")
5345 "OSGi, for Open Services Gateway initiative framework, is a module system
5346 and service platform for the Java programming language. This package contains
5347 bundle tracking utility classes.")
5348 (license license:asl2.0)))
5350 (define-public java-osgi-service-cm
5352 (name "java-osgi-service-cm")
5356 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5357 "org.osgi.service.cm/"
5358 version "/org.osgi.service.cm-"
5359 version "-sources.jar"))
5362 "1z8kap48y3xi0ggj8v6czglfnpnd94mmismgi2wbqhj1nl5fzbp6"))))
5363 (build-system ant-build-system)
5365 `(#:jar-name "osgi-service-cm.jar"
5366 #:tests? #f)); no tests
5368 `(("framework" ,java-osgi-framework)
5369 ("annotation" ,java-osgi-annotation)))
5370 (home-page "http://www.osgi.org")
5371 (synopsis "OSGI Configuration Management")
5373 "OSGi, for Open Services Gateway initiative framework, is a module system
5374 and service platform for the Java programming language. This package contains
5375 utility classes for the configuration of services.")
5376 (license license:asl2.0)))
5378 (define-public java-osgi-service-packageadmin
5380 (name "java-osgi-service-packageadmin")
5384 (uri (string-append "http://central.maven.org/maven2/org/osgi/"
5385 "org.osgi.service.packageadmin/"
5386 version "/org.osgi.service.packageadmin-"
5387 version "-sources.jar"))
5390 "041mpxzi7g36wmcily6y4ccn3jx15akpdy8gmhyb7m98x7qfvn52"))))
5391 (build-system ant-build-system)
5393 `(#:jar-name "osgi-service-packageadmin.jar"
5394 #:tests? #f)); no tests
5396 `(("framework" ,java-osgi-framework)))
5397 (home-page "http://www.osgi.org")
5398 (synopsis "OSGI Package Administration")
5400 "OSGi, for Open Services Gateway initiative framework, is a module system
5401 and service platform for the Java programming language. This package contains
5402 the packageadmin service.")
5403 (license license:asl2.0)))
5405 (define-public java-ops4j-base-lang
5407 (name "java-ops4j-base-lang")
5411 (uri (string-append "https://github.com/ops4j/org.ops4j.base/"
5412 "archive/base-" version ".tar.gz"))
5415 "18hl3lpchgpv8yh5rlk39l2gif5dlfgb8gxjmncf39pr2dprkniw"))))
5416 (build-system ant-build-system)
5418 `(#:jar-name "java-ops4j-base-lang.jar"
5419 #:source-dir "ops4j-base-lang/src/main/java"
5420 #:tests? #f; no tests
5422 (modify-phases %standard-phases
5423 (add-before 'build 'add-test-file
5425 ;; That file is required by a test in ops4j-pax-exam-core-spi
5426 (mkdir-p "build/classes/META-INF/maven/org.ops4j.base/ops4j-base-lang")
5427 (with-output-to-file "build/classes/META-INF/maven/org.ops4j.base/ops4j-base-lang/pom.properties"
5431 "version=" ,version "\n"
5432 "groupId=org.ops4j.base"
5433 "artifactId=ops4j-base-lang\n")))))))))
5434 (home-page "https://ops4j1.jira.com/wiki/spaces/base/overview")
5435 (synopsis "Utility classes and extensions to be used in OPS4J projects")
5436 (description "OPS4J stands for Open Participation Software for Java. This
5437 package contains utilities and extensions related to @code{java.lang}.")
5438 (license license:asl2.0)))
5440 (define-public java-ops4j-base-monitors
5442 (inherit java-ops4j-base-lang)
5443 (name "java-ops4j-base-monitors")
5445 `(#:jar-name "java-ops4j-base-monitors.jar"
5446 #:source-dir "ops4j-base-monitors/src/main/java"
5447 #:tests? #f)); no tests
5449 `(("lang" ,java-ops4j-base-lang)))
5450 (description "OPS4J stands for Open Participation Software for Java. This
5451 package contains utilities and extensions related to monitoring.")))
5453 (define-public java-ops4j-base-io
5455 (inherit java-ops4j-base-lang)
5456 (name "java-ops4j-base-io")
5458 `(#:jar-name "java-ops4j-base-io.jar"
5459 #:source-dir "ops4j-base-io/src/main/java"
5460 #:test-dir "ops4j-base-io/src/test"
5462 (list "**/ListerTest.java")))
5464 `(("lang" ,java-ops4j-base-monitors)
5465 ("lang" ,java-ops4j-base-lang)))
5467 `(("junit" ,java-junit)
5468 ("hamcrest" ,java-hamcrest-core)))
5469 (description "OPS4J stands for Open Participation Software for Java. This
5470 package contains utilities and extensions related to handling streams and files.")))
5472 (define-public java-ops4j-base-util
5474 (inherit java-ops4j-base-lang)
5475 (name "java-ops4j-base-util")
5477 `(#:jar-name "java-ops4j-base-util.jar"
5478 #:source-dir "ops4j-base-util/src/main/java"
5479 #:test-dir "ops4j-base-util/src/test"))
5481 `(("lang" ,java-ops4j-base-lang)))
5483 `(("junit" ,java-junit)))
5484 (description "OPS4J stands for Open Participation Software for Java. This
5485 package contains utilities and extensions related to environment, i18n and
5488 (define-public java-ops4j-base-util-property
5490 (inherit java-ops4j-base-lang)
5491 (name "java-ops4j-base-util-property")
5493 `(#:jar-name "java-ops4j-base-util-property.jar"
5494 #:source-dir "ops4j-base-util-property/src/main/java"
5495 #:tests? #f)); no tests
5497 `(("lang" ,java-ops4j-base-lang)
5498 ("util" ,java-ops4j-base-util)))
5499 (description "OPS4J stands for Open Participation Software for Java. This
5500 package contains utilities and extensions related to resolving properties from
5501 different sources.")))
5503 (define-public java-ops4j-base-store
5505 (inherit java-ops4j-base-lang)
5506 (name "java-ops4j-base-store")
5508 `(#:jar-name "java-ops4j-base-store.jar"
5509 #:source-dir "ops4j-base-store/src/main/java"
5510 #:tests? #f)); no tests
5512 `(("lang" ,java-ops4j-base-lang)
5513 ("slf4j" ,java-slf4j-api)
5514 ("io" ,java-ops4j-base-io)))
5515 (description "OPS4J stands for Open Participation Software for Java. This
5516 package contains utilities for storing and retrieving data from an
5517 @code{InputStream}.")))
5519 (define-public java-ops4j-base-spi
5521 (inherit java-ops4j-base-lang)
5522 (name "java-ops4j-base-spi")
5524 `(#:jar-name "java-ops4j-base-spi.jar"
5525 #:source-dir "ops4j-base-spi/src/main/java"
5526 #:test-dir "ops4j-base-spi/src/test"))
5528 `(("junit" ,java-junit)
5529 ("hamcrest" ,java-hamcrest-core)))
5530 (description "OPS4J stands for Open Participation Software for Java. This
5531 package contains utilities for obtaining services via the Java SE 6
5532 @code{ServiceLoader}.")))
5534 (define-public java-aqute-bnd-annotation
5536 (name "java-aqute-bnd-annotation")
5540 (uri (string-append "https://github.com/bndtools/bnd/archive/"
5541 version ".REL.tar.gz"))
5542 (file-name (string-append name "-" version ".tar.gz"))
5545 "09vgb6axikbz66zi9falijbnzh1qnp9ysfns123dmzdb01cbza9q"))))
5546 (build-system ant-build-system)
5548 `(#:jar-name "java-aqute-bnd-annotation.jar"
5549 #:source-dir "biz.aQute.bnd.annotation/src"
5550 #:tests? #f)); empty test dir
5551 (home-page "http://bnd.bndtools.org/")
5552 (synopsis "Tools for OSGi")
5553 (description "Bnd is a swiss army knife for OSGi, it creates manifest
5554 headers based on analyzing the class code, it verifies the project settings,
5555 it manages project dependencies, gives diffs jars, and much more.")
5556 (license license:asl2.0)))
5558 (define-public java-aqute-libg
5560 (inherit java-aqute-bnd-annotation)
5561 (name "java-aqute-libg")
5563 `(#:jar-name "java-aqute-libg.jar"
5564 #:source-dir "aQute.libg/src"
5565 #:tests? #f)); FIXME: tests are in "aQute.libg/test", not in a java directory
5567 `(("slf4j" ,java-slf4j-api)
5568 ("osgi-annot" ,java-osgi-annotation)
5569 ("java-osgi-cmpn" ,java-osgi-cmpn)
5570 ("osgi" ,java-osgi-core)))))
5572 (define-public java-aqute-bndlib
5574 (inherit java-aqute-bnd-annotation)
5575 (name "java-aqute-bndlib")
5577 `(#:jar-name "java-bndlib.jar"
5578 #:source-dir "biz.aQute.bndlib/src"
5579 #:tests? #f)); no tests
5581 `(("slf4j" ,java-slf4j-api)
5582 ("osgi-annot" ,java-osgi-annotation)
5583 ("java-aqute-libg" ,java-aqute-libg)
5584 ("java-aqute-bnd-annotation" ,java-aqute-bnd-annotation)
5585 ("java-osgi-service-component-annotations" ,java-osgi-service-component-annotations)
5586 ("java-osgi-service-repository" ,java-osgi-service-repository)
5587 ("java-osgi-service-log" ,java-osgi-service-log)
5588 ("java-osgi-service-metatype-annotations" ,java-osgi-service-metatype-annotations)
5589 ("java-osgi-namespace-contract" ,java-osgi-namespace-contract)
5590 ("java-osgi-namespace-extender" ,java-osgi-namespace-extender)
5591 ("java-osgi-namespace-service" ,java-osgi-namespace-service)
5592 ("promise" ,java-osgi-util-promise)
5593 ("osgi" ,java-osgi-core)))))
5595 (define-public java-ops4j-pax-tinybundles
5597 (name "java-ops4j-pax-tinybundles")
5601 (uri (string-append "https://github.com/ops4j/org.ops4j.pax.tinybundles/"
5602 "archive/tinybundles-" version ".tar.gz"))
5605 "0y0gq3pvv0iir2b885lmlwnvr724vv7vklzhhr4fs27d7mdkj871"))))
5607 `(#:jar-name "java-ops4j-pax-tinybundles.jar"
5608 #:source-dir "src/main/java"
5610 ;; Abstract base classes for other tests
5611 (list "**/BndTest.java" "**/CoreTest.java")
5613 (modify-phases %standard-phases
5614 (add-before 'check 'fix-version
5616 ;; This test has a reference to an old version of bndlib we are not
5617 ;; packaging. It uses the version referenced in pom.xml. We replace
5618 ;; it with our own version.
5619 (substitute* "src/test/java/org/ops4j/pax/tinybundles/bnd/BndTest.java"
5620 (("2.4.0.201411031534") "3.4.0")))))))
5622 `(("lang" ,java-ops4j-base-lang)
5623 ("io" ,java-ops4j-base-io)
5624 ("store" ,java-ops4j-base-store)
5625 ("slf4j" ,java-slf4j-api)
5626 ("libg" ,java-aqute-libg)
5627 ("bndlib" ,java-aqute-bndlib)))
5629 `(("junit" ,java-junit)
5630 ("hamcrest" ,java-hamcrest-core)
5631 ("log4j" ,java-log4j-api)
5632 ("bndannotation" ,java-aqute-bnd-annotation)
5633 ("framework" ,java-osgi-framework)))
5634 (build-system ant-build-system)
5635 (home-page "https://ops4j1.jira.com/wiki/spaces/ops4j/pages/12060312/Tinybundles")
5636 (synopsis "Java APIs to create OSGi related artifacts")
5637 (description "Tinybundles is all about creating OSGi related artifacts like
5638 Bundles, Fragments and Deployment Packages with Java Api. It is very convinient
5639 to create such artifacts on-the-fly inside Tests (like in Pax Exam). On the
5640 other hand, this library can be a foundation of real end user tools that need
5641 to create those artifacts.")
5642 (license license:asl2.0)))
5644 (define-public java-ops4j-pax-exam-core
5646 (name "java-ops4j-pax-exam-core")
5650 (uri (string-append "https://github.com/ops4j/org.ops4j.pax.exam2/"
5651 "archive/exam-reactor-" version ".tar.gz"))
5654 "08mzw8nkah3rj3vznlplnawspxhp61zgvb44ifqa1rni1cvbms2g"))))
5656 `(#:jar-name "java-ops4j-pax-exam-core.jar"
5657 #:source-dir "core/pax-exam/src/main/java"
5658 #:test-dir "core/pax-exam/src/test"))
5660 `(("slf4j" ,java-slf4j-api)
5661 ("lang" ,java-ops4j-base-lang)
5662 ("io" ,java-ops4j-base-io)
5663 ("util-property" ,java-ops4j-base-util-property)
5664 ("util-store" ,java-ops4j-base-store)
5665 ("java-osgi-core" ,java-osgi-core)))
5667 `(("junit" ,java-junit)
5668 ("hamcrest" ,java-hamcrest-core)))
5669 (build-system ant-build-system)
5670 (home-page "https://ops4j1.jira.com/wiki/spaces/PAXEXAM4/overview")
5671 (synopsis "In-Container Testing for OSGi, Java EE and CDI")
5672 (description "Pax Exam creates OSGi bundles for testing purposes. It lets
5673 the user take control of the OSGi framework, the test framework (e.g. JUnit) and
5674 the system under test at the same time.")
5675 (license license:asl2.0)))
5677 (define-public java-ops4j-pax-exam-core-spi
5679 (inherit java-ops4j-pax-exam-core)
5680 (name "java-ops4j-pax-exam-core-spi")
5682 `(#:jar-name "java-ops4j-pax-exam-spi.jar"
5683 #:source-dir "src/main/java"
5686 ;; Abstract base class, not a test
5687 "**/BaseStagedReactorTest.java"
5688 ;; Depends on org.mortbay.jetty.testwars:test-war-dump
5689 "**/WarBuilderTest.java")
5691 (modify-phases %standard-phases
5692 (add-before 'configure 'chdir
5694 ;; Tests assume we are in this directory
5695 (chdir "core/pax-exam-spi")))
5696 (add-before 'check 'fix-tests
5698 ;; One test checks that this file is present.
5699 (mkdir-p "build/classes/META-INF/maven/org.ops4j.pax.exam/pax-exam-spi")
5700 (with-output-to-file
5701 "build/classes/META-INF/maven/org.ops4j.pax.exam/pax-exam-spi/pom.properties"
5704 (string-append "artifactId = pax-exam-spi\n"
5705 "version = " ,(package-version java-ops4j-pax-exam-core-spi)))))
5706 ;; Maven puts compilation results in the target directory, while we
5707 ;; put them in the build directory.
5708 (substitute* '("src/test/java/org/ops4j/pax/exam/spi/war/WarBuilderTest.java"
5709 "src/test/java/org/ops4j/pax/exam/spi/war/WarTestProbeBuilderTest.java"
5710 "src/test/java/org/ops4j/pax/exam/spi/war/ZipBuilderTest.java")
5711 (("target") "build"))
5712 ;; One test is expected to fail, but it doesn't throw the expected exception
5713 (substitute* "src/test/java/org/ops4j/pax/exam/spi/reactors/BaseStagedReactorTest.java"
5714 (("AssertionError") "IllegalArgumentException")))))))
5716 `(("java-ops4j-pax-exam-core" ,java-ops4j-pax-exam-core)
5717 ("lang" ,java-ops4j-base-lang)
5718 ("monitors" ,java-ops4j-base-monitors)
5719 ("store" ,java-ops4j-base-store)
5720 ("io" ,java-ops4j-base-io)
5721 ("spi" ,java-ops4j-base-spi)
5722 ("osgi" ,java-osgi-core)
5723 ("slf4j" ,java-slf4j-api)
5724 ("tinybundles" ,java-ops4j-pax-tinybundles)))
5726 `(("mockito" ,java-mockito-1)
5727 ("junit" ,java-junit)
5728 ("hamcrest" ,java-hamcrest-core)
5729 ("cglib" ,java-cglib)
5730 ("objenesis" ,java-objenesis)
5731 ("asm" ,java-asm)))))
5733 (define-public java-ops4j-pax-exam-core-junit
5735 (inherit java-ops4j-pax-exam-core)
5736 (name "java-ops4j-pax-exam-core-junit")
5738 `(#:jar-name "ops4j-pax-exam-core-junit.jar"
5739 #:source-dir "drivers/pax-exam-junit4/src/main/java"
5740 #:tests? #f)); no tests
5742 `(("junit" ,java-junit)
5743 ("slf4j" ,java-slf4j-api)
5744 ("core" ,java-ops4j-pax-exam-core)
5745 ("spi" ,java-ops4j-pax-exam-core-spi)))
5746 (native-inputs '())))
5748 (define-public java-fasterxml-jackson-annotations
5750 (name "java-fasterxml-jackson-annotations")
5754 (uri (string-append "https://github.com/FasterXML/"
5755 "jackson-annotations/archive/"
5756 "jackson-annotations-" version ".tar.gz"))
5759 "005ksgqx2ds3zdmlvbcmmz82y28b1mx0i9bpvprim1jaddbba0bd"))))
5760 (build-system ant-build-system)
5762 `(#:jar-name "jackson-annotations.jar"
5763 #:source-dir "src/main/java"
5764 #:test-dir "src/test"))
5766 `(("junit" ,java-junit)))
5767 (home-page "https://github.com/FasterXML/jackson-annotations")
5768 (synopsis "General purpose annotations for the Jackson Data Processor")
5769 (description "This package contains general purpose annotations for the
5770 Jackson Data Processor, used on value and handler types. The only annotations
5771 not included are ones that require dependency to the Databind package.")
5772 (license license:asl2.0)))
5774 (define-public java-fasterxml-jackson-core
5776 (name "java-fasterxml-jackson-core")
5780 (uri (string-append "https://github.com/FasterXML/"
5781 "jackson-core/archive/"
5782 "jackson-core-" version ".tar.gz"))
5785 "1sdfp74zvlh4xr5h5bj87yjlp6kny3i8ai9m0q3xs7f8hvmxpx09"))))
5786 (build-system ant-build-system)
5788 `(#:jar-name "jackson-core.jar"
5789 #:source-dir "src/main/java"
5790 #:test-dir "src/test"
5793 ;; Expected failure. pom.xml excludes these
5795 ;; Base classes that have no constructor for junit
5797 "**/ConcurrencyReadTest.java"
5798 "**/ManualCharAccessTest.java"
5799 "**/ManualCharAccessTest.java"
5800 "**/TrailingCommasTest.java"
5801 "**/AsyncMissingValuesInObjectTest.java"
5802 "**/AsyncMissingValuesInArrayTest.java")
5804 (modify-phases %standard-phases
5805 (add-before 'configure 'generate-PackageVersion.java
5807 (let* ((out "src/main/java/com/fasterxml/jackson/core/json/PackageVersion.java")
5808 (in (string-append out ".in")))
5811 (("@package@") "com.fasterxml.jackson.core.json")
5812 (("@projectversion@") ,version)
5813 (("@projectgroupid@") "com.fasterxml.jackson.core")
5814 (("@projectartifactid@") "jackson-core")))))
5815 (add-before 'build 'copy-resources
5817 (copy-recursively "src/main/resources"
5819 (add-before 'check 'copy-test-resources
5821 (copy-recursively "src/test/resources"
5822 "build/test-classes"))))))
5824 `(("junit" ,java-junit)
5825 ("hamcrest" ,java-hamcrest-core)))
5826 (home-page "https://github.com/FasterXML/jackson-core")
5829 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
5831 (define-public java-fasterxml-jackson-databind
5833 (name "java-fasterxml-jackson-databind")
5837 (uri (string-append "https://github.com/FasterXML/"
5838 "jackson-databind/archive/"
5839 "jackson-databind-" version ".tar.gz"))
5842 "02xrbj6g7pzybq8q33xmpf7cxfapk6z6lgxvig7d38fijz400lji"))))
5843 (build-system ant-build-system)
5845 `(#:jar-name "jackson-databind.jar"
5846 #:source-dir "src/main/java"
5847 #:tests? #f; requires javax.measures for which I can't find a free implementation
5849 (modify-phases %standard-phases
5850 (add-before 'configure 'generate-PackageVersion.java
5852 (let* ((out "src/main/java/com/fasterxml/jackson/databind/cfg/PackageVersion.java")
5853 (in (string-append out ".in")))
5856 (("@package@") "com.fasterxml.jackson.databind.cfg")
5857 (("@projectversion@") ,version)
5858 (("@projectgroupid@") "com.fasterxml.jackson.databind")
5859 (("@projectartifactid@") "jackson-databind")))))
5860 (add-before 'build 'copy-resources
5862 (copy-recursively "src/main/resources" "build/classes"))))))
5864 `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations)
5865 ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core)))
5866 (home-page "https://github.com/FasterXML/jackson-databind")
5867 (synopsis "Data-binding functionality and tree-model for the Jackson Data Processor")
5868 (description "This package contains the general-purpose data-binding
5869 functionality and tree-model for Jackson Data Processor. It builds on core
5870 streaming parser/generator package, and uses Jackson Annotations for
5872 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
5874 (define-public java-fasterxml-jackson-modules-base-jaxb
5876 (name "java-fasterxml-jackson-modules-base-jaxb")
5880 (uri (string-append "https://github.com/FasterXML/"
5881 "jackson-modules-base/archive/"
5882 "jackson-modules-base-" version ".tar.gz"))
5885 "0bj2pzvycnj3ysbcfa6xl38dmvnp01mnjfcb9jyhv503fch2iv44"))))
5886 (build-system ant-build-system)
5888 `(#:jar-name "jackson-modules-base-jaxb.jar"
5889 #:source-dir "jaxb/src/main/java"
5890 #:test-dir "jaxb/src/test"
5892 ;; Base class for tests
5893 (list "**/BaseJaxbTest.java")
5895 (modify-phases %standard-phases
5896 (add-before 'configure 'generate-PackageVersion.java
5898 (let* ((out (string-append "jaxb/src/main/java/com/fasterxml/"
5899 "jackson/module/jaxb/PackageVersion.java"))
5900 (in (string-append out ".in")))
5903 (("@package@") "com.fasterxml.jackson.module.jaxb")
5904 (("@projectversion@") ,version)
5905 (("@projectgroupid@") "com.fasterxml.jackson.module.jaxb")
5906 (("@projectartifactid@") "jackson-module-jaxb")))))
5907 (add-before 'build 'copy-resources
5909 (copy-recursively "jaxb/src/main/resources" "build/classes"))))))
5911 `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations)
5912 ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core)
5913 ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind)))
5915 `(("java-junit" ,java-junit)))
5916 (home-page "https://github.com/FasterXML/jackson-modules-base")
5917 (synopsis "Jaxb annotations jackson module")
5918 (description "This package is the jaxb annotations module for jackson.")
5919 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
5921 (define-public java-snakeyaml
5923 (name "java-snakeyaml")
5927 (uri (string-append "https://bitbucket.org/asomov/snakeyaml/get/v"
5931 "0rf5ha6w0waz50jz2479jsrbgmd0dnx0gs337m126j5z7zlmg7mg"))))
5932 (build-system ant-build-system)
5934 `(#:jar-name "java-snakeyaml.jar"
5935 #:source-dir "src/main/java"
5936 ;; Tests require velocity, a cyclic dependency, and
5937 ;; java-spring-framework-context which is not packaged.
5939 (home-page "https://bitbucket.org/asomov/snakeyaml")
5940 (synopsis "YAML processor")
5941 (description "SnakeYAML is a YAML processor for the Java Virtual Machine.")
5942 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
5944 (define-public java-fasterxml-jackson-dataformat-yaml
5946 (name "java-fasterxml-jackson-dataformat-yaml")
5950 (uri (string-append "https://github.com/FasterXML/"
5951 "jackson-dataformats-text/archive/"
5952 "jackson-dataformats-text-" version ".tar.gz"))
5955 "140fwcafv05zbh2ppa6z533dzmfcvzbdxf0dbpbyzqvd84v2vhl2"))))
5956 (build-system ant-build-system)
5958 `(#:jar-name "jackson-dataformat-yaml.jar"
5959 #:source-dir "yaml/src/main/java"
5960 #:test-dir "yaml/src/test"
5961 #:test-exclude (list "**/failing/**.java")
5963 (modify-phases %standard-phases
5964 (add-before 'configure 'generate-PackageVersion.java
5966 (let* ((out "yaml/src/main/java/com/fasterxml/jackson/dataformat/yaml/PackageVersion.java")
5967 (in (string-append out ".in")))
5970 (("@package@") "com.fasterxml.jackson.dataformat.yaml")
5971 (("@projectversion@") ,version)
5972 (("@projectgroupid@") "com.fasterxml.jackson.dataformat.yaml")
5973 (("@projectartifactid@") "jackson-dataformat-yaml"))))))))
5975 `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations)
5976 ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core)
5977 ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind)
5978 ("java-snakeyaml" ,java-snakeyaml)))
5980 `(("junit" ,java-junit)
5981 ("hamcrest" ,java-hamcrest-core)
5982 ("java-ops4j-pax-exam-core-spi" ,java-ops4j-pax-exam-core-spi)
5983 ("java-ops4j-pax-exam-core-junit" ,java-ops4j-pax-exam-core-junit)
5984 ("java-ops4j-pax-exam" ,java-ops4j-pax-exam-core)))
5985 (home-page "https://github.com/FasterXML/jackson-dataformats-text")
5986 (synopsis "Yaml backend for Jackson")
5987 (description "Dataformat backends are used to support format alternatives
5988 to JSON, supported by default. This is done by sub-classing Jackson core
5990 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
5992 (define-public java-stax2-api
5994 (name "java-stax2-api")
5998 (uri (string-append "https://github.com/FasterXML/stax2-api/archive/"
5999 "stax2-api-" version ".tar.gz"))
6002 "1amc1si0l0hyyw2sawmnzy4hkna3z6fp195y4nm5m9wb9ld5awkq"))))
6003 (build-system ant-build-system)
6005 `(#:jar-name "java-stax2-api.jar"
6006 #:source-dir "src/main/java"
6007 #:tests? #f)); no tests
6008 (home-page "https://github.com/FasterXML/stax2-api")
6009 (synopsis "Stax2 API")
6010 (description "Stax2 API is an extension to basic Stax 1.0 API that adds
6011 significant new functionalities, such as full-featured bi-direction validation
6012 interface and high-performance Typed Access API.")
6013 (license license:bsd-2)))
6015 (define-public java-woodstox-core
6017 (name "java-woodstox-core")
6021 (uri (string-append "https://github.com/FasterXML/woodstox/archive/"
6022 "woodstox-core-" version ".tar.gz"))
6025 "1i7pdgb8jbw6gdy5kmm0l6rz109n2ns92pqalpyp24vb8vlvdfd4"))))
6026 (build-system ant-build-system)
6028 `(#:jar-name "woodstox.jar"
6030 (list "**/Base*.java" "failing/**")
6032 (modify-phases %standard-phases
6033 (add-before 'build 'remove-msv-dep
6035 ;; we don't need osgi, and it depends on msv
6036 (delete-file-recursively "src/main/java/com/ctc/wstx/osgi")
6037 ;; msv's latest release is from 2011 and we don't need it
6038 (delete-file-recursively "src/main/java/com/ctc/wstx/msv")
6039 (delete-file-recursively "src/test/java/wstxtest/osgi")
6040 (delete-file-recursively "src/test/java/wstxtest/msv")))
6041 (add-before 'build 'copy-resources
6043 (copy-recursively "src/main/resources" "build/classes"))))))
6045 `(("stax2" ,java-stax2-api)))
6047 `(("junit" ,java-junit)))
6048 (home-page "https://github.com/FasterXML/woodstox")
6049 (synopsis "Stax XML API implementation")
6050 (description "Woodstox is a stax XML API implementation.")
6051 (license license:asl2.0)))
6053 (define-public java-fasterxml-jackson-dataformat-xml
6055 (name "java-fasterxml-jackson-dataformat-xml")
6059 (uri (string-append "https://github.com/FasterXML/"
6060 "jackson-dataformat-xml/archive/"
6061 "jackson-dataformat-xml-" version ".tar.gz"))
6064 "0x3m9n4kwclcyvxhxjx654qpjza4crphml1q2392qpnbfydx6lnh"))))
6065 (build-system ant-build-system)
6067 `(#:jar-name "jackson-dataformat-xml.jar"
6068 #:source-dir "src/main/java"
6070 (list "**/failing/**")
6072 (modify-phases %standard-phases
6073 (add-before 'configure 'generate-PackageVersion.java
6075 (let* ((out "src/main/java/com/fasterxml/jackson/dataformat/xml/PackageVersion.java")
6076 (in (string-append out ".in")))
6080 (("@package@") "com.fasterxml.jackson.dataformat.xml")
6081 (("@projectversion@") ,version)
6082 (("@projectgroupid@") "com.fasterxml.jackson.dataformat.xml")
6083 (("@projectartifactid@") "jackson-dataformat-xml")))))
6084 (add-before 'build 'copy-resources
6086 (copy-recursively "src/main/resources" "build/classes"))))))
6088 `(("jackson-annotations" ,java-fasterxml-jackson-annotations)
6089 ("jackson-core" ,java-fasterxml-jackson-core)
6090 ("jackson-modules-base-jaxb" ,java-fasterxml-jackson-modules-base-jaxb)
6091 ("jackson-databind" ,java-fasterxml-jackson-databind)
6092 ("stax2-api" ,java-stax2-api)
6093 ("woodstox" ,java-woodstox-core)))
6095 `(("junit" ,java-junit)
6096 ("hamcrest" ,java-hamcrest-core)))
6097 (home-page "https://github.com/FasterXML/jackson-dataformat-xml")
6098 (synopsis "Read and write XML")
6099 (description "This package contains Jackson extension component for reading
6100 and writing XML encoded data.
6102 Further, the goal is to emulate how JAXB data-binding works with \"Code-first\"
6103 approach (that is, no support is added for \"Schema-first\" approach). Support
6104 for JAXB annotations is provided by JAXB annotation module; this module
6105 provides low-level abstractions (@code{JsonParser}, @code{JsonGenerator},
6106 @code{JsonFactory}) as well as small number of higher level overrides needed to
6107 make data-binding work.")
6108 (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing
6110 (define-public java-hdrhistogram
6112 (name "java-hdrhistogram")
6116 (uri (string-append "https://github.com/HdrHistogram/HdrHistogram/"
6117 "archive/HdrHistogram-" version ".tar.gz"))
6120 "1sicbmc3sr42nw93qbkb26q9rn33ag33k6k77phjc3j5h5gjffqv"))))
6121 (build-system ant-build-system)
6123 `(#:jar-name "java-hdrhistogram.jar"
6124 #:source-dir "src/main/java"
6126 (modify-phases %standard-phases
6127 (add-before 'configure 'set-version
6129 (let* ((version-java "src/main/java/org/HdrHistogram/Version.java")
6130 (template (string-append version-java ".template")))
6131 (copy-file template version-java)
6132 (substitute* version-java
6133 (("\\$VERSION\\$") ,version)
6134 (("\\$BUILD_TIME\\$") "0"))
6137 `(("junit" ,java-junit)
6138 ("hamcrest" ,java-hamcrest-core)))
6139 (home-page "https://hdrhistogram.github.io/HdrHistogram")
6140 (synopsis "High dynamic range histogram")
6141 (description "Hdrhistogram allows to create histograms that support
6142 recording and analyzing sampled data value counts across a configurable integer
6143 value range with configurable value precision within the range. Value precision
6144 is expressed as the number of significant digits in the value recording, and
6145 provides control over value quantization behavior across the value range and
6146 the subsequent value resolution at any given level.")
6147 (license license:public-domain)))
6149 (define-public java-aopalliance
6151 (name "java-aopalliance")
6155 ;; Note: this git repository is not official, but contains the
6156 ;; source code that is in the CVS repository. Downloading the
6157 ;; tarball from sourceforge is undeterministic, and the cvs download
6160 (url "https://github.com/hoverruan/aopalliance")
6161 (commit "0d7757ae204e5876f69431421fe9bc2a4f01e8a0")))
6162 (file-name (string-append name "-" version))
6165 "0rsg2b0v3hxlq2yk1i3m2gw3xwq689j3cwx9wbxvqfpdcjbca0qr"))))
6166 (build-system ant-build-system)
6168 `(#:jar-name "java-aopalliance.jar"
6170 #:tests? #f; no tests
6171 #:source-dir "aopalliance/src/main"))
6172 (home-page "http://aopalliance.sourceforge.net")
6173 (synopsis "Aspect-Oriented Programming")
6174 (description "The AOP Alliance project is a joint project between several
6175 software engineering people who are interested in Aspect-Oriented Programming
6177 (license license:public-domain)))
6179 (define-public java-javax-inject
6181 (name "java-javax-inject")
6185 (uri (string-append "https://github.com/javax-inject/javax-inject/"
6186 "archive/javax.inject-" version ".tar.gz"))
6189 "1ydrlvh2r7vr1g7lhjwy3w2dggpj9h6pix1lakkkgdywb365n6g0"))))
6190 (build-system ant-build-system)
6192 `(#:jar-name "java-javax-inject.jar"
6194 #:tests? #f)); no tests
6195 (home-page "http://github.com/javax-inject/javax-inject")
6196 (synopsis "JSR-330: Dependency Injection for Java")
6197 (description "This package specifies a means for obtaining objects in such
6198 a way as to maximize reusability, testability and maintainability compared to
6199 traditional approaches such as constructors, factories, and service locators
6200 (e.g., JNDI). This process, known as dependency injection, is beneficial to
6201 most nontrivial applications.
6203 Many types depend on other types. For example, a @var{Stopwatch} might depend
6204 on a @var{TimeSource}. The types on which a type depends are known as its
6205 dependencies. The process of finding an instance of a dependency to use at run
6206 time is known as resolving the dependency. If no such instance can be found,
6207 the dependency is said to be unsatisfied, and the application is broken.")
6208 (license license:asl2.0)))
6210 (define-public java-guice
6216 (uri (string-append "https://github.com/google/guice/archive/"
6218 (file-name (string-append name "-" version ".tar.gz"))
6221 "0dwmqjzlavb144ywqqglj3h68hqszkff8ai0a42hyb5il0qh4rbp"))))
6222 (build-system ant-build-system)
6224 `(#:jar-name "java-guice.jar"
6226 #:tests? #f; FIXME: tests are not in a java sub directory
6227 #:source-dir "core/src"))
6229 `(("guava" ,java-guava)
6230 ("java-cglib" ,java-cglib)
6231 ("java-aopalliance" ,java-aopalliance)
6232 ("java-javax-inject" ,java-javax-inject)
6233 ("java-asm" ,java-asm)))
6234 (home-page "https://github.com/google/guice")
6235 (synopsis "Lightweight dependency injection framework")
6236 (description "Guice is a lightweight dependency injection framework fo
6238 (license license:asl2.0)))
6240 (define-public java-guice-servlet
6242 (inherit java-guice)
6243 (name "java-guice-servlet")
6245 `(#:jar-name "guice-servlet.jar"
6246 #:source-dir "extensions/servlet/src/"
6248 #:tests? #f)); FIXME: not in a java subdir
6250 `(("guice" ,java-guice)
6251 ("servlet" ,java-tomcat)
6252 ,@(package-inputs java-guice)))))
6254 (define-public java-assertj
6256 (name "java-assertj")
6260 (uri (string-append "https://github.com/joel-costigliola/"
6261 "assertj-core/archive/"
6262 "assertj-core-" version ".tar.gz"))
6265 "1kf124fxskf548rklkg86294w2x6ajqrff94rrhyqns31danqkfz"))))
6266 (build-system ant-build-system)
6268 `(#:jar-name "java-assertj.jar"
6270 #:source-dir "src/main/java"
6271 #:tests? #f)); depends on tng-junit which depends on assertj
6273 `(("cglib" ,java-cglib)
6274 ("junit" ,java-junit)
6275 ("hamcrest" ,java-hamcrest-core)))
6277 `(("mockito" ,java-mockito-1)))
6278 (home-page "https://joel-costigliola.github.io/assertj/index.html")
6279 (synopsis "Fluent assertions for java")
6280 (description "AssertJ core is a Java library that provides a fluent
6281 interface for writing assertions. Its main goal is to improve test code
6282 readability and make maintenance of tests easier.")
6283 (license license:asl2.0)))
6285 (define-public java-jboss-javassist
6287 (name "java-jboss-javassist")
6291 (uri (string-append "https://github.com/jboss-javassist/javassist/"
6293 (string-map (lambda (x) (if (eq? x #\.) #\_ x)) version)
6297 "10lpcr3sbf7y6fq6fc2h2ik7rqrivwcy4747bg0kxhwszil3cfmf"))))
6298 (build-system ant-build-system)
6300 `(#:jar-name "java-jboss-javassist.jar"
6302 #:source-dir "src/main"
6303 #:tests? #f; FIXME: requires junit-awtui and junit-swingui from junit3
6305 (modify-phases %standard-phases
6306 (add-before 'configure 'remove-binary
6308 (delete-file "javassist.jar")
6311 `(("junit" ,java-junit)))
6312 (home-page "https://github.com/jboss-javassist/javassist")
6313 (synopsis "Java bytecode engineering toolkit")
6314 (description "Javassist (JAVA programming ASSISTant) makes Java bytecode
6315 manipulation simple. It is a class library for editing bytecodes in Java; it
6316 enables Java programs to define a new class at runtime and to modify a class
6317 file when the JVM loads it.")
6318 (license (list license:gpl2 license:cddl1.0)))); either gpl2 only or cddl.
6320 (define-public java-jcommander
6322 (name "java-jcommander")
6326 (uri (string-append "https://github.com/cbeust/jcommander/archive/"
6328 (file-name (string-append name "-" version ".tar.gz"))
6331 "1f5k2ckay6qjc3d3w3d7bc0p3cx3c7n6p6zxvw1kibqdr0q98wlx"))))
6332 (build-system ant-build-system)
6334 `(#:jar-name "java-jcommander.jar"
6336 #:tests? #f; requires testng which depends on jcommander
6337 #:source-dir "src/main/java"))
6338 (home-page "http://jcommander.org")
6339 (synopsis "Command line parameters parser")
6340 (description "JCommander is a very small Java framework that makes it
6341 trivial to parse command line parameters. Parameters are declared with
6343 (license license:asl2.0)))
6345 (define-public java-bsh
6351 (uri (string-append "https://github.com/beanshell/beanshell/archive/"
6353 (file-name (string-append name "-" version ".tar.gz"))
6356 "1bawkxk6jyc75hxvzkpz689h73cn3f222m0ar3nvb0dal2b85kfv"))))
6357 (build-system ant-build-system)
6359 `(#:build-target "jarall"
6360 #:test-target "junit-tests-all"
6362 (modify-phases %standard-phases
6364 (lambda* (#:key outputs #:allow-other-keys)
6365 (let ((share (string-append (assoc-ref outputs "out") "/share/java")))
6367 (copy-file "dist/bsh-2.0b6.jar" (string-append share "/bsh-2.0b6.jar"))
6369 (home-page "http://beanshell.org/")
6370 (synopsis "Lightweight Scripting for Java")
6371 (description "BeanShell is a small, free, embeddable Java source
6372 interpreter with object scripting language features, written in Java.
6373 BeanShell dynamically executes standard Java syntax and extends it with common
6374 scripting conveniences such as loose types, commands, and method closures like
6375 those in Perl and JavaScript.")
6376 (license license:asl2.0)))
6378 (define-public java-fest-util
6380 (name "java-fest-util")
6384 (uri (string-append "https://github.com/alexruiz/fest-util/"
6385 "archive/fest-util-" version ".tar.gz"))
6388 "05g6hljz5mdaakk8d7g32klbhz9bdwp3qlj6rdaggdidxs3x1sb8"))))
6389 (build-system ant-build-system)
6391 `(#:jar-name "java-fest-util.jar"
6392 #:source-dir "src/main/java"))
6394 `(("junit" ,java-junit)
6395 ("hamcrest" ,java-hamcrest-core)))
6396 (home-page "https://github.com/alexruiz/fest-util")
6397 (synopsis "FEST common utilities")
6398 (description "Common utilities used in all FEST module.")
6399 (license license:asl2.0)))
6401 (define-public java-fest-test
6403 (name "java-fest-test")
6407 (uri (string-append "https://github.com/alexruiz/fest-test/"
6408 "archive/fest-test-" version ".tar.gz"))
6411 "1rxfbw6l9vc65iy1x3fb617qc6y4w2k430pgf1mfbxfdlxbm0f7g"))))
6412 (build-system ant-build-system)
6414 `(#:jar-name "java-fest-test.jar"
6415 #:source-dir "src/main/java"
6416 #:tests? #f)); no tests
6418 `(("junit" ,java-junit)))
6419 (home-page "https://github.com/alexruiz/fest-test")
6420 (synopsis "Common FEST testing infrastructure")
6421 (description "Fest-test contains the common FEST testing infrastructure.")
6422 (license license:asl2.0)))
6424 (define-public java-fest-assert
6426 (name "java-fest-assert")
6430 (uri (string-append "https://github.com/alexruiz/fest-assert-2.x/"
6431 "archive/fest-assert-core-" version ".tar.gz"))
6434 "1bi0iqavikzww6rxvz5jyg7y6bflv95s6ibryxx0xfcxrrw6i5lw"))))
6435 (build-system ant-build-system)
6437 `(#:jar-name "java-fest-assert.jar"
6438 #:source-dir "src/main/java"
6443 ;; Unable to set MockitoNamingPolicy on cglib generator which creates FastClasses
6444 "**/MessageFormatter_format_Test.java"
6445 "**/internal/*/*_assert*_Test.java")))
6447 `(("java-fest-util" ,java-fest-util)))
6449 `(("java-junit" ,java-junit)
6450 ("java-fest-test" ,java-fest-test)
6451 ("java-hamcrest-core" ,java-hamcrest-core)
6452 ("java-mockito" ,java-mockito-1)
6453 ("java-cglib" ,java-cglib)
6454 ("java-objenesis" ,java-objenesis)
6455 ("java-asm" ,java-asm)))
6456 (home-page "https://github.com/alexruiz/fest-assert-2.x")
6457 (synopsis "FEST fluent assertions")
6458 (description "FEST-Assert provides a fluent interface for assertions.")
6459 (license license:asl2.0)))
6461 (define-public java-testng
6463 (name "java-testng")
6467 (uri (string-append "https://github.com/cbeust/testng/archive/"
6469 (file-name (string-append name "-" version ".tar.gz"))
6472 "01j2x47wkj7n5w6gpcjfbwgc88ai5654b23lb87w7nsrj63m3by6"))))
6473 (build-system ant-build-system)
6475 `(#:jdk ,icedtea-8; java.util.function
6476 #:jar-name "java-testng.jar"
6477 #:source-dir "src/main/java"
6479 (modify-phases %standard-phases
6480 (add-before 'build 'copy-resources
6482 (copy-recursively "src/main/resources" "build/classes")
6484 (add-before 'check 'copy-test-resources
6486 (copy-recursively "src/test/resources" "build/test-classes")
6490 (system* "ant" "compile-tests")
6491 ;; we don't have groovy
6492 (substitute* "src/test/resources/testng.xml"
6493 (("<class name=\"test.groovy.GroovyTest\" />") ""))
6494 (zero? (system* "java" "-cp" (string-append (getenv "CLASSPATH")
6496 ":build/test-classes")
6497 "-Dtest.resources.dir=src/test/resources"
6498 "org.testng.TestNG" "src/test/resources/testng.xml")))))))
6500 `(("junit" ,java-junit)
6501 ("java-jsr305" ,java-jsr305)
6502 ("java-bsh" ,java-bsh)
6503 ("java-jcommander" ,java-jcommander)
6504 ("java-guice" ,java-guice)
6505 ("snakeyaml" ,java-snakeyaml)))
6507 `(("guava" ,java-guava)
6508 ("java-javax-inject" ,java-javax-inject)
6509 ("java-hamcrest" ,java-hamcrest-all)
6510 ("java-assertj" ,java-assertj)
6511 ("cglib" ,java-cglib)
6513 ("aopalliance" ,java-aopalliance)))
6514 (home-page "http://testng.org")
6515 (synopsis "Testing framework")
6516 (description "TestNG is a testing framework inspired from JUnit and NUnit
6517 but introducing some new functionalities that make it more powerful and easier
6519 (license license:asl2.0)))
6521 (define-public java-jnacl
6528 (url "https://github.com/neilalexander/jnacl")
6529 (commit "40c322e0a42637ab17cdf941138eeaf2494055f8")))
6532 "1pspnmp44q61a2q4bpslpxw86rfn8s5l0xgvyrikqgdvg7ypx597"))))
6533 (build-system ant-build-system)
6535 `(#:jar-name "java-jnacl.jar"
6536 #:source-dir "src/main/java"
6539 (modify-phases %standard-phases
6540 (add-before 'build 'fix-tests
6542 (substitute* "src/test/java/com/neilalexander/jnacl/NaClTest.java"
6543 (("assertions.Assertions") "assertions.api.Assertions"))
6544 (substitute* "src/test/java/com/neilalexander/jnacl/NaclSecretBoxTest.java"
6545 (("assertions.Assertions") "assertions.api.Assertions"))
6549 (system* "ant" "compile-tests")
6551 (zero? (system* "java" "-cp" (string-append (getenv "CLASSPATH")
6553 ":build/test-classes")
6554 "org.testng.TestNG" "-testclass"
6555 "build/test-classes/com/neilalexander/jnacl/NaclSecretBoxTest.class"))
6556 (zero? (system* "java" "-cp" (string-append (getenv "CLASSPATH")
6558 ":build/test-classes")
6559 "org.testng.TestNG" "-testclass"
6560 "build/test-classes/com/neilalexander/jnacl/NaClTest.class"))))))))
6562 `(("java-testng" ,java-testng)
6563 ("java-fest-util" ,java-fest-util)
6564 ("java-fest-assert" ,java-fest-assert)))
6565 (home-page "https://github.com/neilalexander/jnacl")
6566 (synopsis "Java implementation of NaCl")
6567 (description "Pure Java implementation of the NaCl: Networking and
6568 Cryptography library.")
6569 (license license:mpl2.0)))
6571 (define-public java-mvel2
6577 (uri (string-append "https://github.com/mvel/mvel/archive/mvel2-"
6578 version ".Final.tar.gz"))
6581 "01ph5s9gm16l2qz58lg21w6fna7xmmrj7f9bzqr1jim7h9557d3z"))))
6582 (build-system ant-build-system)
6584 `(#:jar-name "mvel2.jar"
6585 #:source-dir "src/main/java"
6587 (list "**/Abstract*.java"
6588 ;; Base class with no tests
6589 "**/MVELThreadTest.java")
6591 (modify-phases %standard-phases
6592 (add-after 'install 'install-bin
6593 (lambda* (#:key outputs #:allow-other-keys)
6594 (let ((bin (string-append (assoc-ref outputs "out") "/bin")))
6596 (with-output-to-file (string-append bin "/mvel2")
6600 "#!" (which "bash") "\n"
6601 "if [ \"$#\" -ne \"2\" ]; then\n"
6602 "echo 'Usage: mvel2 <script> <out.dir>'\n"
6605 "java -Dout.dir=$2 -cp " (getenv "CLASSPATH")
6606 ":" (assoc-ref outputs "out") "/share/java/mvel2.jar"
6607 " org.mvel2.sh.Main $1"))))
6608 (chmod (string-append bin "/mvel2") #o755))
6611 `(("junit" ,java-junit)
6612 ("hamcrest" ,java-hamcrest-core)))
6613 (home-page "https://github.com/mvel/mvel")
6614 (synopsis "MVFLEX Expression Language")
6615 (description "MVEL has largely been inspired by Java syntax, but has some
6616 fundamental differences aimed at making it more efficient as an expression
6617 language, such as operators that directly support collection, array and string
6618 matching, as well as regular expressions. MVEL is used to evaluate expressions
6619 written using Java syntax.
6621 In addition to the expression language, MVEL serves as a templating language for
6622 configuration and string construction.")
6623 (license license:asl2.0)))
6625 (define-public java-lz4
6631 (uri (string-append "https://github.com/lz4/lz4-java/archive/"
6633 (file-name (string-append name "-" version ".tar.gz"))
6636 "096dm57p2lzqk28n0j2p52x2j3cvnsd2dfqn43n7vbwrkjsy7y54"))))
6637 (build-system ant-build-system)
6639 `(#:jar-name "lz4.jar"
6641 #:source-dir "src/java:src/java-unsafe"
6642 #:tests? #f; FIXME: requires more dependencies
6644 (modify-phases %standard-phases
6645 (add-before 'configure 'generate-source
6647 (with-directory-excursion "src/build/source_templates"
6648 (zero? (system* "mvel2" "../gen_sources.mvel" "../../java"))))))))
6650 `(("mvel" ,java-mvel2)))
6651 (home-page "https://jpountz.github.io/lz4-java")
6652 (synopsis "Compression algorithm")
6653 (description "LZ4 - Java is a Java port of the popular lz4 compression
6654 algorithms and xxHash hashing algorithm.")
6655 (license license:asl2.0)))
6657 (define-public java-bouncycastle-bcprov
6659 (name "java-bouncycastle-bcprov")
6663 (uri "https://bouncycastle.org/download/bcprov-jdk15on-158.tar.gz")
6666 "1hgkg96llbvgs8i0krwz2n0j7wlg6jfnq8w8kg0cc899j0wfmf3n"))))
6667 (build-system ant-build-system)
6669 `(#:jar-name "bouncycastle-bcprov.jar"
6670 #:tests? #f; no tests
6673 (modify-phases %standard-phases
6674 (add-before 'configure 'unzip-src
6677 (with-directory-excursion "src"
6678 (zero? (system* "unzip" "../src.zip"))))))))
6681 ("junit" ,java-junit)))
6682 (home-page "https://www.bouncycastle.org")
6683 (synopsis "Cryptographic library")
6684 (description "Bouncy Castle Provider (bcprov) is a cryptographic library
6685 for the Java programming language.")
6686 (license license:expat)))
6688 (define-public java-bouncycastle-bcpkix
6690 (name "java-bouncycastle-bcpkix")
6694 (uri "https://bouncycastle.org/download/bcpkix-jdk15on-158.tar.gz")
6697 "0is7qay02803s9f7lhnfcjlz61ni3hq5d7apg0iil7nbqkbfbcq2"))))
6698 (build-system ant-build-system)
6700 `(#:jar-name "bouncycastle-bcpkix.jar"
6701 #:tests? #f; no tests
6704 (modify-phases %standard-phases
6705 (add-before 'configure 'unzip-src
6708 (with-directory-excursion "src"
6709 (zero? (system* "unzip" "../src.zip"))))))))
6712 ("junit" ,java-junit)))
6714 `(("bcprov" ,java-bouncycastle-bcprov)))
6715 (home-page "https://www.bouncycastle.org")
6716 (synopsis "Cryptographic library")
6717 (description "Bouncy Castle Java API for PKIX, CMS, EAC, TSP, PKCS, OCSP,
6719 (license license:expat)))
6721 (define-public java-lmax-disruptor
6723 (name "java-lmax-disruptor")
6727 (uri (string-append "https://github.com/LMAX-Exchange/disruptor/"
6728 "archive/" version ".tar.gz"))
6729 (file-name (string-append name "-" version ".tar.gz"))
6732 "17da2gwj5abnlsfgn2xqjk5lgzbg4vkb0hdv2dvc8r2fx4bi7w3g"))))
6733 (build-system ant-build-system)
6735 `(#:jar-name "java-lmax-disruptor.jar"
6737 #:tests? #f)); tests hang
6739 `(("junit" ,java-junit)
6740 ("java-hdrhistogram" ,java-hdrhistogram)
6741 ("java-jmock" ,java-jmock)
6742 ("java-jmock-legacy" ,java-jmock-legacy)
6743 ("java-jmock-junit4" ,java-jmock-junit4)
6744 ("java-hamcrest-all" ,java-hamcrest-all)))
6746 `(("cglib" ,java-cglib)
6747 ("objenesis" ,java-objenesis)
6749 (home-page "https://www.lmax.com/disruptor")
6750 (synopsis "High performance inter-thread communication")
6751 (description "LMAX Disruptor is a software pattern and software component
6752 for high performance inter-thread communication that avoids the need for
6753 message queues or resource locking.")
6754 (license license:asl2.0)))
6756 (define-public java-xerial-core
6758 (name "java-xerial-core")
6762 (uri (string-append "https://github.com/xerial/xerial-java/archive/"
6764 (file-name (string-append name "-" version ".tar.gz"))
6767 "0d3g863i41bgalpa4xr3vm1h140l091n8iwgq5qvby5yivns9y8d"))))
6768 (build-system ant-build-system)
6770 `(#:jar-name "xerial-core.jar"
6771 #:source-dir "xerial-core/src/main/java"
6772 #:test-dir "xerial-core/src/test"
6774 (modify-phases %standard-phases
6775 (add-before 'build 'copy-resources
6777 (copy-recursively "xerial-core/src/main/resources"
6781 `(("junit" ,java-junit)
6782 ("hamcrest" ,java-hamcrest-core)))
6783 (home-page "https://github.com/xerial/xerial-java")
6784 (synopsis "Data managment libraries for Java")
6785 (description "Xerial is a set of data management libraries for the Java
6786 programming language. The ulitimate goal of the Xerial project is to manage
6787 everything as database, including class objects, text format data, data
6789 (license license:asl2.0)))
6791 (define-public java-powermock-reflect
6793 (name "java-powermock-reflect")
6797 (uri (string-append "https://github.com/powermock/powermock/"
6798 "archive/powermock-" version ".tar.gz"))
6799 (file-name (string-append name "-" version ".tar.gz"))
6802 "0sbgi5vqq7k72wzcdjb20s370vyd4hsbnx71pzb8ishml3gy7fwy"))
6804 (search-patches "java-powermock-fix-java-files.patch"))))
6805 (build-system ant-build-system)
6807 `(#:jar-name "java-powermock-reflect.jar"
6809 #:source-dir "powermock-reflect/src/main/java"
6810 #:test-dir "powermock-reflect/src/test"))
6812 `(("java-objenesis" ,java-objenesis)))
6814 `(("junit" ,java-junit)
6815 ("cglib" ,java-cglib)
6817 ("hamcrest" ,java-hamcrest-core)
6818 ("assertj" ,java-assertj)))
6819 (home-page "https://github.com/powermock/powermock")
6820 (synopsis "Mock library extension framework")
6821 (description "PowerMock is a framework that extends other mock libraries
6822 such as EasyMock with more powerful capabilities. PowerMock uses a custom
6823 classloader and bytecode manipulation to enable mocking of static methods,
6824 constructors, final classes and methods, private methods, removal of static
6825 initializers and more. By using a custom classloader no changes need to be
6826 done to the IDE or continuous integration servers which simplifies adoption.")
6827 (license license:asl2.0)))
6829 (define-public java-powermock-core
6831 (inherit java-powermock-reflect)
6832 (name "java-powermock-core")
6834 `(#:jar-name "java-powermock-core.jar"
6835 #:source-dir "powermock-core/src/main/java"
6836 #:test-dir "powermock-core/src/test"
6837 #:tests? #f; requires powermock-api
6840 `(("reflect" ,java-powermock-reflect)
6841 ("javassist" ,java-jboss-javassist)))
6843 `(("junit" ,java-junit)
6844 ("assertj" ,java-assertj)
6845 ("mockito" ,java-mockito-1)))))