gnu: facter: Update to 4.0.34.
[jackhill/guix/guix.git] / gnu / packages / java.scm
index d74f0af..3590ea9 100644 (file)
@@ -3,7 +3,7 @@
 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016, 2017 Roel Janssen <roel@gnu.org>
 ;;; Copyright © 2017, 2019 Carlo Zancanaro <carlo@zancanaro.id.au>
-;;; Copyright © 2017, 2018, 2019 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2017-2020 Julien Lepiller <julien@lepiller.eu>
 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2016, 2017, 2018 Alex Vong <alexvong1995@gmail.com>
 ;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
@@ -54,7 +54,6 @@
   #:use-module (gnu packages fontutils)
   #:use-module (gnu packages gawk)
   #:use-module (gnu packages gettext)
-  #:use-module (gnu packages gcc)
   #:use-module (gnu packages gl)
   #:use-module (gnu packages ghostscript) ;lcms
   #:use-module (gnu packages gnome)
@@ -67,6 +66,8 @@
   #:use-module (gnu packages libffi)
   #:use-module (gnu packages linux) ;alsa
   #:use-module (gnu packages maths)
+  #:use-module (gnu packages maven)
+  #:use-module (gnu packages maven-parent-pom)
   #:use-module (gnu packages nss)
   #:use-module (gnu packages onc-rpc)
   #:use-module (gnu packages web)
@@ -165,6 +166,64 @@ defined in The Java Language Specification into the bytecoded instruction set
 and binary format defined in The Java Virtual Machine Specification.")
     (license license:ibmpl1.0)))
 
+(define-public drip
+  ;; Last release is from 2014, with a few important commits afterwards.
+  (let ((commit "a4bd00df0199e78243847f06cc04ecaea31f8f08"))
+    (package
+      (name "drip")
+      (version (git-version "0.2.4" "1" commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://github.com/ninjudd/drip")
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "0wzmjwfyldr3jn49517xd8yn7dgdk8h88qkga3kjyg1zc375ylg2"))))
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("jdk" ,icedtea "jdk")))
+      (arguments
+       `(#:tests? #f                    ; No tests.
+         #:phases
+         (modify-phases %standard-phases
+           (delete 'configure)
+           (add-before 'install 'fix-wrapper
+             (lambda* (#:key inputs #:allow-other-keys)
+               (let ((jps (string-append (assoc-ref inputs "jdk") "/bin/jps")))
+                 (substitute* "bin/drip"
+                   (("jps") jps)
+                   (("brew update && brew upgrade drip") "guix pull && guix install drip")
+                   ;; No need to make:
+                   (("\\(cd -- \"\\$drip_dir\" && make -s\\) \\|\\| exit 1") "")
+                   ;; No need to include source:
+                   (("\\[\\[ -r \\$drip_dir/src/org/flatland/drip/Main\\.java \\]\\]")
+                    "true"))
+                 #t)))
+           (replace 'install
+             (lambda* (#:key outputs #:allow-other-keys)
+               (let* ((out (assoc-ref outputs "out"))
+                      (bin (string-append out "/bin"))
+                      (share (string-append out "/share/drip")))
+                 (mkdir-p bin)
+                 (for-each
+                  (lambda (file)
+                    (install-file (string-append "bin/" file) bin))
+                  '("drip" "drip_daemon" "drip_proxy"))
+                 (install-file "drip.jar" share)
+                 (substitute* (string-append bin "/drip")
+                   (("drip_dir=\\$bin_dir/..")
+                    (string-append "drip_dir=" share)))
+                 #t))))))
+      (home-page "https://github.com/ninjudd/drip")
+      (synopsis "Faster Java Virtual Machine launching")
+      (description "Drip is a launcher for the Java Virtual Machine that
+provides much faster startup times than the @command{java} command.  The @command{drip}
+script is intended to be a drop-in replacement for the @command{java} command,
+only faster.")
+      (license license:epl1.0))))
+
 ;; This is the last version of GNU Classpath that can be built without ECJ.
 (define classpath-bootstrap
   (package
@@ -254,11 +313,6 @@ language.")
        ("libffi" ,libffi)
        ("zip" ,zip)
        ("zlib" ,zlib)))
-    ;; When built with a recent GCC and glibc the configure step of icedtea-6
-    ;; fails with an invalid instruction error.
-    (native-inputs
-     `(("gcc" ,gcc-5)
-       ("libc" ,glibc-2.28)))
     (home-page "http://jamvm.sourceforge.net/")
     (synopsis "Small Java Virtual Machine")
     (description "JamVM is a Java Virtual Machine conforming to the JVM
@@ -276,7 +330,7 @@ JNI.")
     (version "1.8.4")
     (source (origin
               (method url-fetch)
-              (uri (string-append "http://archive.apache.org/dist/"
+              (uri (string-append "mirror://apache/"
                                   "ant/source/apache-ant-"
                                   version "-src.tar.bz2"))
               (sha256
@@ -708,6 +762,8 @@ machine.")))
               (sha256
                (base32
                 "1nl0zxz8y5x8gwsrm7n32bry4dx8x70p8z3s9jbdvs8avyb8whkn"))
+              (patches
+               (search-patches "jamvm-2.0.0-disable-branch-patching.patch"))
               (snippet
                '(begin
                   ;; Remove precompiled software.
@@ -2231,9 +2287,7 @@ new Date();"))
               (modules '((guix build utils)))
               (snippet
                `(begin
-                  (for-each delete-file (find-files "." ".*.bin$"))
-                  (for-each delete-file (find-files "." ".*.exe$"))
-                  (for-each delete-file (find-files "." ".*.jar$"))
+                  (for-each delete-file (find-files "." ".*.(bin|exe|jar)$"))
                   #t))))
     (inputs
      `(("alsa-lib" ,alsa-lib)
@@ -2261,6 +2315,94 @@ new Date();"))
        ("zip" ,zip)))
     (home-page "https://openjdk.java.net/projects/jdk/12")))
 
+(define-public openjdk13
+  (package
+    (inherit openjdk12)
+    (name "openjdk")
+    (version "13.0")
+    (source (origin
+            (method url-fetch)
+            (uri "http://hg.openjdk.java.net/jdk/jdk13/archive/9c250a7600e1.tar.bz2")
+            (file-name (string-append name "-" version ".tar.bz2"))
+            (sha256
+             (base32
+              "0v0ljvx5dyzp96dw4z4ksw3pvasil7783mgnmd1wk9gads5ab8iq"))
+            (modules '((guix build utils)))
+            (snippet
+             `(begin
+                (for-each delete-file (find-files "." ".*.(bin|exe|jar)$"))
+                #t))))
+    (inputs
+     `(("alsa-lib" ,alsa-lib)
+       ("cups" ,cups)
+       ("fontconfig" ,fontconfig)
+       ("freetype" ,freetype)
+       ("giflib" ,giflib)
+       ("lcms" ,lcms)
+       ("libjpeg" ,libjpeg-turbo)
+       ("libpng" ,libpng)
+       ("libx11" ,libx11)
+       ("libxext" ,libxext)
+       ("libxrandr" ,libxrandr)
+       ("libxrender" ,libxrender)
+       ("libxt" ,libxt)
+       ("libxtst" ,libxtst)))
+    (native-inputs
+     `(("autoconf" ,autoconf)
+       ("openjdk12:jdk" ,openjdk12 "jdk")
+       ("make@4.2" ,gnu-make-4.2)
+       ("pkg-config" ,pkg-config)
+       ("unzip" ,unzip)
+       ("which" ,which)
+       ("zip" ,zip)))
+    (home-page "https://openjdk.java.net/projects/jdk/13")))
+
+(define-public openjdk14
+  (package
+    (inherit openjdk13)
+    (name "openjdk")
+    (version "14.0")
+    (source (origin
+             (method url-fetch)
+             (uri "http://hg.openjdk.java.net/jdk/jdk14/archive/bc54620a3848.tar.bz2")
+             (file-name (string-append name "-" version ".tar.bz2"))
+             (sha256
+              (base32
+               "0z485pk7r1xpw8004g4nrwrzj17sabgx8yfdbxwfvzkjp8qyajch"))
+             (modules '((guix build utils)))
+             (snippet
+              `(begin
+                  ;; The m4 macro uses 'help' to search for builtins, which is
+                  ;; not available in bash-minimal
+                  (substitute* "make/autoconf/basics.m4"
+                    (("if help") "if command -v"))
+                 (for-each delete-file (find-files "." ".*.(bin|exe|jar)$"))
+                 #t))))
+    (inputs
+     `(("alsa-lib" ,alsa-lib)
+       ("cups" ,cups)
+       ("fontconfig" ,fontconfig)
+       ("freetype" ,freetype)
+       ("giflib" ,giflib)
+       ("lcms" ,lcms)
+       ("libjpeg" ,libjpeg-turbo)
+       ("libpng" ,libpng)
+       ("libx11" ,libx11)
+       ("libxext" ,libxext)
+       ("libxrandr" ,libxrandr)
+       ("libxrender" ,libxrender)
+       ("libxt" ,libxt)
+       ("libxtst" ,libxtst)))
+    (native-inputs
+     `(("autoconf" ,autoconf)
+       ("make@4.2" ,gnu-make-4.2)
+       ("openjdk13:jdk" ,openjdk13 "jdk")
+       ("pkg-config" ,pkg-config)
+       ("unzip" ,unzip)
+       ("which" ,which)
+       ("zip" ,zip)))
+    (home-page "https://openjdk.java.net/projects/jdk/14")))
+
 (define-public icedtea icedtea-8)
 
 \f
@@ -2400,10 +2542,10 @@ new Date();"))
     (source (origin
               (method hg-fetch)
               (uri (hg-reference
-                     (url "http://hg.openjdk.java.net/openjfx/8u-dev/rt")
-                     (changeset (string-append
-                                  (string-join (string-split version #\.) "u")
-                                  "-ga"))))
+                    (url "http://hg.openjdk.java.net/openjfx/8u-dev/rt")
+                    (changeset (string-append
+                                (string-join (string-split version #\.) "u")
+                                "-ga"))))
               (file-name (string-append name "-" version "-checkout"))
               (modules '((guix build utils)))
               (snippet
@@ -2413,7 +2555,8 @@ new Date();"))
                   #t))
               (sha256
                (base32
-                "0yg38mwpivswccv9n96k06x3iv82i4px1a9xg9l8dswzwmfj259f"))))
+                "0yg38mwpivswccv9n96k06x3iv82i4px1a9xg9l8dswzwmfj259f"))
+              (patches (search-patches "java-openjfx-build-jdk_version.patch"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-openjfx.jar"
@@ -2513,7 +2656,7 @@ OpenJFX distribution.")))
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/javacc/javacc.git")
+                    (url "https://github.com/javacc/javacc")
                     (commit "release_41")))
               (file-name (string-append "javacc-" version "-checkout"))
               (sha256
@@ -2554,6 +2697,35 @@ as tree building (via a tool called JJTree included with JavaCC), actions,
 debugging, etc.")
     (license license:bsd-3)))
 
+;; javacc-3, as javacc-4 is not properly bootstrapped: is contains a javacc.jar
+;; in the bootstrap/ directory.
+(define-public javacc-3
+  (package
+    (inherit javacc-4)
+    (version "3.2")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/javacc/javacc.git")
+                    (commit "release_32")))
+              (file-name (string-append "javacc-" version "-checkout"))
+              (sha256
+               (base32
+                "1pyf1xyh8gk83nxqn2v2mdws32l68ydznha41cxa4l2kkbq1v1g3"))))
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'build 'set-java-version
+           (lambda _
+             (for-each
+               (lambda (file)
+                 (substitute* file
+                   (("debug=") "source=\"1.4\" debug=")))
+               (find-files "." "build.xml"))
+             #t))
+         (replace 'install (install-jars "bin/lib")))))))
+
 (define-public javacc
   (package
     (inherit javacc-4)
@@ -2562,7 +2734,7 @@ debugging, etc.")
      (origin
        (method git-fetch)
        (uri (git-reference
-             (url "https://github.com/javacc/javacc.git")
+             (url "https://github.com/javacc/javacc")
              (commit version)))
        (file-name (git-file-name "javacc" version))
        (sha256
@@ -2761,9 +2933,11 @@ Main-Class: org.eclipse.jdt.internal.compiler.batch.Main\n"
                                  ,(package-version java-commons-lang) ".jar"))
                  (("\\$\\{lib\\}/commons-io/commons-io.jar")
                   (string-append (assoc-ref inputs "java-commons-io")
-                                 "/share/java/commons-io-"
+                                 "/lib/m2/commons-io/commons-io/"
+                                 ,(package-version java-commons-io)
+                                 "/commons-io-"
                                  ,(package-version java-commons-io)
-                                 "-SNAPSHOT.jar"))
+                                 ".jar"))
                  ;; Remove dependency on svn
                  (("<build-info.*") "")
                  (("\\$\\{revision.number\\}")
@@ -3054,18 +3228,19 @@ libraries from the SIS division at ETH Zurich like jHDF5.")
                                  ,(package-version java-commons-lang) ".jar"))
                  (("\\$\\{lib\\}/commons-io/commons-io.jar")
                   (string-append (assoc-ref inputs "java-commons-io")
-                                 "/share/java/commons-io-"
+                                 "/lib/m2/commons-io/commons-io/"
                                  ,(package-version java-commons-io)
-                                 "-SNAPSHOT.jar"))
+                                 "/commons-io-"
+                                 ,(package-version java-commons-io)
+                                 ".jar"))
                  (("\\$\\{lib\\}/testng/testng-jdk15.jar")
                   (string-append (assoc-ref inputs "java-testng")
                                  "/share/java/java-testng.jar"))
                  (("\\$\\{lib\\}/junit4/junit.jar")
-                  (string-append (assoc-ref inputs "java-junit")
-                                 "/share/java/junit.jar"))
+                  (car (find-files (assoc-ref inputs "java-junit") "jar$")))
                  (("\\$\\{lib\\}/jmock/hamcrest/hamcrest-core.jar")
-                  (string-append (assoc-ref inputs "java-hamcrest-core")
-                                 "/share/java/hamcrest-core.jar")))
+                  (car (find-files (assoc-ref inputs "java-hamcrest-core")
+                                   "jar$"))))
                ;; Remove dependency on ch.rinn.restrictions
                (with-directory-excursion "source/java/ch/systemsx/cisd/hdf5/"
                  (substitute* '("BitSetConversionUtils.java"
@@ -3188,7 +3363,7 @@ API and version 2.1 of the Java ServerPages API.")
       (source (origin
                 (method git-fetch)
                 (uri (git-reference
-                      (url "https://github.com/javaee/servlet-spec.git")
+                      (url "https://github.com/javaee/servlet-spec")
                       (commit version)))
                 (file-name (git-file-name name version))
                 (sha256
@@ -3317,34 +3492,6 @@ is implemented.")
               license:mpl2.0
               license:lgpl2.1+))))
 
-(define-public java-xz
-  (package
-   (name "java-xz")
-   (version "1.6")
-   (source (origin
-     (method url-fetch)
-     (uri (string-append "http://tukaani.org/xz/xz-java-" version ".zip"))
-     (sha256
-      (base32
-       "1z3p1ri1gvl07inxn0agx44ck8n7wrzfmvkz8nbq3njn8r9wba8x"))))
-   (build-system ant-build-system)
-   (arguments
-    `(#:tests? #f ; There are no tests to run.
-      #:jar-name ,(string-append "xz-" version  ".jar")
-      #:phases
-      (modify-phases %standard-phases
-        ;; The unpack phase enters the "maven" directory by accident.
-        (add-after 'unpack 'chdir
-          (lambda _ (chdir "..") #t)))))
-   (native-inputs
-    `(("unzip" ,unzip)))
-   (home-page "https://tukaani.org/xz/java.html")
-   (synopsis "Implementation of XZ data compression in pure Java")
-   (description "This library aims to be a complete implementation of XZ data
-compression in pure Java.  Single-threaded streamed compression and
-decompression and random access decompression have been fully implemented.")
-   (license license:public-domain)))
-
 ;; java-hamcrest-core uses qdox version 1.12.  We package this version instead
 ;; of the latest release.
 (define-public java-qdox-1.12
@@ -3406,7 +3553,28 @@ documentation tools.")
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "qdox.jar"
-       #:tests? #f)); no tests
+       #:tests? #f; no tests
+       #:modules
+       ((guix build ant-build-system)
+        (guix build java-utils)
+        (guix build utils)
+        (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'install 'create-pom
+           (lambda _
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `((project
+                       (modelVersion "4.0.0")
+                       (name "QDox")
+                       (groupId "com.thoughtworks.qdox")
+                       (artifactId "qdox")
+                       (version ,,version))))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (home-page "https://github.com/codehaus/qdox")
     (synopsis "Parse definitions from Java source files")
     (description "QDox is a high speed, small footprint parser for extracting
@@ -3415,6 +3583,23 @@ class/interface/method definitions from source files complete with JavaDoc
 documentation tools.")
     (license license:asl2.0)))
 
+(define-public java-qdox-2-M9
+  (package
+    (inherit java-qdox)
+    (version "2.0-M9"); required by plexus-java
+    (source (origin
+              (method url-fetch)
+              ;; 2.0-M4, -M5 at https://github.com/paul-hammant/qdox
+              ;; Older releases at https://github.com/codehaus/qdox/
+              ;; Note: The release at maven is pre-generated. The release at
+              ;; github requires jflex.
+              (uri (string-append "https://repo1.maven.org/maven2/"
+                                  "com/thoughtworks/qdox/qdox/" version
+                                  "/qdox-" version "-sources.jar"))
+              (sha256
+               (base32
+                "1s2jnmx2dkwnaha12lcj26aynywgwa8sslc47z82wx8xai13y4fg"))))))
+
 (define-public java-jarjar
   (package
     (name "java-jarjar")
@@ -3431,10 +3616,10 @@ documentation tools.")
               (snippet
                '(begin
                   ;; Delete bundled thirds-party jar archives.
-                  ;; TODO: unbundle maven-plugin-api.
-                  (delete-file "lib/asm-4.0.jar")
-                  (delete-file "lib/asm-commons-4.0.jar")
-                  (delete-file "lib/junit-4.8.1.jar")
+                  (delete-file-recursively "lib")
+                  (delete-file "src/test/enumtest.jar")
+                  ;; the CLASSPATH needs this directory, create an empty one
+                  (mkdir-p "lib")
                   #t))))
     (build-system ant-build-system)
     (arguments
@@ -3449,11 +3634,11 @@ documentation tools.")
                (("<path id=\"path.build\">")
                 (string-append "<path id=\"path.build\"><fileset dir=\""
                                (assoc-ref inputs "java-asm-bootstrap")
-                               "/share/java\" includes=\"**/*.jar\"/>"))
+                               "/lib/m2\" includes=\"**/*.jar\"/>"))
                (("<zipfileset src=\"lib/asm-4.0.jar\"/>") "")
                (("lib/asm-commons-4.0.jar")
-                (string-append (assoc-ref inputs "java-asm-bootstrap")
-                               "/share/java/asm-6.0.jar"))
+                (car (find-files (assoc-ref inputs "java-asm-bootstrap")
+                                 "asm-6.0.jar")))
                (("<include name=\"org/objectweb/asm/commons/Remap\\*\\.class\"/>")
                 (string-append "<include name=\"org/objectweb/asm/"
                                "commons/Remap*.class\"/>"
@@ -3463,6 +3648,13 @@ documentation tools.")
                                "<include name=\"org/objectweb/asm/"
                                "commons/SignatureRemapper.class\"/>")))
              #t))
+         (add-before 'build 'remove-maven-dependency
+           (lambda _
+             ;; We do not need to build jarjar as a maven plugin just yet, so
+             ;; remove this file.  Maven requires jarjar (but not that plugin),
+             ;; so removing it improves the bootstrap.
+             (delete-file "src/main/com/tonicsystems/jarjar/JarJarMojo.java")
+             #t))
          (replace 'install
            (lambda* (#:key outputs #:allow-other-keys)
              (let ((target (string-append (assoc-ref outputs "out")
@@ -3505,6 +3697,7 @@ an Ant task that extends the built-in @code{jar} task.")
     (arguments
      `(#:tests? #f ; Tests require junit
        #:modules ((guix build ant-build-system)
+                  (guix build java-utils)
                   (guix build utils)
                   (srfi srfi-1))
        #:make-flags (list (string-append "-Dversion=" ,version))
@@ -3558,28 +3751,18 @@ private Method[] allMethods = getSortedMethods();")))
            (lambda _
              (mkdir-p "lib/integration")
              #t))
+         (add-before 'build 'create-pom
+           (lambda _
+             (substitute* "pom/hamcrest-core.pom"
+               (("@VERSION@") ,version))
+             #t))
          (replace 'install
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let* ((target (string-append (assoc-ref outputs "out")
-                                           "/share/java/"))
-                    (version-suffix ,(string-append "-" version ".jar"))
-                    (install-without-version-suffix
-                     (lambda (jar)
-                       (copy-file jar
-                                  (string-append target
-                                                 (basename jar version-suffix)
-                                                 ".jar")))))
-               (mkdir-p target)
-               (for-each
-                install-without-version-suffix
-                (find-files "build"
-                            (lambda (name _)
-                              (and (string-suffix? ".jar" name)
-                                   (not (string-suffix? "-sources.jar" name)))))))
-             #t)))))
+           (install-from-pom "pom/hamcrest-core.pom")))))
     (native-inputs
      `(("java-qdox-1.12" ,java-qdox-1.12)
        ("java-jarjar" ,java-jarjar)))
+    (propagated-inputs
+     `(("java-hamcrest-parent-pom" ,java-hamcrest-parent-pom)))
     (home-page "http://hamcrest.org/")
     (synopsis "Library of matchers for building test expressions")
     (description
@@ -3589,6 +3772,52 @@ declaratively, to be used in other frameworks.  Typical scenarios include
 testing frameworks, mocking libraries and UI validation rules.")
     (license license:bsd-2)))
 
+(define java-hamcrest-parent-pom
+  (package
+    (inherit java-hamcrest-core)
+    (name "java-hamcrest-parent-pom")
+    (propagated-inputs '())
+    (native-inputs '())
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (replace 'build
+           (lambda _
+             (substitute* "pom/hamcrest-parent.pom"
+               (("@VERSION@") ,(package-version java-hamcrest-core)))
+             #t))
+         (replace 'install
+           (install-pom-file "pom/hamcrest-parent.pom")))))))
+
+(define-public java-hamcrest-library
+  (package
+    (inherit java-hamcrest-core)
+    (name "java-hamcrest-library")
+    (arguments
+     (substitute-keyword-arguments (package-arguments java-hamcrest-core)
+      ((#:build-target _) "library")
+      ((#:phases phases)
+       `(modify-phases ,phases
+          (add-after 'unpack 'patch-classpath-for-integration
+            (lambda* (#:key inputs #:allow-other-keys)
+              (substitute* "build.xml"
+                (("build/hamcrest-core-\\$\\{version\\}\\.jar")
+                 (car (find-files (assoc-ref inputs "java-hamcrest-core")
+                                  "jar$"))))
+              #t))
+          (replace 'create-pom
+            (lambda _
+             (substitute* "pom/hamcrest-library.pom"
+               (("@VERSION@") ,(package-version java-hamcrest-core)))
+              #t))
+          (replace 'install
+            (install-from-pom "pom/hamcrest-library.pom"))))))
+    (propagated-inputs
+     `(("java-hamcrest-core" ,java-hamcrest-core)
+       ("java-hamcrest-parent-pom" ,java-hamcrest-parent-pom)))))
+
 (define-public java-junit
   (package
     (name "java-junit")
@@ -3610,10 +3839,23 @@ testing frameworks, mocking libraries and UI validation rules.")
                   #t))))
     (build-system ant-build-system)
     (arguments
-     `(#:tests? #f ; no tests
-       #:jar-name "junit.jar"))
-    (inputs
+     `(#:jar-name "junit.jar"
+       #:source-dir "src/main/java"
+       #:test-dir "src/test"
+       #:test-exclude (list "**/SimpleTest.java" "**/StackTracesTest.java"
+                            "**/RuleChainTest.java" "**/TestWatchmanTest.java")
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'check 'copy-test-resources
+           (lambda _
+             (copy-recursively "src/test/resources" "build/test-classes")
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
+    (propagated-inputs
      `(("java-hamcrest-core" ,java-hamcrest-core)))
+    (native-inputs
+     `(("java-hamcrest-library" ,java-hamcrest-library)))
     (home-page "https://junit.org/junit4/")
     (synopsis "Test framework for Java")
     (description
@@ -3622,10 +3864,42 @@ JUnit provides assertions for testing expected results, test fixtures for
 sharing common test data, and test runners for running tests.")
     (license license:epl1.0)))
 
+(define-public java-junitparams
+  (package
+    (name "java-junitparams")
+    (version "1.1.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/Pragmatists/JUnitParams")
+                     (commit (string-append "JUnitParams-" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0rb52xdfp99invyjrras3w0bf0a81cz30yd47rkkiyqcqj0y1q9b"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "junitparams.jar"
+       #:source-dir "src/main/java"
+       #:test-dir "src/test"
+       #:test-exclude (list "**/SuperclassTest.java")))
+    (inputs
+     `(("java-junit" ,java-junit)))
+    (native-inputs
+     `(("java-junit" ,java-junit)
+       ("java-hamcrest-core" ,java-hamcrest-core)
+       ("java-assertj" ,java-assertj)))
+    (home-page "https://github.com/Pragmatists/JUnitParams")
+    (synopsis "Parameterised test support for JUnit")
+    (description "The JUnitParams project adds a new runner to JUnit and
+provides much easier and readable parametrised tests for JUnit.")
+    (license license:asl2.0)))
+
 (define-public java-plexus-utils
   (package
     (name "java-plexus-utils")
-    (version "3.2.0")
+    ;; sisu-build-api needs this version, later versions don't work
+    (version "3.2.1")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -3634,7 +3908,7 @@ sharing common test data, and test runners for running tests.")
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1mlx7xrq7lgqjqcpg7y4hi1ghavf28vvk3har82037dqx61n0f15"))))
+                "1w169glixyk94jbczj8jzg897lsab46jihiaa3dhw0p06g35va8b"))))
     (build-system ant-build-system)
     ;; FIXME: The default build.xml does not include a target to install
     ;; javadoc files.
@@ -3664,11 +3938,21 @@ cli/shell/BourneShell.java"
 
                ;; FIXME: The command line tests fail, maybe because they use
                ;; absolute paths.
-               (delete-file "cli/CommandlineTest.java"))
-             #t)))))
+               (delete-file "cli/CommandlineTest.java")
+
+               ;; These tests require openjdk jmh, which is not packaged yet
+               (for-each delete-file (find-files "." "PerfTest.java$")))
+             #t))
+         (add-before 'build 'copy-resources
+           (lambda _
+             (copy-recursively "src/main/resources" "build/classes")
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
     (native-inputs
      `(("java-hamcrest-core" ,java-hamcrest-core)
        ("java-junit" ,java-junit)))
+    (propagated-inputs
+     `(("plexus-parent-pom" ,plexus-parent-pom-5.1)))
     (home-page "https://codehaus-plexus.github.io/plexus-utils/")
     (synopsis "Common utilities for the Plexus framework")
     (description "This package provides various Java utility classes for the
@@ -3676,10 +3960,24 @@ Plexus framework to ease working with strings, files, command lines, XML and
 more.")
     (license license:asl2.0)))
 
+(define-public java-plexus-utils-3.3.0
+  (package
+    (inherit java-plexus-utils)
+    (version "3.3.0")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/codehaus-plexus/plexus-utils")
+                     (commit (string-append "plexus-utils-" version))))
+              (file-name (git-file-name "java-plexus-utils" version))
+              (sha256
+               (base32
+                "0d0fq21rzjy0j55kcp8w9k1rbq9rwr0r7cc8239p9jbz54vihp0g"))))))
+
 (define-public java-plexus-interpolation
   (package
     (name "java-plexus-interpolation")
-    (version "1.23")
+    (version "1.26")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -3688,11 +3986,16 @@ more.")
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "005hxxg1adv71a96lz4vp65bk3v1pi76j4c45z29xzizclib16vl"))))
+                "1rahjmhywf6d5m32qzlc9izawyvcd71abfm9k03f13rs2xmfxzlh"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "plexus-interpolation.jar"
-       #:source-dir "src/main"))
+       #:source-dir "src/main"
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("plexus-parent-pom-5.1" ,plexus-parent-pom-5.1)))
     (native-inputs
      `(("java-junit" ,java-junit)
        ("java-hamcrest-core" ,java-hamcrest-core)))
@@ -3710,7 +4013,7 @@ these two libraries to vary independently of one another.")
 (define-public java-plexus-classworlds
   (package
     (name "java-plexus-classworlds")
-    (version "2.5.2")
+    (version "2.6.0")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -3719,12 +4022,17 @@ these two libraries to vary independently of one another.")
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1iv8x55fbni2hg4l7pdpbwfq75xmvq1f25g6nxma8rcdpihsh13r"))))
+                "034k2hgvj1saalwbnzrbg4n0zgzwcpz1lhlb8q4kgglsp9pmm03s"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "plexus-classworlds.jar"
        #:source-dir "src/main"
-       #:tests? #f));; FIXME: we need to generate some resources as in pom.xml
+       #:tests? #f;; FIXME: we need to generate some resources as in pom.xml
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("plexus-parent-pom-5.1" ,plexus-parent-pom-5.1)))
     (native-inputs
      `(("java-junit" ,java-junit)))
     (home-page "https://codehaus-plexus.github.io/plexus-classworlds/")
@@ -3752,22 +4060,31 @@ components.")
      `(#:jar-name "container-default.jar"
        #:source-dir "plexus-container-default/src/main/java"
        #:test-dir "plexus-container-default/src/test"
-       #:jdk ,icedtea-8
        #:tests? #f; requires plexus-archiver, which depends on this package
        #:phases
        (modify-phases %standard-phases
+         (add-before 'build 'fix-google-collections
+           (lambda _
+             ;; Google collections are now replaced with guava
+             (substitute* "plexus-container-default/pom.xml"
+               (("google-collections") "guava")
+               (("com.google.collections") "com.google.guava"))
+             #t))
          (add-before 'build 'copy-resources
            (lambda _
              (copy-recursively
                "plexus-container-default/src/main/resources/"
                "build/classes")
-             #t)))))
-    (inputs
-     `(("worldclass" ,java-plexus-classworlds)
-       ("xbean" ,java-geronimo-xbean-reflect)
-       ("utils" ,java-plexus-utils)
-       ("junit" ,java-junit)
-       ("guava" ,java-guava)))
+             #t))
+         (replace 'install
+           (install-from-pom "plexus-container-default/pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-worldclass" ,java-plexus-classworlds)
+       ("java-geronimo-xbean-reflect" ,java-geronimo-xbean-reflect)
+       ("java-plexus-utils" ,java-plexus-utils)
+       ("java-junit" ,java-junit)
+       ("java-guava" ,java-guava)
+       ("java-plexus-containers-parent-pom" ,java-plexus-containers-parent-pom)))
     (home-page "https://github.com/codehaus-plexus/plexus-containers")
     (synopsis "Inversion-of-control container")
     (description "Plexus-default-container is Plexus' inversion-of-control
@@ -3775,10 +4092,25 @@ components.")
 implementation.")
     (license license:asl2.0)))
 
+(define java-plexus-containers-parent-pom
+  (package
+    (inherit java-plexus-container-default-bootstrap)
+    (name "java-plexus-containers-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("plexus-parent-pom" ,plexus-parent-pom-4.0)))))
+
 (define-public java-plexus-io
   (package
     (name "java-plexus-io")
-    (version "3.0.0")
+    (version "3.2.0")
     (source (origin
               (method git-fetch)
               (uri (git-reference
@@ -3787,25 +4119,28 @@ implementation.")
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "1h4q9l2j9sfbscvxpnyy2hazi0r83h3am86y4r959wrl1b24xxwd"))))
+                "1r3wqfpbxq8vp4p914i8p88r0994rmcjw02hz14n11cfb6gsyvlr"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "plexus-io.jar"
        #:source-dir "src/main/java"
        #:test-dir "src/test"
-       #:jdk ,icedtea-8
        #:phases
        (modify-phases %standard-phases
          (add-before 'build 'copy-resources
            (lambda _
-             (mkdir-p "build/classes/META-INF/plexus")
-             (copy-file "src/main/resources/META-INF/plexus/components.xml"
-                        "build/classes/META-INF/plexus/components.xml")
-             #t)))))
+             (mkdir-p "build/classes")
+             (copy-recursively "src/main/resources" "build/classes")
+             (mkdir-p "build/test-classes")
+             (copy-recursively "src/test/resources" "build/test-classes")
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-utils" ,java-plexus-utils-3.3.0)
+       ("java-commons-io" ,java-commons-io)
+       ("plexus-parent-pom" ,plexus-parent-pom-5.1)))
     (inputs
-     `(("utils" ,java-plexus-utils)
-       ("commons-io" ,java-commons-io)
-       ("java-jsr305" ,java-jsr305)))
+     `(("java-jsr305" ,java-jsr305)))
     (native-inputs
      `(("junit" ,java-junit)
        ("hamcrest" ,java-hamcrest-core)
@@ -3823,19 +4158,18 @@ reusing it in maven.")
 (define-public java-plexus-archiver
   (package
     (name "java-plexus-archiver")
-    (version "4.1.0")
+    (version "4.2.2")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://github.com/codehaus-plexus/plexus-archiver"
                                   "/archive/plexus-archiver-" version ".tar.gz"))
               (sha256
                (base32
-                "0ry6i92gli0mvdmfih2vgs0lkf9yvx18h2ajxim66yg6yipnp0hg"))))
+                "144n971r3lfrx3l12nf2scm80x4xdvgbkk4bjpa4vcvvdrll6qys"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "plexus-archiver.jar"
        #:source-dir "src/main/java"
-       #:jdk ,icedtea-8
        #:test-dir "src/test"
        #:test-exclude (list "**/Abstract*.java" "**/Base*.java")
        #:phases
@@ -3853,25 +4187,28 @@ reusing it in maven.")
              #t))
          (add-before 'build 'copy-resources
            (lambda _
-             (mkdir-p "build/classes/META-INF/plexus")
-             (copy-file "src/main/resources/META-INF/plexus/components.xml"
-                        "build/classes/META-INF/plexus/components.xml")
-             #t)))))
+             (mkdir-p "build/classes")
+             (copy-recursively "src/main/resources" "build/classes")
+             (mkdir-p "build/test-classes")
+             (copy-recursively "src/test/resources" "build/test-classes")
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-utils" ,java-plexus-utils-3.3.0)
+       ("java-plexus-io" ,java-plexus-io)
+       ("java-iq80-snappy" ,java-iq80-snappy)
+       ("java-commons-compress" ,java-commons-compress)
+       ("plexus-parent-pom" ,plexus-parent-pom-6.1)))
     (inputs
-     `(("utils" ,java-plexus-utils)
-       ("commons-io" ,java-commons-io)
-       ("snappy" ,java-iq80-snappy)
-       ("io" ,java-plexus-io)
-       ("compress" ,java-commons-compress)
-       ("container-default" ,java-plexus-container-default-bootstrap)
-       ("snappy" ,java-snappy)
-       ("java-jsr305" ,java-jsr305)))
+     `(("java-jsr305" ,java-jsr305)
+       ("java-plexus-container-default"
+        ,java-plexus-container-default-bootstrap)))
     (native-inputs
      `(("java-hamcrest-core" ,java-hamcrest-core)
        ("junit" ,java-junit)
        ("classworld" ,java-plexus-classworlds)
        ("xbean" ,java-geronimo-xbean-reflect)
-       ("xz" ,java-tukaani-xz)
+       ("xz" ,java-xz)
        ("guava" ,java-guava)))
     (home-page "https://github.com/codehaus-plexus/plexus-archiver")
     (synopsis "Archiver component of the Plexus project")
@@ -3894,9 +4231,15 @@ archives (jar).")
                             ;; Failures
                             "**/ComponentRealmCompositionTest.java"
                             "**/PlexusContainerTest.java")
-       #:jdk ,icedtea-8
        #:phases
        (modify-phases %standard-phases
+         (add-before 'build 'fix-google-collections
+           (lambda _
+             ;; Google collections are now replaced with guava
+             (substitute* "plexus-container-default/pom.xml"
+               (("google-collections") "guava")
+               (("com.google.collections") "com.google.guava"))
+             #t))
          (add-before 'build 'copy-resources
            (lambda _
              (copy-recursively
@@ -3911,7 +4254,9 @@ archives (jar).")
                    dir "/plexus/component/composition/"
                    "ComponentRealmCompositionTest.java")
                  (("src/test") "plexus-container-default/src/test"))
-               #t))))))
+               #t)))
+         (replace 'install
+           (install-from-pom "plexus-container-default/pom.xml")))))
     (inputs
      `(("worldclass" ,java-plexus-classworlds)
        ("xbean" ,java-geronimo-xbean-reflect)
@@ -3929,13 +4274,64 @@ archives (jar).")
     (arguments
      `(#:jar-name "plexus-component-annotations.jar"
        #:source-dir "plexus-component-annotations/src/main/java"
-       #:tests? #f)); no tests
+       #:tests? #f; no tests
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "plexus-component-annotations/pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-containers-parent-pom" ,java-plexus-containers-parent-pom)))
     (inputs '())
     (native-inputs '())
     (synopsis "Plexus descriptors generator")
     (description "This package is a Maven plugin to generate Plexus descriptors
 from source tags and class annotations.")))
 
+(define-public java-plexus-component-metadata
+  (package
+    (inherit java-plexus-container-default)
+    (name "java-plexus-component-metadata")
+    (arguments
+     `(#:jar-name "plexus-component-metadata.jar"
+       #:source-dir "src/main/java"
+       #:test-dir "src/test"
+       #:jdk ,icedtea-8
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'chdir
+           (lambda _
+             (chdir "plexus-component-metadata")
+             #t))
+         (add-before 'build 'copy-resources
+           (lambda _
+             (copy-recursively "src/main/resources"
+                               "build/classes/")
+             #t)))))
+    (propagated-inputs
+     `(("java-plexus-container-default" ,java-plexus-container-default)
+       ("java-plexu-component-annotations" ,java-plexus-component-annotations)
+       ("java-plexus-utils" ,java-plexus-utils)
+       ("java-plexus-cli" ,java-plexus-cli)
+       ("java-plexus-classworlds" ,java-plexus-classworlds)
+       ("maven-plugin-api" ,maven-plugin-api)
+       ("maven-plugin-annotations" ,maven-plugin-annotations)
+       ("maven-core-bootstrap" ,maven-core-bootstrap)
+       ("maven-model" ,maven-model)
+       ("java-commons-cli" ,java-commons-cli)
+       ("java-qdox" ,java-qdox)
+       ("java-jdom2" ,java-jdom2)
+       ("java-asm" ,java-asm)))
+    (native-inputs
+     `(("java-junit" ,java-junit)
+       ("java-guava" ,java-guava)
+       ("java-geronimo-xbean-reflect" ,java-geronimo-xbean-reflect)))
+    (synopsis "Inversion-of-control container for Maven")
+    (description "The Plexus project provides a full software stack for creating
+and executing software projects.  Based on the Plexus container, the
+applications can utilise component-oriented programming to build modular,
+reusable components that can easily be assembled and reused.  This package
+provides the Maven plugin generating the component metadata.")))
+
 (define-public java-plexus-cipher
   (package
     (name "java-plexus-cipher")
@@ -3953,7 +4349,6 @@ from source tags and class annotations.")))
     (arguments
      `(#:jar-name "plexus-cipher.jar"
        #:source-dir "src/main/java"
-       #:jdk ,icedtea-8
        #:tests? #f; FIXME: requires sisu-inject-bean
        #:phases
        (modify-phases %standard-phases
@@ -3964,16 +4359,83 @@ from source tags and class annotations.")))
              (with-output-to-file "build/classes/META-INF/sisu/javax.inject.Named"
                (lambda _
                  (display "org.sonatype.plexus.components.cipher.DefaultPlexusCipher\n")))
-             #t)))))
+             #t))
+         (add-before 'install 'fix-test-dependency
+           (lambda _
+             ;; sisu-inject-bean is only used for tests, but its scope is "provided".
+             (substitute* "pom.xml"
+               (("provided") "test"))
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
     (inputs
      `(("java-cdi-api" ,java-cdi-api)
        ("java-javax-inject" ,java-javax-inject)))
+    (propagated-inputs
+     `(("java-sonatype-spice-parent-pom" ,java-sonatype-spice-parent-pom-15)))
+    (native-inputs
+     `(("java-junit" ,java-junit)))
     (home-page "https://github.com/sonatype/plexus-cipher")
     (synopsis "Encryption/decryption Component")
     (description "Plexus-cipher contains a component to deal with encryption
 and decryption.")
     (license license:asl2.0)))
 
+(define-public java-plexus-java
+  (package
+    (name "java-plexus-java")
+    (version "0.9.10")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/codehaus-plexus/plexus-languages")
+                     (commit (string-append "plexus-languages-" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0vmvgq5hfxs90yyxgssfpwq78l7vwx1ljwpkk594mrdr8sm668b5"))
+              (modules '((guix build utils)))
+              (snippet
+               `(begin
+                  (for-each delete-file (find-files "." ".*.jar$"))
+                  #t))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "plexus-java.java"
+       #:source-dir "plexus-java/src/main/java"
+       #:test-dir "plexus-java/src/test"
+       #:tests? #f; require mockito 2
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'generate-metadata
+           (lambda _
+             (invoke "java" "-cp" (string-append (getenv "CLASSPATH") ":build/classes")
+                     "org.codehaus.plexus.metadata.PlexusMetadataGeneratorCli"
+                     "--source" "plexus-java/src/main/java"
+                     "--output" "build/classes/META-INF/plexus/components.xml"
+                     "--classes" "build/classes"
+                     "--descriptors" "build/classes/META-INF")
+             (invoke "ant" "jar")
+             #t))
+         (add-before 'install 'install-parent
+           (install-pom-file "pom.xml"))
+         (replace 'install
+           (install-from-pom "plexus-java/pom.xml")))))
+    (propagated-inputs
+     `(("java-asm" ,java-asm)
+       ("java-qdox" ,java-qdox-2-M9)
+       ("java-javax-inject" ,java-javax-inject)
+       ("plexus-parent-pom" ,plexus-parent-pom-4.0)))
+    (inputs
+     `(("java-plexus-component-annotations" ,java-plexus-component-annotations)))
+    (native-inputs
+     `(("java-plexus-component-metadata" ,java-plexus-component-metadata)
+       ("java-junit" ,java-junit)))
+    (home-page "https://codehaus-plexus.github.io/plexus-languages/plexus-java")
+    (synopsis "Shared language features for Java")
+    (description "This package contains shared language features of the Java
+language, for the plexus project.")
+    (license license:asl2.0)))
+
 (define-public java-plexus-compiler-api
   (package
     (name "java-plexus-compiler-api")
@@ -3991,10 +4453,14 @@ and decryption.")
     (arguments
      `(#:jar-name "plexus-compiler-api.jar"
        #:source-dir "plexus-compiler-api/src/main/java"
-       #:jdk ,icedtea-8
-       #:test-dir "plexus-compiler-api/src/test"))
-    (inputs
+       #:test-dir "plexus-compiler-api/src/test"
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "plexus-compiler-api/pom.xml")))))
+    (propagated-inputs
      `(("java-plexus-container-default" ,java-plexus-container-default)
+       ("java-plexus-compiler-pom" ,java-plexus-compiler-pom)
        ("java-plexus-util" ,java-plexus-utils)))
     (native-inputs
      `(("java-junit" ,java-junit)))
@@ -4005,6 +4471,91 @@ compilers.")
     (license (list license:asl2.0
                    license:expat))))
 
+(define java-plexus-compiler-pom
+  (package
+    (inherit java-plexus-compiler-api)
+    (name "java-plexus-compiler-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml"))
+         (add-after 'install 'install-compilers
+           (install-pom-file "plexus-compilers/pom.xml")))))
+    (propagated-inputs
+     `(("plexus-components-parent-pom-4.0" ,plexus-components-parent-pom-4.0)))))
+
+(define plexus-components-parent-pom-4.0
+  (package
+    (name "plexus-components-parent-pom")
+    (version "4.0")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/codehaus-plexus/plexus-components")
+                     (commit (string-append "plexus-components-" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "041bm8yv0m2i17mqg8zljib4ykpha7ijls2qfdwvkma4d39lhysi"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+      `(("plexus-parent-pom-4.0" ,plexus-parent-pom-4.0)))
+    (home-page "https://codehaus-plexus.github.io/plexus-components")
+    (synopsis "Plexus parent pom")
+    (description "This package contains the Plexus components parent POM.")
+    (license license:asl2.0)))
+
+(define-public java-plexus-compiler-manager
+  (package
+    (inherit java-plexus-compiler-api)
+    (name "java-plexus-compiler-manager")
+    (arguments
+     `(#:jar-name "compiler-compiler-manager.java"
+       #:source-dir "plexus-compiler-manager/src/main/java"
+       #:test-dir "plexus-compiler-manager/src/test"
+       #:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'build 'generate-metadata
+           (lambda _
+             (invoke "java" "-cp" (string-append (getenv "CLASSPATH") ":build/classes")
+                     "org.codehaus.plexus.metadata.PlexusMetadataGeneratorCli"
+                     "--source" "plexus-compiler-manager/src/main/java"
+                     "--output" "build/classes/META-INF/plexus/components.xml"
+                     "--classes" "build/classes"
+                     "--descriptors" "build/classes/META-INF")
+             (invoke "ant" "jar")
+             #t))
+         (add-after 'generate-metadata 'rebuild
+           (lambda _
+             (invoke "ant" "jar")
+             #t))
+         (replace 'install
+           (install-from-pom "plexus-compiler-manager/pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-compiler-api" ,java-plexus-compiler-api)
+       ("java-plexus-compiler-pom" ,java-plexus-compiler-pom)
+       ("java-plexus-container-default" ,java-plexus-container-default)))
+    (native-inputs
+     `(("unzip" ,unzip)
+       ("java-plexus-component-metadata" ,java-plexus-component-metadata)))
+    (synopsis "Compiler management for Plexus Compiler component")
+    (description "Plexus Compiler is a Plexus component to use different
+compilers through a uniform API.  This component chooses the compiler
+implementation to use in a project.")))
+
 (define-public java-plexus-compiler-javac
   (package
     (inherit java-plexus-compiler-api)
@@ -4014,17 +4565,105 @@ compilers.")
        #:source-dir "plexus-compilers/plexus-compiler-javac/src/main/java"
        #:jdk ,icedtea-8
        #:tests? #f; depends on compiler-test -> maven-core -> ... -> this package.
-       #:test-dir "plexus-compilers/plexus-compiler-javac/src/test"))
-    (inputs
+       #:test-dir "plexus-compilers/plexus-compiler-javac/src/test"
+       #:modules ((guix build ant-build-system)
+                  (guix build utils)
+                  (guix build java-utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         ;; We cannot use java-plexus-component-metadata to generate the metadata
+         ;; because it ultimately depends on this package.
+         ;; Create it manually instead
+         (add-before 'build 'create-metadata
+           (lambda _
+             (let* ((dir "build/classes/META-INF/plexus")
+                    (file (string-append dir "/components.xml")))
+               (mkdir-p dir)
+               (with-output-to-file file
+                 (lambda _
+                   (sxml->xml
+                     `(component-set
+                        (components
+                          (component
+                            (role "org.codehaus.plexus.compiler.Compiler")
+                            (role-hint "javac")
+                            (implementation "org.codehaus.plexus.compiler.javac.JavacCompiler")
+                            (isolated-realm "false"))))))))
+             #t))
+         (replace 'install
+           (install-from-pom "plexus-compilers/plexus-compiler-javac/pom.xml")))))
+    (propagated-inputs
      `(("java-plexus-compiler-api" ,java-plexus-compiler-api)
        ("java-plexus-utils" ,java-plexus-utils)
        ("java-plexus-container-default" ,java-plexus-container-default)))
-    (native-inputs
-     `(("java-junit" ,java-junit)))
     (synopsis "Javac Compiler support for Plexus Compiler component")
     (description "This package contains the Javac Compiler support for Plexus
 Compiler component.")))
 
+(define plexus-components-pom-1.1.20
+  (package
+    (name "plexus-components-pom-1.1.20")
+    (version "1.1.20")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/codehaus-plexus/plexus-components")
+                     (commit (string-append "plexus-components-" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1q254k95m9icyfsvaw8c226midg8v6v436wvivhv7im825mnp5yb"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("plexus-parent-pom" ,plexus-parent-pom-3.1)))
+    (home-page "https://github.com/codehaus-plexus/plexus-components")
+    (synopsis "Maven parent pom for plexus packages")
+    (description "This package contains the parent pom for plexus component
+packages.")
+    (license license:asl2.0)))
+
+(define-public java-plexus-digest
+  (package
+    (name "java-plexus-digest")
+    (version "1.2")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/codehaus-plexus/plexus-digest")
+                     (commit "2a52ad1bda8297fa0e287163d2fa37245ec6a430")))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "19w5wxsliz8r42niry68qa665kvjsb8081dazg9vgd3pca72w07x"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "plexus-digest.jar"
+       #:source-dir "src/main/java"
+       #:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-utils" ,java-plexus-utils)
+       ("plexus-components-pom-1.1.20" ,plexus-components-pom-1.1.20)))
+    (native-inputs
+     `(("java-junit" ,java-junit)))
+    (home-page "https://github.com/codehaus-plexus/plexus-digest")
+    (synopsis "Hash function utilities for Java")
+    (description "This package is a plexus component that contains hash
+function utilities.")
+    (license license:asl2.0)))
+
 (define-public java-plexus-sec-dispatcher
   (package
     (name "java-plexus-sec-dispatcher")
@@ -4043,7 +4682,6 @@ Compiler component.")))
     (arguments
      `(#:jar-name "plexus-sec-dispatcher.jar"
        #:source-dir "src/main/java"
-       #:jdk ,icedtea-8
        #:phases
        (modify-phases %standard-phases
          (add-before 'build 'generate-models
@@ -4091,9 +4729,12 @@ Compiler component.")))
          (add-before 'check 'fix-paths
            (lambda _
              (copy-recursively "src/test/resources" "target")
-             #t)))))
-    (inputs
-     `(("java-plexus-cipher" ,java-plexus-cipher)))
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("java-plexus-utils" ,java-plexus-utils)
+       ("java-plexus-cipher" ,java-plexus-cipher)
+       ("java-sonatype-spice-parent-pom" ,java-sonatype-spice-parent-pom-12)))
     (native-inputs
      `(("java-modello-core" ,java-modello-core)
        ;; for modello:
@@ -4195,7 +4836,9 @@ which behaves as if all files were just created.</description>\n
     </component>\n
   </components>\n
 </component-set>\n")))
-             #t)))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (inputs
      `(("java-plexus-utils" ,java-plexus-utils)
        ("java-plexus-container-default" ,java-plexus-container-default)))
@@ -4241,7 +4884,7 @@ project and determining what files need to be rebuilt.")
                               "modello/core/io/ModelReaderTest.java")
                  (("src/test") "modello-core/src/test")))
              #t)))))
-    (inputs
+    (propagated-inputs
      `(("java-plexus-utils" ,java-plexus-utils)
        ("java-plexus-container-default" ,java-plexus-container-default)
        ("java-sisu-build-api" ,java-sisu-build-api)))
@@ -4290,8 +4933,7 @@ XSD and documentation.")
                                "build/classes")
              #t)))))
     (inputs
-     `(("java-modello-core" ,java-modello-core)
-       ,@(package-inputs java-modello-core)))
+     `(("java-modello-core" ,java-modello-core)))
     (synopsis "Modello Java Plugin")
     (description "Modello Java Plugin generates Java objects for the model.")))
 
@@ -4320,10 +4962,9 @@ XSD and documentation.")
                  "java/org/codehaus/modello/plugins/xml/XmlModelloPluginTest.java"
                  (("src/test") "modello-plugins/modello-plugin-xml/src/test")))
              #t)))))
-    (inputs
+    (propagated-inputs
      `(("java-modello-core" ,java-modello-core)
-       ("java-modello-plugins-java" ,java-modello-plugins-java)
-       ,@(package-inputs java-modello-core)))
+       ("java-modello-plugins-java" ,java-modello-plugins-java)))
     (synopsis "Modello XML Plugin")
     (description "Modello XML Plugin contains shared code for every plugins
 working on XML representation of the model.")))
@@ -4366,11 +5007,10 @@ every feature for every plugin.")))
              (copy-recursively "modello-plugins/modello-plugin-xpp3/src/main/resources"
                                "build/classes")
              #t)))))
-    (inputs
+    (propagated-inputs
      `(("java-modello-core" ,java-modello-core)
        ("java-modello-plugins-java" ,java-modello-plugins-java)
-       ("java-modello-plugins-xml" ,java-modello-plugins-xml)
-       ,@(package-inputs java-modello-core)))
+       ("java-modello-plugins-xml" ,java-modello-plugins-xml)))
     (native-inputs
      `(("java-xmlunit" ,java-xmlunit)
        ("java-modello-test" ,java-modello-test)
@@ -4391,9 +5031,6 @@ on the XPP3 API (XML Pull Parser).")))
                (base32
                 "115l5pqblirdkmzi32dxx7gbcm4jy0s14y5wircr6h8jdr9aix00"))))
     (build-system ant-build-system)
-    (propagated-inputs
-     `(("java-aqute-bndlib" ,java-aqute-bndlib)
-       ("java-aqute-libg" ,java-aqute-libg)))
     (arguments
      `(#:build-target "compile"
        ;; The tests require an old version of Janino, which no longer compiles
@@ -4410,6 +5047,12 @@ on the XPP3 API (XML Pull Parser).")))
         "-Dbiz.aQute.bnd.path=dummy-path")
        #:phases
        (modify-phases %standard-phases
+         (add-before 'build 'remove-bnd-dependency
+           (lambda _
+             ;; This file is the only one to require bnd, and is not needed
+             ;; because we don't build a bundle.
+             (delete-file "src/org/objectweb/asm/tools/ModuleInfoBndPlugin.java")
+             #t))
          (add-before 'install 'build-jars
            (lambda* (#:key make-flags #:allow-other-keys)
              ;; We cannot use the "jar" target because it depends on a couple
@@ -4418,10 +5061,19 @@ on the XPP3 API (XML Pull Parser).")))
              (invoke "jar"
                      "-cf" (string-append "dist/asm-" ,version ".jar")
                      "-C" "output/build/tmp" ".")))
+         (add-before 'install 'fix-pom
+           (lambda _
+             (substitute* (find-files "archive" "\\.pom$")
+               (("@product.artifact@") ,version))
+             #t))
+         (add-before 'install 'install-parent
+           (install-pom-file "archive/asm-parent.pom"))
          (replace 'install
-           (install-jars "dist")))))
+           (install-from-pom "archive/asm.pom")))))
     (native-inputs
      `(("java-junit" ,java-junit)))
+    (propagated-inputs
+     `(("java-org-ow2-parent-pom" ,java-org-ow2-parent-pom-1.3)))
     (home-page "https://asm.ow2.io/")
     (synopsis "Very small and fast Java bytecode manipulation framework")
     (description "ASM is an all purpose Java bytecode manipulation and
@@ -4431,6 +5083,32 @@ transformations and analysis algorithms allow easily assembling custom
 complex transformations and code analysis tools.")
     (license license:bsd-3)))
 
+(define java-org-ow2-parent-pom-1.3
+  (package
+    (name "java-org-ow2-parent-pom")
+    (version "1.3")
+    (source (origin
+              (method url-fetch)
+              (uri "https://repo1.maven.org/maven2/org/ow2/ow2/1.3/ow2-1.3.pom")
+              (sha256
+               (base32
+                "1yr8hfx8gffpppa4ii6cvrsq029a6x8hzy7nsavxhs60s9kmq8ai"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'unpack)
+         (delete 'build)
+         (delete 'configure)
+         (replace 'install
+           (install-pom-file (assoc-ref %build-inputs "source"))))))
+    (home-page "https://ow2.org")
+    (synopsis "Ow2.org parent pom")
+    (description "This package contains the parent pom for projects from ow2.org,
+including java-asm.")
+    (license license:lgpl2.1+)))
+
 (define java-asm-bootstrap
   (package
     (inherit java-asm)
@@ -4438,13 +5116,7 @@ complex transformations and code analysis tools.")
     (arguments
      (substitute-keyword-arguments (package-arguments java-asm)
        ((#:tests? _) #f)))
-    (native-inputs `())
-    (propagated-inputs
-     `(("java-aqute-bndlib" ,java-aqute-bndlib-bootstrap)
-       ("java-aqute-libg" ,java-aqute-libg-bootstrap)
-       ,@(delete `("java-aqute-bndlib" ,java-aqute-bndlib)
-                 (delete `("java-aqute-libg" ,java-aqute-libg)
-                         (package-inputs java-asm)))))))
+    (native-inputs `())))
 
 (define-public java-cglib
   (package
@@ -4454,7 +5126,7 @@ complex transformations and code analysis tools.")
      (origin
        (method git-fetch)
        (uri (git-reference
-             (url "https://github.com/cglib/cglib.git")
+             (url "https://github.com/cglib/cglib")
              (commit (string-append
                       "RELEASE_"
                       (string-map (lambda (c) (if (char=? c #\.) #\_ c))
@@ -4705,8 +5377,29 @@ The jMock library
                               (find-files (assoc-ref inputs "java-easymock") "\\.jar$")))
                        ";"))
                      (("build/hamcrest-core-\\$\\{version\\}\\.jar")
-                      (string-append (assoc-ref inputs "java-hamcrest-core")
-                                     "/share/java/hamcrest-core.jar")))
+                      (car (find-files (assoc-ref inputs "java-hamcrest-core")
+                                       "jar$"))))
+                   #t))
+               (replace 'install
+                 (lambda* (#:key outputs #:allow-other-keys)
+                   (let* ((target (string-append (assoc-ref outputs "out")
+                                                 "/share/java/"))
+                          (version-suffix
+                            ,(string-append
+                               "-" (package-version java-hamcrest-core) ".jar"))
+                          (install-without-version-suffix
+                           (lambda (jar)
+                             (copy-file jar
+                                        (string-append target
+                                                       (basename jar version-suffix)
+                                                       ".jar")))))
+                     (mkdir-p target)
+                     (for-each
+                      install-without-version-suffix
+                      (find-files "build"
+                                  (lambda (name _)
+                                    (and (string-suffix? ".jar" name)
+                                         (not (string-suffix? "-sources.jar" name)))))))
                    #t)))))))
     (inputs
      `(("java-junit" ,java-junit)
@@ -4766,9 +5459,10 @@ overly clever.")
        #:make-flags
        (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
              (junit    (assoc-ref %build-inputs "java-junit")))
-         (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
-               (string-append "-Dhamcrest.jar=" hamcrest
-                              "/share/java/hamcrest-core.jar")))
+         (list (string-append "-Djunit.jar="
+                              (car (find-files junit "jar$")))
+               (string-append "-Dhamcrest.jar="
+                              (car (find-files hamcrest ".*.jar$")))))
        #:phases
        (modify-phases %standard-phases
          ;; We want to build the jar in the build phase and run the tests
@@ -4855,9 +5549,10 @@ targeting the JVM.")
        (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
              (junit    (assoc-ref %build-inputs "java-junit"))
              (easymock (assoc-ref %build-inputs "java-easymock")))
-         (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
-               (string-append "-Dhamcrest.jar=" hamcrest
-                              "/share/java/hamcrest-core.jar")
+         (list (string-append "-Djunit.jar="
+                              (car (find-files junit "jar$")))
+               (string-append "-Dhamcrest.jar="
+                              (car (find-files hamcrest "jar$")))
                (string-append "-Deasymock.jar=" easymock
                               "/share/java/easymock.jar")))
        #:phases
@@ -4992,16 +5687,18 @@ setter and getter method.")
      `(#:test-target "test"
        #:make-flags
        (list (string-append "-Djunit.jar="
-                            (assoc-ref %build-inputs "java-junit")
-                            "/share/java/junit.jar"))
+                            (car (find-files (assoc-ref %build-inputs "java-junit")
+                                             "jar$"))))
        #:phases
        (modify-phases %standard-phases
          (add-after 'build 'build-javadoc ant-build-javadoc)
-         (replace 'install (install-jars "target"))
+         (replace 'install (install-from-pom "pom.xml"))
          (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
     (native-inputs
      `(("java-junit" ,java-junit)
        ("java-hamcrest-core" ,java-hamcrest-core)))
+    (propagated-inputs
+     `(("apache-commons-parent-pom" ,apache-commons-parent-pom-39)))
     (home-page "https://commons.apache.org/io/")
     (synopsis "Common useful IO related classes")
     (description "Commons-IO contains utility classes, stream implementations,
@@ -5025,8 +5722,8 @@ file filters and endian classes.")
      `(#:test-target "test"
        #:make-flags
        (list (string-append "-Dmaven.junit.jar="
-                            (assoc-ref %build-inputs "java-junit")
-                            "/share/java/junit.jar"))
+                            (car (find-files (assoc-ref %build-inputs "java-junit")
+                                             "jar$"))))
        #:phases
        (modify-phases %standard-phases
          (add-before 'build 'delete-network-tests
@@ -5061,8 +5758,8 @@ file filters and endian classes.")
      `(#:test-target "test"
        #:make-flags
        (list (string-append "-Dmaven.junit.jar="
-                            (assoc-ref %build-inputs "java-junit")
-                            "/share/java/junit.jar")
+                            (car (find-files (assoc-ref %build-inputs "java-junit")
+                                             "jar$")))
              "-Dmaven.compiler.source=1.7"
              "-Dmaven.compiler.target=1.7")
        #:phases
@@ -5146,42 +5843,24 @@ included:
 (define-public java-commons-lang3
   (package
     (name "java-commons-lang3")
-    (version "3.4")
+    (version "3.9")
     (source
      (origin
        (method url-fetch)
        (uri (string-append "mirror://apache/commons/lang/source/"
                            "commons-lang3-" version "-src.tar.gz"))
        (sha256
-        (base32 "0xpshb9spjhplq5a7mr0y1bgfw8190ik4xj8f569xidfcki1d6kg"))))
+        (base32 "0s4ffbvsyl16c90l45ximsg4dwd8hmz7wsza3p308fw43h6mwhb6"))))
     (build-system ant-build-system)
-    (outputs '("out" "doc"))
     (arguments
-     `(#:test-target "test"
-       #:make-flags
-       (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-all"))
-             (junit    (assoc-ref %build-inputs "java-junit"))
-             (easymock (assoc-ref %build-inputs "java-easymock"))
-             (io       (assoc-ref %build-inputs "java-commons-io")))
-         (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
-               (string-append "-Dhamcrest.jar=" hamcrest
-                              "/share/java/hamcrest-all.jar")
-               (string-append "-Dcommons-io.jar=" io
-                              "/share/java/commons-io-"
-                              ,(package-version java-commons-io)
-                              "-SNAPSHOT.jar")
-               (string-append "-Deasymock.jar=" easymock
-                              "/share/java/easymock.jar")))
+     `(#:jar-name "commons-lang3.jar"
+       #:source-dir "src/main/java"
+       #:tests? #f; require junit5
        #:phases
        (modify-phases %standard-phases
-         (add-after 'build 'build-javadoc ant-build-javadoc)
-         (replace 'install (install-jars "target"))
-         (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
-    (native-inputs
-     `(("java-junit" ,java-junit)
-       ("java-commons-io" ,java-commons-io)
-       ("java-hamcrest-all" ,java-hamcrest-all)
-       ("java-easymock" ,java-easymock)))
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("apache-commons-parent-pom" ,apache-commons-parent-pom-48)))
     (home-page "https://commons.apache.org/lang/")
     (synopsis "Extension of the java.lang package")
     (description "The Commons Lang components contains a set of Java classes
@@ -5424,7 +6103,28 @@ bottlenecks move away from the database in an effectively cached system.")
     (arguments
      `(#:tests? #f ; no tests included
        #:jdk ,icedtea-8
-       #:jar-name "jsr250.jar"))
+       #:jar-name "jsr250.jar"
+       #:modules ((guix build ant-build-system)
+                  (guix build utils)
+                  (guix build maven pom)
+                  (guix build java-utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'install 'create-pom
+           (lambda _
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `((project
+                       (modelVersion "4.0.0")
+                       (name "jsr250")
+                       (groupId "javax.annotation")
+                       (artifactId "jsr250-api")
+                       (version ,,version))))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (home-page "https://jcp.org/en/jsr/detail?id=250")
     (synopsis "Security-related annotations")
     (description "This package provides annotations for security.  It provides
@@ -5450,7 +6150,28 @@ namespaces.")
     (build-system ant-build-system)
     (arguments
      `(#:tests? #f ; no tests included
-       #:jar-name "jsr305.jar"))
+       #:jar-name "jsr305.jar"
+       #:modules ((guix build ant-build-system)
+                  (guix build java-utils)
+                  (guix build maven pom)
+                  (guix build utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'install 'create-pom
+           (lambda _
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `((project
+                       (modelVersion "4.0.0")
+                       (name "jsr305")
+                       (groupId "com.google.code.findbugs")
+                       (artifactId "jsr305")
+                       (version ,,version))))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (home-page "http://findbugs.sourceforge.net/")
     (synopsis "Annotations for the static analyzer called findbugs")
     (description "This package provides annotations for the findbugs package.
@@ -5463,22 +6184,24 @@ It provides packages in the @code{javax.annotations} namespace.")
     ;; This is the last release of Guava that can be built with Java 7.
     (version "20.0")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/google/guava/"
-                                  "releases/download/v" version
-                                  "/guava-" version "-sources.jar"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/google/guava/")
+                     (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
+                "00h5cawdjic1vind3yivzh1f58flvm1yfmhsyqwyvmbvj1vakysp"))))
     (build-system ant-build-system)
     (arguments
      `(#:tests? #f                      ; no tests included
        #:jar-name "guava.jar"
+       #:source-dir "guava/src"
        #:phases
        (modify-phases %standard-phases
          (add-after 'unpack 'trim-sources
            (lambda _
-             (with-directory-excursion "src/com/google/common"
+             (with-directory-excursion "guava/src/com/google/common"
                ;; Remove annotations to avoid extra dependencies:
                ;; * "j2objc" annotations are used when converting Java to
                ;;   Objective C;
@@ -5497,9 +6220,12 @@ It provides packages in the @code{javax.annotations} namespace.")
                  (("@ForOverride") "")
                  (("@J2ObjCIncompatible") "")
                  (("@IgnoreJRERequirement") "")))
-             #t)))))
+             #t))
+         (replace 'install (install-from-pom "guava/pom.xml")))))
     (inputs
      `(("java-jsr305" ,java-jsr305)))
+    (propagated-inputs
+     `(("java-guava-parent-pom" ,java-guava-parent-pom)))
     (home-page "https://github.com/google/guava")
     (synopsis "Google core libraries for Java")
     (description "Guava is a set of core libraries that includes new
@@ -5509,6 +6235,21 @@ concurrency, I/O, hashing, primitives, reflection, string processing, and much
 more!")
     (license license:asl2.0)))
 
+(define java-guava-parent-pom
+  (package
+    (inherit java-guava)
+    (name "java-guava-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("java-sonatype-oss-parent-pom" ,java-sonatype-oss-parent-pom-7)))))
+
 ;; The java-commons-logging package provides adapters to many different
 ;; logging frameworks.  To avoid an excessive dependency graph we try to build
 ;; it with only a minimal set of adapters.
@@ -5697,7 +6438,7 @@ an Apache AB clone based on HttpCore.")))
 (define-public java-httpcomponents-httpclient
   (package
     (name "java-httpcomponents-httpclient")
-    (version "4.5.3")
+    (version "4.5.12")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://apache/httpcomponents/httpclient/"
@@ -5705,7 +6446,7 @@ an Apache AB clone based on HttpCore.")))
                                   version "-src.tar.gz"))
               (sha256
                (base32
-                "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
+                "1va99m2zc2liv0v9vn72p5ja8yz4s5wq7zpahaai5nr966kvxzkb"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "httpcomponents-httpclient.jar"
@@ -5832,12 +6573,14 @@ programs.")
                ;; package at this point.
                ;; https://github.com/powermock/powermock
                (delete-file "archivers/sevenz/SevenZNativeHeapTest.java"))
-             #t)))))
-    (inputs
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
+    (propagated-inputs
+     `(("java-xz" ,java-xz)
+       ("apache-commons-parent-pom" ,apache-commons-parent-pom-41)))
+    (native-inputs
      `(("java-junit" ,java-junit)
-       ("java-hamcrest-core" ,java-hamcrest-core)
-       ("java-mockito" ,java-mockito-1)
-       ("java-xz" ,java-xz)))
+       ("java-mockito" ,java-mockito-1)))
     (home-page "https://commons.apache.org/proper/commons-compress/")
     (synopsis "Java library for working with compressed files")
     (description "The Apache Commons Compress library defines an API for
@@ -6691,7 +7434,11 @@ logging framework for Java.")))
     (build-system ant-build-system)
     ;; TODO: javadoc
     (arguments
-     `(#:jar-name "commons-cli.jar"))
+     `(#:jar-name "commons-cli.jar"
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (native-inputs
      `(("java-junit" ,java-junit)
        ("java-hamcrest-core" ,java-hamcrest-core)))
@@ -6717,34 +7464,38 @@ This is a part of the Apache Commons Project.")
 (define-public java-commons-codec
   (package
     (name "java-commons-codec")
-    (version "1.10")
+    (version "1.14")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://apache/commons/codec/source/"
                                   "commons-codec-" version "-src.tar.gz"))
               (sha256
                (base32
-                "1w9qg30y4s0x8gnmr2fgj4lyplfn788jqxbcz27lf5kbr6n8xr65"))))
+                "11xr0agckkhm91pb5akf2mbk84yd54gyr178wj57gsm97fi7nkh9"))))
     (build-system ant-build-system)
-    (outputs '("out" "doc"))
     (arguments
-     `(#:test-target "test"
-       #:make-flags
-       (let ((hamcrest (assoc-ref %build-inputs "java-hamcrest-core"))
-             (junit    (assoc-ref %build-inputs "java-junit")))
-         (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
-               (string-append "-Dhamcrest.jar=" hamcrest
-                              "/share/java/hamcrest-core.jar")
-               ;; Do not append version to jar.
-               "-Dfinal.name=commons-codec"))
+     `(#:jar-name "java-commons-codec.jar"
+       #:source-dir "src/main/java"
+       #:test-dir "src/test"
+       #:test-exclude (list "**/*AbstractTest.java")
        #:phases
        (modify-phases %standard-phases
-         (add-after 'build 'build-javadoc ant-build-javadoc)
-         (replace 'install (install-jars "dist"))
-         (add-after 'install 'install-doc (install-javadoc "dist/docs/api")))))
+         (add-before 'build 'copy-resources
+           (lambda _
+             (copy-recursively "src/main/resources"
+                               "build/classes")
+             #t))
+         (add-before 'check 'copy-test-resources
+           (lambda _
+             (copy-recursively "src/test/resources"
+                               "build/test-classes")
+             #t))
+         (replace 'install (install-from-pom "pom.xml")))))
     (native-inputs
-     `(("java-junit" ,java-junit)
-       ("java-hamcrest-core" ,java-hamcrest-core)))
+     `(("java-commons-lang3" ,java-commons-lang3)
+       ("java-junit" ,java-junit)))
+    (propagated-inputs
+      `(("apache-commons-parent-pom" ,apache-commons-parent-pom-50)))
     (home-page "https://commons.apache.org/codec/")
     (synopsis "Common encoders and decoders such as Base64, Hex, Phonetic and URLs")
     (description "The codec package contains simple encoder and decoders for
@@ -6860,8 +7611,12 @@ more efficient storage-wise than an uncompressed bitmap (as implemented in the
                 (string-append "<include name=\"**/*Test.java\" />"
                                "<exclude name=\"**/MultithreadedInitializationTest"
                                ".java\" />")))
-             #t)))))
-    (inputs
+             #t))
+         (replace 'install
+           (install-from-pom "slf4j-api/pom.xml")))))
+    (propagated-inputs
+     `(("java-slf4j-parent" ,java-slf4j-parent)))
+    (native-inputs
      `(("java-junit" ,java-junit)
        ("java-hamcrest-core" ,java-hamcrest-core)))
     (home-page "https://www.slf4j.org/")
@@ -6873,14 +7628,20 @@ allowing the end user to plug in the desired logging framework at deployment
 time.")
     (license license:expat)))
 
-(define java-slf4j-api-bootstrap
+(define java-slf4j-parent
   (package
     (inherit java-slf4j-api)
-    (name "java-slf4j-api-bootstrap")
-    (inputs `())
+    (name "java-slf4j-parent")
+    (native-inputs `())
+    (propagated-inputs '())
     (arguments
-     (substitute-keyword-arguments (package-arguments java-slf4j-api)
-       ((#:tests? _ #f) #f)))))
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'build)
+         (delete 'configure)
+         (replace 'install
+           (install-pom-file "pom.xml")))))))
 
 (define-public java-slf4j-simple
   (package
@@ -6903,11 +7664,14 @@ time.")
              ;; ... and build test helper classes here:
              (apply invoke
                     `("javac" "-d" "."
-                      ,@(find-files "slf4j-api/src/test" ".*\\.java"))))))))
-    (inputs
+                      ,@(find-files "slf4j-api/src/test" ".*\\.java")))))
+         (replace 'install
+           (install-from-pom "slf4j-simple/pom.xml")))))
+    (propagated-inputs
+     `(("java-slf4j-api" ,java-slf4j-api)))
+    (native-inputs
      `(("java-junit" ,java-junit)
-       ("java-hamcrest-core" ,java-hamcrest-core)
-       ("java-slf4j-api" ,java-slf4j-api)))
+       ("java-hamcrest-core" ,java-hamcrest-core)))
     (home-page "https://www.slf4j.org/")
     (synopsis "Simple implementation of simple logging facade for Java")
     (description "SLF4J binding for the Simple implementation, which outputs
@@ -7304,8 +8068,7 @@ import org.antlr.grammar.v2.ANTLRTreePrinter;"))
      `(("junit" ,java-junit)))
     (propagated-inputs
      `(("java-stringtemplate" ,java-stringtemplate-3)
-       ("antlr" ,antlr2)
-       ("antlr3" ,antlr3-3.1)))))
+       ("antlr" ,antlr2)))))
 
 (define-public antlr3-3.1
   (package
@@ -8166,20 +8929,6 @@ it manages project dependencies, gives diffs jars, and much more.")
      `(("hamcrest" ,java-hamcrest-core)
        ("java-junit" ,java-junit)))))
 
-(define java-aqute-libg-bootstrap
-  (package
-    (inherit java-aqute-libg)
-    (name "java-aqute-libg-bootstrap")
-    (arguments
-     ;; Disable tests, at this stage of bootstrap we have no test frameworks.
-     (substitute-keyword-arguments (package-arguments java-aqute-libg)
-       ((#:tests? _ #f) #f)))
-    (inputs
-     `(("slf4j-bootstrap" ,java-slf4j-api-bootstrap)
-       ,@(delete `("slf4j" ,java-slf4j-api)
-                 (package-inputs java-aqute-libg))))
-    (native-inputs '())))
-
 (define-public java-aqute-bndlib
   (package
     (inherit java-aqute-bnd-annotation)
@@ -8203,17 +8952,6 @@ it manages project dependencies, gives diffs jars, and much more.")
        ("promise" ,java-osgi-util-promise)
        ("osgi" ,java-osgi-core)))))
 
-(define java-aqute-bndlib-bootstrap
-  (package
-    (inherit java-aqute-bndlib)
-    (name "java-aqute-bndlib-bootstrap")
-    (inputs
-     `(("slf4j-bootstrap" ,java-slf4j-api-bootstrap)
-       ("java-aqute-libg-bootstrap" ,java-aqute-libg-bootstrap)
-       ,@(delete `("slf4j" ,java-slf4j-api)
-                 (delete `("java-aqute-libg" ,java-aqute-libg)
-                         (package-inputs java-aqute-bndlib)))))))
-
 (define-public java-ops4j-pax-tinybundles
   (package
     (name "java-ops4j-pax-tinybundles")
@@ -8841,7 +9579,7 @@ the subsequent value resolution at any given level.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/nhatminhle/cofoja.git")
+                    (url "https://github.com/nhatminhle/cofoja")
                     (commit (string-append "v" version))))
               (file-name (string-append "java-cofoja-" version "-checkout"))
               (sha256
@@ -8912,7 +9650,28 @@ this is not a static analysis tool.)")
      `(#:jar-name "java-aopalliance.jar"
        #:jdk ,icedtea-8
        #:tests? #f; no tests
-       #:source-dir "aopalliance/src/main"))
+       #:source-dir "aopalliance/src/main"
+       #:modules ((guix build ant-build-system)
+                  (guix build utils)
+                  (guix build maven pom)
+                  (guix build java-utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         (add-before 'install 'create-pom
+           (lambda _
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `((project
+                       (modelVersion "4.0.0")
+                       (name "aopalliance")
+                       (groupId "aopalliance")
+                       (artifactId "aopalliance")
+                       (version "1.0"))))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (home-page "http://aopalliance.sourceforge.net")
     (synopsis "Aspect-Oriented Programming")
     (description "The AOP Alliance project is a joint project between several
@@ -8923,20 +9682,25 @@ software engineering people who are interested in Aspect-Oriented Programming
 (define-public java-javax-inject
   (package
     (name "java-javax-inject")
-    (version "tck-1")
+    (version "1")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/javax-inject/javax-inject/"
-                                  "archive/javax.inject-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/javax-inject/javax-inject")
+                     (commit version)))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1ydrlvh2r7vr1g7lhjwy3w2dggpj9h6pix1lakkkgdywb365n6g0"))))
+                "1rspl0nkvk1jif6nccikw93xic6ljj2b6kpy2mffwi2mnvc13j7x"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-javax-inject.jar"
-       #:jdk ,icedtea-8
-       #:tests? #f)); no tests
-    (home-page "http://github.com/javax-inject/javax-inject")
+       #:tests? #f; no tests
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "pom.xml")))))
+    (home-page "https://github.com/javax-inject/javax-inject")
     (synopsis "JSR-330: Dependency Injection for Java")
     (description "This package specifies a means for obtaining objects in such
 a way as to maximize reusability, testability and maintainability compared to
@@ -8956,32 +9720,42 @@ the dependency is said to be unsatisfied, and the application is broken.")
     (name "java-guice")
     (version "4.1")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/google/guice/archive/"
-                                  version ".tar.gz"))
-              (file-name (string-append name "-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/google/guice")
+                     (commit version)))
+              (file-name (git-file-name name version))
               (modules '((guix build utils)))
               (snippet
                `(begin
-                  (for-each delete-file (find-files "." ".*.jar"))))
+                  (for-each delete-file (find-files "." ".*.jar")) #t))
               (sha256
                (base32
-                "0dwmqjzlavb144ywqqglj3h68hqszkff8ai0a42hyb5il0qh4rbp"))))
+                "18im5hdfl4q1b9chww2s1ii60sn3ydyyar32a2sf2p2g8zlbdswq"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-guice.jar"
        #:jdk ,icedtea-8
        #:tests? #f; FIXME: tests are not in a java sub directory
-       #:source-dir "core/src"))
-    (inputs
-     `(("guava" ,java-guava)
+       #:source-dir "core/src"
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'make-files-writable
+           (lambda _
+             (for-each make-file-writable (find-files "."))
+             #t))
+         (replace 'install
+           (install-from-pom "core/pom.xml")))))
+    (propagated-inputs
+     `(("java-aopalliance" ,java-aopalliance)
+       ("java-asm" ,java-asm)
        ("java-cglib" ,java-cglib)
-       ("java-aopalliance" ,java-aopalliance)
+       ("java-guava" ,java-guava)
        ("java-javax-inject" ,java-javax-inject)
-       ("java-asm" ,java-asm)))
+       ("java-guice-parent-pom" ,java-guice-parent-pom)))
     (home-page "https://github.com/google/guice")
     (synopsis "Lightweight dependency injection framework")
-    (description "Guice is a lightweight dependency injection framework fo
+    (description "Guice is a lightweight dependency injection framework for
 Java 6 and above.")
     (license license:asl2.0)))
 
@@ -8993,24 +9767,76 @@ Java 6 and above.")
      `(#:jar-name "guice-servlet.jar"
        #:source-dir "extensions/servlet/src/"
        #:jdk ,icedtea-8
-       #:tests? #f)); FIXME: not in a java subdir
+       #:tests? #f  ; FIXME: not in a java subdir
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'make-files-writable
+           (lambda _
+             (for-each make-file-writable (find-files "."))
+             #t)))))
     (inputs
      `(("guice" ,java-guice)
        ("servlet"  ,java-classpathx-servletapi)
        ,@(package-inputs java-guice)))))
 
+(define java-guice-parent-pom
+  (package
+    (inherit java-guice)
+    (name "java-guice-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (add-after 'install 'install-extensions
+           (install-pom-file "extensions/pom.xml"))
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("java-google-parent-pom" ,java-google-parent-pom-5)))))
+
+(define java-google-parent-pom-5
+  (package
+    (name "java-google-parent-pom")
+    (version "5")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/google/google-maven-parents")
+                     (commit (string-append "google-" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0zb7hx24p8k8rfdvix2vsbfqn73jhrycdndvhf8j5gbii9wbqibv"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (home-page "https://github.com/google/google-maven-parents")
+    (synopsis "Google parent pom")
+    (description "This package contains the Maven parent POM for other Google
+Java projects.")
+    (license license:asl2.0)))
+
 (define-public java-assertj
   (package
     (name "java-assertj")
     (version "3.8.0")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/joel-costigliola/"
-                                  "assertj-core/archive/"
-                                  "assertj-core-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/joel-costigliola/assertj-core")
+                     (commit (string-append "assertj-core-" version))))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1kf124fxskf548rklkg86294w2x6ajqrff94rrhyqns31danqkfz"))))
+                "1k35cg2in7pzk4pbdjryr0pll5lgk1r6ngrn0j8cdlgi7w8zh2d1"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-assertj.jar"
@@ -9035,14 +9861,22 @@ readability and make maintenance of tests easier.")
     (name "java-jboss-javassist")
     (version "3.21.0")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/jboss-javassist/javassist/"
-                                  "archive/rel_"
-                                  (string-map (lambda (x) (if (eq? x #\.) #\_ x)) version)
-                                  "_ga.tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/jboss-javassist/javassist")
+                     (commit
+                       (string-append "rel_"
+                                      (string-map
+                                        (lambda (x) (if (eq? x #\.) #\_ x)) version)
+                                      "_ga"))))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "10lpcr3sbf7y6fq6fc2h2ik7rqrivwcy4747bg0kxhwszil3cfmf"))))
+                "0h3zlcyqiaq01fspm69h7vki67raw305w89p4ha8vlhpzw02qifm"))
+              (modules '((guix build utils)))
+              (snippet
+               '(begin
+                  (delete-file "javassist.jar")))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-jboss-javassist.jar"
@@ -9051,9 +9885,9 @@ readability and make maintenance of tests easier.")
        #:tests? #f; FIXME: requires junit-awtui and junit-swingui from junit3
        #:phases
        (modify-phases %standard-phases
-         (add-before 'configure 'remove-binary
+         (add-after 'unpack 'make-files-writable
            (lambda _
-             (delete-file "javassist.jar")
+             (for-each make-file-writable (find-files "."))
              #t)))))
     (native-inputs
      `(("junit" ,java-junit)))
@@ -9070,13 +9904,14 @@ file when the JVM loads it.")
     (name "java-jcommander")
     (version "1.71")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/cbeust/jcommander/archive/"
-                                  version ".tar.gz"))
-              (file-name (string-append name "-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/cbeust/jcommander")
+                     (commit version)))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1f5k2ckay6qjc3d3w3d7bc0p3cx3c7n6p6zxvw1kibqdr0q98wlx"))))
+                "12vcpc19sd7jhvjgp7xz1qjanfix162xb3x2q5zah93rjklj1h57"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-jcommander.jar"
@@ -9095,25 +9930,42 @@ annotations.")
     (name "java-bsh")
     (version "2.0b6")
     (source (origin
-              (method url-fetch)
-              (uri (string-append "https://github.com/beanshell/beanshell/archive/"
-                                  version ".tar.gz"))
-              (file-name (string-append name "-" version ".tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/beanshell/beanshell")
+                     (commit version)))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1bawkxk6jyc75hxvzkpz689h73cn3f222m0ar3nvb0dal2b85kfv"))))
+                "0kz3f0xjack6c9syssi4qjw1rbd3q5963sk5pmr143hiibxa9csw"))
+              (modules '((guix build utils)))
+              (snippet
+               '(begin
+                  ;; Delete bundled third-party jar archives.
+                  (for-each delete-file (find-files "." ".*.jar$"))
+                  (for-each (lambda (file) (chmod file #o644))
+                            (find-files "." "."))
+                  #t))))
     (build-system ant-build-system)
     (arguments
      `(#:build-target "jarall"
        #:test-target "junit-tests-all"
+       #:make-flags (list "-DDATE" "(no date for reproducibility)")
        #:phases
        (modify-phases %standard-phases
+         (add-before 'install 'fix-pom
+           (lambda _
+             (substitute* "pom.xml"
+               (("org.apache-extras.beanshell") "org.beanshell"))
+             #t))
          (replace 'install
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let ((share (string-append (assoc-ref outputs "out") "/share/java")))
-               (mkdir-p share)
-               (copy-file "dist/bsh-2.0b6.jar" (string-append share "/bsh-2.0b6.jar"))
-               #t))))))
+           (install-from-pom "pom.xml")))))
+    (inputs
+     `(("java-classpathx-servletapi" ,java-classpathx-servletapi)
+       ("java-commons-bsf" ,java-commons-bsf)))
+    (native-inputs
+     `(("java-junit" ,java-junit)
+       ("javacc" ,javacc-3)))
     (home-page "http://beanshell.org/")
     (synopsis "Lightweight Scripting for Java")
     (description "BeanShell is a small, free, embeddable Java source
@@ -9219,7 +10071,7 @@ those in Perl and JavaScript.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/cbeust/testng.git")
+                    (url "https://github.com/cbeust/testng")
                     (commit version)))
               (file-name (string-append name "-" version "-checkout"))
               (sha256
@@ -9297,7 +10149,7 @@ to use.")
       (source (origin
                 (method git-fetch)
                 (uri (git-reference
-                      (url "https://github.com/neilalexander/jnacl.git")
+                      (url "https://github.com/neilalexander/jnacl")
                       (commit commit)))
                 (file-name (git-file-name name version))
                 (sha256
@@ -9880,7 +10732,7 @@ protocol-independent framework to build mail and messaging applications.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                    (url "https://github.com/zeromq/jeromq.git")
+                    (url "https://github.com/zeromq/jeromq")
                     (commit (string-append "v" version))))
               (file-name (string-append name "-" version "-checkout"))
               (sha256
@@ -10029,13 +10881,16 @@ outputting XML data from Java code.")
                ;; org.apache.xbean.asm6 is actually repackaged java-asm
                (substitute* (string-append dir "XbeanAsmParameterNameLoader.java")
                  (("org.apache.xbean.asm5") "org.objectweb.asm"))
-               #t))))))
+               #t)))
+         (replace 'install (install-from-pom "xbean-reflect/pom.xml")))))
     (inputs
      `(("asm" ,java-asm)
        ("log4j" ,java-log4j-api)
        ("log4j-1.2" ,java-log4j-1.2-api)
        ("log4j-core" ,java-log4j-core)
        ("logging" ,java-commons-logging-minimal)))
+    (propagated-inputs
+     `(("java-geronimo-parent-pom" ,java-geronimo-parent-pom)))
     (native-inputs
      `(("junit" ,java-junit)))
     (home-page "https://geronimo.apache.org/maven/xbean/3.6/xbean-reflect/")
@@ -10044,6 +10899,65 @@ outputting XML data from Java code.")
 and graphs of objects for dependency injection frameworks")
     (license license:asl2.0)))
 
+(define java-geronimo-genesis-2.1
+  (package
+    (name "java-geronimo-genesis")
+    (version "2.1")
+    (source (origin
+              (method svn-fetch)
+              (uri (svn-reference
+                     (url (string-append "https://svn.apache.org/repos/asf/"
+                                         "geronimo/genesis/tags/genesis-"
+                                         version))
+                     (revision 1807396)))
+              (file-name (string-append name "-" version "-source"))
+              (sha256
+               (base32
+                "119yn795jvnjf52si84q192s8wag1k013iabg78b7wnadssnnh31"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml"))
+         (add-after 'install 'install-enforcer-rules
+           (install-pom-file "genesis-enforcer-rules/pom.xml"))
+         (add-after 'install 'install-flava
+           (install-pom-file "genesis-default-flava/pom.xml"))
+         (add-after 'install 'install-packaging
+           (install-pom-file "genesis-packaging/pom.xml"))
+         (add-after 'install-flava 'install-flava-java4
+           (install-pom-file "genesis-default-flava/genesis-java1.4-flava/pom.xml"))
+         (add-after 'install-flava 'install-flava-java5
+           (install-pom-file "genesis-default-flava/genesis-java5-flava/pom.xml"))
+         (add-after 'install-flava 'install-flava-java6
+           (install-pom-file "genesis-default-flava/genesis-java6-flava/pom.xml")))))
+    (propagated-inputs
+     `(("apache-parent-pom" ,apache-parent-pom-13)))
+    (home-page "https://geronimo.apache.org")
+    (synopsis "Collection of maven POM files for the Geronimo project")
+    (description "Apache Geronimo is a server runtime.  This package contains
+only pom files used by other components in the Geronimo project.")
+    (license license:asl2.0)))
+
+(define java-geronimo-parent-pom
+  (package
+    (inherit java-geronimo-xbean-reflect)
+    (name "java-geronimo-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("java-geronimo-genesis" ,java-geronimo-genesis-2.1)))))
+
 (define-public java-geronimo-xbean-bundleutils
   (package
     (inherit java-geronimo-xbean-reflect)
@@ -10082,7 +10996,7 @@ public Bundle getBundle()"))
        ("java-osgi-framework" ,java-osgi-framework)
        ("java-eclipse-osgi" ,java-eclipse-osgi)
        ("java-osgi-service-packageadmin" ,java-osgi-service-packageadmin)))))
+
 (define-public java-geronimo-xbean-asm-util
   (package
     (inherit java-geronimo-xbean-reflect)
@@ -10094,7 +11008,7 @@ public Bundle getBundle()"))
     (inputs
      `(("java-asm" ,java-asm)))
     (native-inputs '())))
+
 (define-public java-geronimo-xbean-finder
   (package
     (inherit java-geronimo-xbean-reflect)
@@ -10178,7 +11092,11 @@ including pre-existing objects that you do not have source-code of.")
                (with-directory-excursion "hawtjni-generator/src/main/resources/"
                  (install-file "libhawtjni.so" lib)
                  (install-file "hawtjni.h" inc)))
-             #t)))))
+             #t))
+         (add-before 'install 'install-parent
+           (install-pom-file "pom.xml"))
+         (replace 'install
+           (install-from-pom "hawtjni-runtime/pom.xml")))))
     (inputs
      `(("java-commons-cli" ,java-commons-cli)
        ("java-asm" ,java-asm)
@@ -10237,8 +11155,16 @@ that is part of the SWT Tools project.")
            (lambda* (#:key outputs #:allow-other-keys)
              (install-file "src/main/native-package/src/jansi.h"
                            (string-append (assoc-ref outputs "out") "/include"))
-             #t)))))
-    (inputs
+             #t))
+         (add-before 'install 'fix-pom
+           (lambda _
+             ;; pom contains variables to complete name, but we don't support that
+             (substitute* "pom.xml"
+               (("\\$\\{platform\\}") "native"))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
+    (propagated-inputs
      `(("java-hawtjni" ,java-hawtjni)))
     (home-page "https://fusesource.github.io/jansi/")
     (synopsis "Native library for jansi")
@@ -10267,8 +11193,25 @@ console output.")
        (modify-phases %standard-phases
          (add-after 'check 'clear-term
            (lambda _
-             (invoke "echo" "-e" "\\e[0m"))))))
-    (inputs
+             (invoke "echo" "-e" "\\e[0m")))
+         (add-before 'install 'install-parent
+           (install-pom-file "pom.xml"))
+         (add-before 'install 'fix-pom
+           (lambda _
+             ;; pom adds jansi native versions for different platforms, but we
+             ;; only need one, so use native instead
+             (substitute* "jansi/pom.xml"
+               (("windows32") "native")
+               (("windows64") "native")
+               (("osx") "native")
+               (("linux32") "native")
+               (("linux64") "native")
+               (("freebsd32") "native")
+               (("freebsd64") "native"))
+             #t))
+         (replace 'install
+           (install-from-pom "jansi/pom.xml")))))
+    (propagated-inputs
      `(("java-jansi-native" ,java-jansi-native)))
     (native-inputs
      `(("java-junit" ,java-junit)
@@ -10294,7 +11237,31 @@ sequences to format your console output which works on every platform.")
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "java-jboss-el-api_spec.jar"
-       #:jdk ,icedtea-8))
+       #:modules ((guix build ant-build-system)
+                  (guix build utils)
+                  (guix build maven pom)
+                  (guix build java-utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         ;; the origin of javax.el:javax.el-api is unknown, so we use this package
+         ;; instead, which implements the same thing.  We override the pom file
+         ;; to "rename" the package so it can be found by maven.
+         (add-before 'install 'override-pom
+           (lambda _
+             (delete-file "pom.xml")
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `(project
+                      (modelVersion "4.0.0")
+                      (name "el-api")
+                      (groupId "javax.el")
+                      (artifactId "javax.el-api")
+                      (version "3.0")))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (inputs
      `(("java-junit" ,java-junit)))
     (home-page "https://github.com/jboss/jboss-el-api_spec")
@@ -10323,7 +11290,33 @@ JavaServer Pages (JSP).")
      `(#:jar-name "java-jboss-interceptors-api_spec.jar"
        #:jdk ,icedtea-8
        #:source-dir "."
-       #:tests? #f)); no tests
+       #:tests? #f; no tests
+       #:modules ((guix build ant-build-system)
+                  (guix build utils)
+                  (guix build maven pom)
+                  (guix build java-utils)
+                  (sxml simple))
+       #:phases
+       (modify-phases %standard-phases
+         ;; the origin of javax.interceptor:javax.interceptor-api is unknown,
+         ;; so we use this package instead, which implements the same thing.
+         ;; We override the pom file to "rename" the package so it can be found
+         ;; by maven.
+         (add-before 'install 'override-pom
+           (lambda _
+             (delete-file "pom.xml")
+             (with-output-to-file "pom.xml"
+               (lambda _
+                 (sxml->xml
+                   `(project
+                      (modelVersion "4.0.0")
+                      (name "interceptor-api")
+                      (groupId "javax.interceptor")
+                      (artifactId "javax.interceptor-api")
+                      (version "3.0")))))
+             #t))
+         (replace 'install
+           (install-from-pom "pom.xml")))))
     (home-page "https://github.com/jboss/jboss-interceptors-api_spec")
     (synopsis "Interceptors 1.2 API classes from JSR 318")
     (description "Java-jboss-interceptors-api-spec implements the Interceptors
@@ -10350,11 +11343,16 @@ specific events.")
        #:jar-name "java-cdi-api.jar"
        #:test-dir "api/src/test"
        #:jdk ,icedtea-8
-       #:tests? #f)); Tests fail because we don't have a CDI provider yet
-    (inputs
+       #:tests? #f; Tests fail because we don't have a CDI provider yet
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "api/pom.xml")))))
+    (propagated-inputs
      `(("java-javax-inject" ,java-javax-inject)
        ("java-jboss-el-api-spec" ,java-jboss-el-api-spec)
-       ("java-jboss-interceptors-api-spec" ,java-jboss-interceptors-api-spec)))
+       ("java-jboss-interceptors-api-spec" ,java-jboss-interceptors-api-spec)
+       ("java-weld-parent-pom" ,java-weld-parent-pom)))
     (native-inputs
      `(("java-testng" ,java-testng)
        ("java-hamcrest-core" ,java-hamcrest-core)))
@@ -10465,14 +11463,14 @@ classes prior to Java SE 8.")
 (define-public java-xerces
   (package
     (name "java-xerces")
-    (version "2.11.0")
+    (version "2.12.1")
     (source
      (origin
        (method url-fetch)
        (uri (string-append "mirror://apache/xerces/j/source/"
                            "Xerces-J-src." version ".tar.gz"))
        (sha256
-        (base32 "1006igwy2lqrmjvdk64v8dg6qbk9c29pm8xxx7r87n0vnpvmx6pm"))
+        (base32 "0494kq36gw3nah19ifb720vwxbpg4ww0k6m3zq6wyanw6a083p6s"))
        (patches (search-patches
                  "java-xerces-xjavac_taskdef.patch"
                  "java-xerces-build_dont_unzip.patch"
@@ -10667,13 +11665,13 @@ features that bring it on par with the Z shell line editor.")
         ,(origin
            (method git-fetch)
            (uri (git-reference
-                  (url "https://github.com/xmlunit/test-resources.git")
+                  (url "https://github.com/xmlunit/test-resources")
                   (commit "a590d2ae865c3e0455691d76ba8eefccc2215aec")))
            (file-name "java-xmlunit-test-resources")
            (sha256
             (base32
              "0r0glj37pg5l868yjz78gckr91cs8fysxxbp9p328dssssi91agr"))))))
-    (home-page "http://www.xmlunit.org/")
+    (home-page "https://www.xmlunit.org/")
     (synopsis "XML output testing")
     (description "XMLUnit provides you with the tools to verify the XML you
 emit is the one you want to create.  It provides helpers to validate against
@@ -10773,7 +11771,7 @@ graphs, and pie charts.")
     (version "3.1")
     (source (origin
               (method url-fetch)
-              (uri (string-append "https://archive.apache.org/dist/httpcomponents/"
+              (uri (string-append "mirror://apache/httpcomponents/"
                                   "commons-httpclient/source/commons-httpclient-"
                                   version "-src.tar.gz"))
               (sha256
@@ -10869,7 +11867,7 @@ inside a Zip archive.")
     (version "2.0.8")
     (source (origin
               (method url-fetch)
-              (uri (string-append "https://archive.apache.org/dist/jakarta/oro/"
+              (uri (string-append "mirror://apache/jakarta/oro/"
                                   "jakarta-oro-" version ".tar.gz"))
               (sha256
                (base32
@@ -10882,6 +11880,7 @@ inside a Zip archive.")
     (build-system ant-build-system)
     (arguments
      `(#:build-target "package"
+       #:make-flags (list "-DDATE" "(no recorded date for reproducibility)")
        #:tests? #f; tests are run as part of the build process
        #:phases
        (modify-phases %standard-phases
@@ -10932,11 +11931,10 @@ from ORO, Inc.")
                ;; so don't fail if we can't find a native library for another architecture.
                (("zipfileset") "zipfileset erroronmissingarchive=\"false\""))
              ;; Copy test dependencies
-             (copy-file (string-append (assoc-ref inputs "java-junit")
-                                       "/share/java/junit.jar")
+             (copy-file (car (find-files (assoc-ref inputs "java-junit") "jar$"))
                         "lib/junit.jar")
-             (copy-file (string-append (assoc-ref inputs "java-hamcrest-core")
-                                       "/share/java/hamcrest-core.jar")
+             (copy-file (car (find-files (assoc-ref inputs "java-hamcrest-core")
+                                         "jar$"))
                         "lib/hamcrest-core.jar")
              ;; FIXME: once reflections.jar is built, copy it to lib/test.
              #t))
@@ -10985,11 +11983,11 @@ Java method invocation.")
                 (string-append (assoc-ref inputs "java-native-access")
                                "/share/java/jna.jar"))
                (("../../lib/hamcrest-core-.*.jar")
-                (string-append (assoc-ref inputs "java-hamcrest-core")
-                               "/share/java/hamcrest-core.jar"))
+                (car (find-files (assoc-ref inputs "java-hamcrest-core")
+                                 "jar$")))
                (("../../lib/junit.jar")
-                (string-append (assoc-ref inputs "java-junit")
-                               "/share/java/junit.jar")))
+                (car (find-files (assoc-ref inputs "java-junit")
+                                 "jar$"))))
              #t))
          (replace 'install
            (install-jars "dist")))))
@@ -11226,25 +12224,30 @@ and reporting) project dependencies.  It is characterized by the following:
 (define-public java-eclipse-sisu-inject
   (package
     (name "java-eclipse-sisu-inject")
-    (version "0.3.3")
+    (version "0.3.4")
     (source (origin
               (method git-fetch)
               (uri (git-reference
                      (url "https://github.com/eclipse/sisu.inject/")
-                     (commit "releases/0.3.3")))
+                     (commit (string-append "releases/" version))))
               (file-name (git-file-name name version))
               (sha256
                (base32
-                "0gibc9x0bw0f4ls086fx73610fcspz9g2as7kcpcfhvl5znysvg7"))))
+                "16044sizdb0rjbhlfbmcnpds5y7by7dyn9b0c11606aikqi8k3x6"))))
     (build-system ant-build-system)
     (arguments
      `(#:jar-name "eclipse-sisu-inject.jar"
        #:source-dir "org.eclipse.sisu.inject/src"
-       #:jdk ,icedtea-8
-       #:tests? #f)); no tests
-    (inputs
+       #:tests? #f; no tests
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'install
+           (install-from-pom "org.eclipse.sisu.inject/pom.xml")))))
+    (propagated-inputs
      `(("java-guice" ,java-guice)
-       ("java-guice-servlet" ,java-guice-servlet)
+       ("java-sisu-inject-parent-pom" ,java-sisu-inject-parent-pom)))
+    (inputs
+     `(("java-guice-servlet" ,java-guice-servlet)
        ("java-javax-inject" ,java-javax-inject)
        ("java-javaee-servletapi" ,java-javaee-servletapi)
        ("java-junit" ,java-junit)
@@ -11265,6 +12268,20 @@ Integration with other containers via the Eclipse Extension Registry and the
 OSGi Service Registry is a goal of this project.")
     (license license:epl1.0)))
 
+(define java-sisu-inject-parent-pom
+  (package
+    (inherit java-eclipse-sisu-inject)
+    (name "java-sisu-inject-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs '())))
+
 (define-public java-eclipse-sisu-plexus
   (package
     (name "java-eclipse-sisu-plexus")
@@ -11272,7 +12289,7 @@ OSGi Service Registry is a goal of this project.")
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                     (url "https://github.com/eclipse/sisu.plexus.git")
+                     (url "https://github.com/eclipse/sisu.plexus")
                      (commit (string-append "releases/" version))))
               (file-name (git-file-name name version))
               (sha256
@@ -11326,22 +12343,27 @@ OSGi Service Registry is a goal of this project.")
                (substitute* "java/org/eclipse/sisu/plexus/DefaultPlexusContainerTest.java"
                  (("resources/component-jar")
                   "org.eclipse.sisu.plexus.tests/resources/component-jar")))
-             #t)))))
-    (inputs
+             #t))
+         (replace 'install
+           (install-from-pom "org.eclipse.sisu.plexus/pom.xml")))))
+    (propagated-inputs
      `(("java-plexus-classworlds" ,java-plexus-classworlds)
-       ("java-plexus-util" ,java-plexus-utils)
+       ("java-plexus-utils" ,java-plexus-utils)
        ("java-plexus-component-annotations" ,java-plexus-component-annotations)
-       ("java-osgi-framework" ,java-osgi-framework)
+       ("java-cdi-api" ,java-cdi-api)
        ("java-eclipse-sisu-inject" ,java-eclipse-sisu-inject)
-       ("java-guice" ,java-guice)
-       ("java-javax-inject" ,java-javax-inject)
+       ("java-sisu-plexus-parent-pom" ,java-sisu-plexus-parent-pom)))
+    (inputs
+     `(("java-osgi-framework" ,java-osgi-framework)
        ("java-slf4j-api" ,java-slf4j-api)
-       ("java-junit" ,java-junit)))
-    (native-inputs
-     `(("java-guava" ,java-guava)
+       ("java-javax-inject" ,java-javax-inject)
+       ("java-guice" ,java-guice)
+       ("java-guava" ,java-guava)
        ("java-aopalliance" ,java-aopalliance)
-       ("java-cglib" ,java-cglib)
-       ("java-asm" ,java-asm)))
+       ("java-asm" ,java-asm)
+       ("java-cglib" ,java-cglib)))
+    (native-inputs
+     `(("java-junit" ,java-junit)))
     (home-page "https://www.eclipse.org/sisu/")
     (synopsis "Plexus support for the sisu container")
     (description "Sisu is a modular JSR330-based container that supports
@@ -11349,6 +12371,21 @@ classpath scanning, auto-binding, and dynamic auto-wiring.  This package
 adds Plexus support to the Sisu-Inject container.")
     (license license:epl1.0)))
 
+(define java-sisu-plexus-parent-pom
+  (package
+    (inherit java-eclipse-sisu-plexus)
+    (name "java-sisu-plexus-parent-pom")
+    (arguments
+     `(#:tests? #f
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (replace 'install
+           (install-pom-file "pom.xml")))))
+    (propagated-inputs
+     `(("java-sonatype-oss-parent-pom-9" ,java-sonatype-oss-parent-pom-9)))))
+
 (define-public java-commons-compiler
   (package
     (name "java-commons-compiler")
@@ -11857,3 +12894,54 @@ involving one or more shared resources having ACID (Atomicity, Consistency,
 Isolation and Durability) properties.")
     ;; either gpl2 only with classpath exception or cddl.
     (license (list license:gpl2 license:cddl1.0))))
+
+(define-public java-picocli
+  (package
+    (name "java-picocli")
+    (version "4.3.2")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/remkop/picocli")
+                     (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1sxp6rxjfgjd98ly14b3d15dvxkm5wg4g46w12jyhmr0kmkaca3c"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "picocli.jar"
+       #:source-dir "src/main/java"
+       ;; Tests require missing dependencies (junitparams, system-rules)
+       #:tests? #f))
+    (home-page "https://picocli.info")
+    (synopsis "REPL for the JVM")
+    (description "Picocli is a framework for building command line applications
+for the JVM.  It supports colors, autocompletion, subcommands, and more.  Written
+in Java, usable from Groovy, Kotlin, Scala, etc.")
+    (license license:asl2.0)))
+
+(define-public java-jetbrains-annotations
+  (package
+    (name "java-jetbrains-annotations")
+    (version "19.0.0")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/JetBrains/java-annotations")
+                     (commit version)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0z6i1xs60cd5ffz23c49sq68wn5mphhs3xpar1n93ppama2ng80v"))))
+    (build-system ant-build-system)
+    (arguments
+     `(#:jar-name "jetbrains-annotations.jar"
+       #:source-dir "common/src/main/java:java8/src/main/java"
+       #:tests? #f)); no tests
+    (home-page "https://github.com/JetBrains/java-annotations")
+    (synopsis "Annotations for Java and other JVM languages")
+    (description "This package contains a set of Java annotations which can be
+used in JVM-based languages.  They serve as an additional documentation and
+can be interpreted by IDEs and static analysis tools to improve code analysis.")
+    (license license:expat)))