;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2015, 2016, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
;;; Copyright © 2016, 2017 Roel Janssen <roel@gnu.org>
-;;; Copyright © 2017 Carlo Zancanaro <carlo@zancanaro.id.au>
-;;; Copyright © 2017, 2018 Julien Lepiller <julien@lepiller.eu>
+;;; Copyright © 2017, 2019 Carlo Zancanaro <carlo@zancanaro.id.au>
+;;; Copyright © 2017, 2018, 2019 Julien Lepiller <julien@lepiller.eu>
;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
;;; Copyright © 2016, 2017, 2018 Alex Vong <alexvong1995@gmail.com>
-;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
-;;; Copyright © 2018 Gábor Boskovits <boskovits@gmail.com>
+;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2018, 2019 Gábor Boskovits <boskovits@gmail.com>
;;; Copyright © 2018 Chris Marusich <cmmarusich@gmail.com>
-;;; Copyright © 2018 Efraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
;;;
;;; This file is part of GNU Guix.
;;;
#:use-module (gnu packages gettext)
#:use-module (gnu packages gcc)
#:use-module (gnu packages gl)
- #:use-module (gnu packages gnuzilla) ;nss
#:use-module (gnu packages ghostscript) ;lcms
#:use-module (gnu packages gnome)
#:use-module (gnu packages groovy)
#:use-module (gnu packages guile)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages image)
+ #:use-module (gnu packages java-compression)
#:use-module (gnu packages libffi)
#:use-module (gnu packages linux) ;alsa
#:use-module (gnu packages maths)
+ #:use-module (gnu packages nss)
#:use-module (gnu packages onc-rpc)
#:use-module (gnu packages web)
#:use-module (gnu packages wget)
"--disable-gjdoc")
#:phases
(modify-phases %standard-phases
+ ;; XXX: This introduces a memory leak as we remove a call to free up
+ ;; memory for the file name string. This was necessary because of a
+ ;; runtime error that would have prevented us from building
+ ;; ant-bootstrap later. See https://issues.guix.gnu.org/issue/36685
+ ;; for the gnarly details.
+ (add-after 'unpack 'remove-call-to-free
+ (lambda _
+ (substitute* "native/jni/java-io/java_io_VMFile.c"
+ (("result = cpio_isFileExists.*" m)
+ (string-append m "\n//")))
+ #t))
(add-after 'install 'install-data
(lambda _ (invoke "make" "install-data"))))))
(native-inputs
(arguments
`(#:configure-flags
(list (string-append "--with-classpath-install-dir="
- (assoc-ref %build-inputs "classpath")))))
+ (assoc-ref %build-inputs "classpath"))
+ "--disable-int-caching"
+ "--enable-runtime-reloc-checks"
+ "--enable-ffi")))
(inputs
`(("classpath" ,classpath-bootstrap)
("jikes" ,jikes)
+ ("libffi" ,libffi)
("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
`(("jikes" ,jikes)
("jamvm" ,jamvm-1-bootstrap)
("unzip" ,unzip)
- ("zip", zip)))
+ ("zip" ,zip)))
(home-page "http://ant.apache.org")
(synopsis "Build tool for Java")
(description
(with-directory-excursion "openjdk"
(invoke "tar" "xvf" (assoc-ref inputs "hotspot-src"))
(rename-file "hg-checkout" "hotspot"))
+ (substitute* "patches/freetypeversion.patch"
+ (("REQUIRED_FREETYPE_VERSION = 2.2.1")
+ "REQUIRED_FREETYPE_VERSION = 2.10.1"))
(substitute* "Makefile.in"
(("echo \"ERROR: No up-to-date OpenJDK zip available\"; exit -1;")
"echo \"trust me\";")
(string-append (assoc-ref inputs "freetype")
"/lib"))
#t))
+ (add-before 'build 'disable-os-version-check
+ ;; allow build on linux major version change
+ (lambda _
+ (setenv "DISABLE_HOTSPOT_OS_VERSION_CHECK" "ok")
+ #t))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((doc (string-append (assoc-ref outputs "doc")
("fastjar" ,fastjar)
("fontconfig" ,fontconfig)
("freetype" ,freetype)
- ("gcc" ,gcc-4.9) ; there's a segmentation fault when compiling with gcc-5 or gcc-7
("gtk" ,gtk+-2)
("gawk" ,gawk)
("giflib" ,giflib)
((name . _) name))
inputs))))
#t)))
+ (add-after 'unpack 'patch-bitrot
+ (lambda _
+ (substitute* '("patches/boot/revert-6973616.patch"
+ "openjdk.src/jdk/make/common/shared/Defs-versions.gmk")
+ (("REQUIRED_FREETYPE_VERSION = 2.2.1")
+ "REQUIRED_FREETYPE_VERSION = 2.10.1"))
+ ;; As of attr 2.4.48 this header is no longer
+ ;; included. It is provided by the libc instead.
+ (substitute* '("configure"
+ "openjdk.src/jdk/src/solaris/native/sun/nio/fs/LinuxNativeDispatcher.c")
+ (("attr/xattr.h") "sys/xattr.h"))
+ #t))
(add-after 'unpack 'fix-x11-extension-include-path
(lambda* (#:key inputs #:allow-other-keys)
(substitute* "openjdk.src/jdk/make/sun/awt/mawt.gmk"
(string-append (assoc-ref inputs "freetype")
"/lib"))
#t))
+ (add-before 'build 'disable-os-version-check
+ ;; allow build on linux major version change
+ (lambda _
+ (setenv "DISABLE_HOTSPOT_OS_VERSION_CHECK" "ok")
+ #t))
(add-before 'check 'fix-test-framework
(lambda _
;; Fix PATH in test environment
(add-after 'install 'install-libjvm
(lambda* (#:key inputs outputs #:allow-other-keys)
(let* ((lib-path (string-append (assoc-ref outputs "out")
- "/lib/amd64")))
+ ;; See 'INSTALL_ARCH_DIR' in
+ ;; 'configure'.
+ ,(match (%current-system)
+ ("i686-linux"
+ "/lib/i386")
+ ("x86_64-linux"
+ "/lib/amd64")
+ ("armhf-linux"
+ "/lib/arm")
+ ("aarch64-linux"
+ "/lib/aarch64")))))
(symlink (string-append lib-path "/server/libjvm.so")
(string-append lib-path "/libjvm.so")))
#t))
(description
"This package provides the Java development kit OpenJDK built with the
IcedTea build harness.")
+
+ ;; 'configure' lists "mips" and "mipsel", but not "mips64el'.
+ (supported-systems (delete "mips64el-linux" %supported-systems))
+
;; IcedTea is released under the GPL2 + Classpath exception, which is the
;; same license as both GNU Classpath and OpenJDK.
(license license:gpl2+))))
(delete 'patch-paths)
(delete 'set-additional-paths)
(delete 'patch-patches)
+ (delete 'patch-bitrot)
;; Prevent the keytool from recording the current time when
;; adding certificates at build time.
(add-after 'unpack 'patch-keystore
(sha256
(base32
"0zywq2203b4hx4jms9vbwvjcj1d3k2v3qpx4s33729fkpmid97r4"))
+ (patches (search-patches
+ "openjdk-10-idlj-reproducibility.patch"))
(modules '((guix build utils)))
(snippet
`(begin
("which" ,which)
("zip" ,zip)))))
+(define-public openjdk11
+ (package
+ (name "openjdk")
+ (version "11.28")
+ (source (origin
+ (method url-fetch)
+ (uri "http://hg.openjdk.java.net/jdk/jdk/archive/76072a077ee1.tar.bz2")
+ (file-name (string-append name "-" version ".tar.bz2"))
+ (sha256
+ (base32
+ "0v705w1s9lrqalzahir78pk397rkk9gfvzq821yv8h3xha0bqi6w"))
+ (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$"))
+ #t))))
+ (build-system gnu-build-system)
+ (outputs '("out" "jdk" "doc"))
+ (arguments
+ `(#:imported-modules
+ ((guix build syscalls)
+ (ice-9 binary-ports)
+ (rnrs bytevectors)
+ ,@%gnu-build-system-modules)
+ #:tests? #f; requires jtreg
+ ;; TODO package jtreg
+ ;; disable parallel builds, as the openjdk build system does not like -j
+ #:parallel-build? #f
+ #:parallel-tests? #f
+ ;; reenable parallel builds and tests by adding the flags manually
+ #:make-flags (list (string-append "JOBS=" (number->string (parallel-job-count))))
+ #:configure-flags
+ `("--disable-option-checking" ; --enable-fast-install default flag errors otherwise
+ "--disable-warnings-as-errors"
+ ;; make validate-runpath pass, see: http://issues.guix.info/issue/32894
+ "--with-native-debug-symbols=zipped"
+ ;; do not use the bundled libraries
+ "--with-giflib=system"
+ "--with-lcms=system"
+ "--with-libjpeg=system"
+ "--with-libpng=system"
+ "--with-version-pre="
+ ;; allow the build system to locate the system freetype
+ ,(string-append "--with-freetype-include="
+ (assoc-ref %build-inputs "freetype") "/include")
+ ,(string-append "--with-freetype-lib="
+ (assoc-ref %build-inputs "freetype") "/lib"))
+ ;; TODO
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'patch-source-shebangs 'fix-java-shebangs
+ (lambda _
+ ;; This file was "fixed" by patch-source-shebangs, but it requires
+ ;; this exact first line.
+ (substitute* "make/data/blacklistedcertsconverter/blacklisted.certs.pem"
+ (("^#!.*") "#! java BlacklistedCertsConverter SHA-256\n"))
+ #t))
+ (replace 'build
+ (lambda _
+ (with-output-to-file ".src-rev"
+ (lambda _
+ (display ,version)))
+ (setenv "GUIX_LD_WRAPPER_ALLOW_IMPURITIES" "yes")
+ (invoke "make" "all")
+ #t))
+ ;; jdk 11 does not build jre by default any more
+ ;; building it anyways
+ ;; for further information see:
+ ;; https://github.com/AdoptOpenJDK/openjdk-build/issues/356
+ (add-after 'build 'build-jre
+ (lambda _
+ (invoke "make" "legacy-jre-image")
+ #t))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (jdk (assoc-ref outputs "jdk"))
+ (doc (assoc-ref outputs "doc"))
+ (images (car (find-files "build" ".*-server-release"
+ #:directories? #t))))
+ (copy-recursively (string-append images "/images/jdk") jdk)
+ (copy-recursively (string-append images "/images/jre") out)
+ (copy-recursively (string-append images "/images/docs") doc))
+ #t))
+ ;; Some of the libraries in the lib/ folder link to libjvm.so.
+ ;; But that shared object is located in the server/ folder, so it
+ ;; cannot be found. This phase creates a symbolic link in the
+ ;; lib/ folder so that the other libraries can find it.
+ ;;
+ ;; See:
+ ;; https://lists.gnu.org/archive/html/guix-devel/2017-10/msg00169.html
+ ;;
+ ;; FIXME: Find the bug in the build system, so that this symlink is
+ ;; not needed.
+ (add-after 'install 'install-libjvm
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((lib-out (string-append (assoc-ref outputs "out")
+ "/lib"))
+ (lib-jdk (string-append (assoc-ref outputs "jdk")
+ "/lib")))
+ (symlink (string-append lib-jdk "/server/libjvm.so")
+ (string-append lib-jdk "/libjvm.so"))
+ (symlink (string-append lib-out "/server/libjvm.so")
+ (string-append lib-out "/libjvm.so")))
+ #t))
+ (add-after 'install 'strip-character-data-timestamps
+ (lambda* (#:key outputs #:allow-other-keys)
+ (use-modules (guix build syscalls))
+ (let ((archive (string-append
+ (assoc-ref outputs "jdk") "/lib/src.zip"))
+ (dir (mkdtemp! "zip-contents.XXXXXX")))
+ (with-directory-excursion dir
+ (invoke "unzip" archive))
+ (delete-file archive)
+ (with-directory-excursion dir
+ (let ((char-data-files (find-files "." "CharacterData.*")))
+ (for-each (lambda (file)
+ (substitute* file
+ (((string-append "This file was generated "
+ "AUTOMATICALLY from a template "
+ "file.*"))
+ (string-append "This file was generated "
+ "AUTOMATICALLY from a template "
+ "file"))))
+ char-data-files)))
+ (with-directory-excursion dir
+ (let ((files (find-files "." ".*" #:directories? #t)))
+ (apply invoke "zip" "-0" "-X" archive files))))))
+ (add-after 'strip-character-data-timestamps 'strip-archive-timestamps
+ (lambda* (#:key outputs #:allow-other-keys)
+ (use-modules (guix build syscalls)
+ (ice-9 binary-ports)
+ (rnrs bytevectors))
+ (letrec ((repack-archive
+ (lambda (archive)
+ (let ((dir (mkdtemp! "zip-contents.XXXXXX")))
+ (with-directory-excursion dir
+ (invoke "unzip" archive))
+ (delete-file archive)
+ (for-each (compose repack-archive canonicalize-path)
+ (find-files dir "(ct.sym|.*.jar)$"))
+ (let ((reset-file-timestamp
+ (lambda (file)
+ (let ((s (lstat file)))
+ (unless (eq? (stat:type s) 'symlink)
+ (format #t "reset ~a~%" file)
+ (utime file 0 0 0 0))))))
+ (for-each reset-file-timestamp
+ (find-files dir #:directories? #t)))
+ (with-directory-excursion dir
+ (let ((files (find-files "." ".*" #:directories? #t)))
+ (apply invoke "zip" "-0" "-X" archive files)))))))
+ (for-each repack-archive
+ (find-files (assoc-ref outputs "doc") ".*.zip$"))
+ (for-each repack-archive
+ (find-files (assoc-ref outputs "jdk")
+ ".*.(zip|jar|diz)$"))
+ (repack-archive (string-append (assoc-ref outputs "jdk") "/lib/ct.sym"))
+ (let ((repack-jmod
+ (lambda (file-name)
+ (call-with-input-file file-name
+ (lambda (file)
+ (let ((header #vu8(#x4a #x4d #x01 #x00)))
+ (if (equal? (get-bytevector-n
+ file (bytevector-length header))
+ header)
+ (let* ((header-length (bytevector-length header))
+ (temp-file (mkstemp!
+ (string-copy
+ "temp-file.XXXXXX")))
+ (temp-filename (port-filename temp-file))
+ (content-length
+ (- (stat:size (stat file))
+ header-length)))
+ (sendfile temp-file file content-length header-length)
+ (delete-file file-name)
+ (close-port temp-file)
+ (repack-archive (canonicalize-path temp-filename))
+ (call-with-output-file file-name
+ (lambda (file)
+ (put-bytevector file header)
+ (call-with-input-file temp-filename
+ (lambda (temp-file)
+ (sendfile
+ file temp-file
+ (stat:size (stat temp-file)) 0)))))))))))))
+ (for-each repack-jmod
+ (find-files (assoc-ref outputs "jdk") ".*.jmod$")))
+ #t)))
+ (add-after 'install 'remove-timestamp-from-api-summary
+ (lambda* (#:key outputs #:allow-other-keys)
+ (substitute* (string-append (assoc-ref outputs "doc")
+ "/api/overview-summary.html")
+ (("Generated by javadoc \\(11-internal\\).*$")
+ "Generated by javadoc (11-internal) -->\n"))
+ #t)))))
+ (inputs
+ `(("alsa-lib" ,alsa-lib)
+ ("cups" ,cups)
+ ("fontconfig" ,fontconfig)
+ ("freetype" ,freetype)
+ ("giflib" ,giflib)
+ ("lcms" ,lcms)
+ ("libjpeg" ,libjpeg)
+ ("libpng" ,libpng)
+ ("libx11" ,libx11)
+ ("libxext" ,libxext)
+ ("libxrender" ,libxrender)
+ ("libxt" ,libxt)
+ ("libxtst" ,libxtst)))
+ (native-inputs
+ `(("autoconf" ,autoconf)
+ ("openjdk10" ,openjdk10)
+ ("openjdk10:jdk" ,openjdk10 "jdk")
+ ("pkg-config" ,pkg-config)
+ ("unzip" ,unzip)
+ ("which" ,which)
+ ("zip" ,zip)))
+ (home-page "https://openjdk.java.net/projects/jdk/11/")
+ (synopsis "Java development kit")
+ (description
+ "This package provides the Java development kit OpenJDK.")
+ (license license:gpl2+)))
+
+(define-public openjdk12
+ (package
+ (inherit openjdk11)
+ (name "openjdk")
+ (version "12.33")
+ (source (origin
+ (method url-fetch)
+ (uri "http://hg.openjdk.java.net/jdk/jdk/archive/0276cba45aac.tar.bz2")
+ (file-name (string-append name "-" version ".tar.bz2"))
+ (sha256
+ (base32
+ "0mbhdrk12b6878kby0flnbak7444dlpm0ihlmf92vk59y1c02bc2"))
+ (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$"))
+ #t))))
+ (inputs
+ `(("alsa-lib" ,alsa-lib)
+ ("cups" ,cups)
+ ("fontconfig" ,fontconfig)
+ ("freetype" ,freetype)
+ ("giflib" ,giflib)
+ ("lcms" ,lcms)
+ ("libjpeg" ,libjpeg)
+ ("libpng" ,libpng)
+ ("libx11" ,libx11)
+ ("libxext" ,libxext)
+ ("libxrandr" ,libxrandr)
+ ("libxrender" ,libxrender)
+ ("libxt" ,libxt)
+ ("libxtst" ,libxtst)))
+ (native-inputs
+ `(("autoconf" ,autoconf)
+ ("openjdk11" ,openjdk11)
+ ("openjdk11:jdk" ,openjdk11 "jdk")
+ ("pkg-config" ,pkg-config)
+ ("unzip" ,unzip)
+ ("which" ,which)
+ ("zip" ,zip)))
+ (home-page "https://openjdk.java.net/projects/jdk/12")))
+
(define-public icedtea icedtea-8)
\f
`(("java-junit" ,java-junit)
,@(package-inputs ant/java8)))))
+(define-public java-openjfx-build
+ (package
+ (name "java-openjfx-build")
+ ;; This is a java-8 version
+ (version "8.202")
+ (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"))))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "0yg38mwpivswccv9n96k06x3iv82i4px1a9xg9l8dswzwmfj259f"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "java-openjfx.jar"
+ #:source-dir "buildSrc/src/main/java"
+ #:test-dir "buildSrc/src/test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'configure 'generate-jsl-parser
+ (lambda _
+ (invoke "antlr3" "-o"
+ "buildSrc/src/main/java/com/sun/scenario/effect/compiler"
+ "buildSrc/src/main/antlr/JSL.g"))))))
+ (inputs
+ `(("antlr3" ,antlr3)
+ ("java-stringtemplate" ,java-stringtemplate)))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "https://openjfx.io")
+ (synopsis "Graphical application toolkit in Java")
+ (description "OpenJFX is a client application platform for desktop,
+mobile and embedded systems built on Java. Its goal is to produce a
+modern, efficient, and fully featured toolkit for developing rich client
+applications. This package contains base classes for the OpenJFX
+distribution and helper classes for building other parts of the
+distribution.")
+ (license license:gpl2))) ;gpl2 only, with classpath exception
+
+(define-public java-openjfx-base
+ (package (inherit java-openjfx-build)
+ (name "java-openjfx-base")
+ (arguments
+ `(#:jar-name "java-openjfx-base.jar"
+ #:source-dir "modules/base/src/main/java:modules/base/src/main/java8:modules/base/src/main/version-info"
+ #:test-dir "modules/base/src/test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'remove-empty-file
+ (lambda _
+ (with-directory-excursion "modules/base/src/test/java"
+ ;; These files are completely commented, but junit expects them to
+ ;; contain a class, so tests fail.
+ (delete-file
+ "com/sun/javafx/property/adapter/PropertyDescriptorTest.java")
+ (delete-file
+ "com/sun/javafx/property/adapter/ReadOnlyPropertyDescriptorTest.java")
+ (delete-file "javafx/beans/property/PropertiesTest.java")
+ (delete-file
+ "javafx/beans/property/adapter/ReadOnlyJavaBeanPropertyBuilder_General_Test.java")
+ ;; This one fails
+ (delete-file "com/sun/javafx/runtime/VersionInfoTest.java"))
+ #t)))))
+ (propagated-inputs
+ `(("java-openjfx-build" ,java-openjfx-build)))
+ (description "OpenJFX is a client application platform for desktop,
+mobile and embedded systems built on Java. Its goal is to produce a
+modern, efficient, and fully featured toolkit for developing rich client
+applications. This package contains base classes for the OpenJFX
+distribution.")))
+
+(define-public java-openjfx-graphics
+ (package (inherit java-openjfx-build)
+ (name "java-openjfx-graphics")
+ (arguments
+ `(#:jar-name "java-openjfx-graphics.jar"
+ #:source-dir "modules/graphics/src/main/java"
+ #:tests? #f; require X
+ #:test-dir "modules/graphics/src/test"))
+ (propagated-inputs
+ `(("java-openjfx-base" ,java-openjfx-base)
+ ("java-swt" ,java-swt)))
+ (description "OpenJFX is a client application platform for desktop,
+mobile and embedded systems built on Java. Its goal is to produce a
+modern, efficient, and fully featured toolkit for developing rich client
+applications. This package contains graphics-related classes for the
+OpenJFX distribution.")))
+
+(define-public java-openjfx-media
+ (package (inherit java-openjfx-build)
+ (name "java-openjfx-media")
+ (propagated-inputs
+ `(("java-openjxf-graphics" ,java-openjfx-graphics)))
+ (arguments
+ `(#:jar-name "java-openjfx-media.jar"
+ #:source-dir "modules/media/src/main/java"
+ #:tests? #f)); no tests
+ (description "OpenJFX is a client application platform for desktop,
+mobile and embedded systems built on Java. Its goal is to produce a
+modern, efficient, and fully featured toolkit for developing rich client
+applications. This package contains media-related classes for the
+OpenJFX distribution.")))
+
(define-public javacc-4
(package
(name "javacc")
(define-public javacc
(package
(inherit javacc-4)
- (version "7.0.3")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/javacc/javacc/"
- "archive/" version ".tar.gz"))
- (file-name (string-append "javacc-" version ".tar.gz"))
- (sha256
- (base32
- "111xc9mnmc5a6qz6x3xbhqc07y1lg2b996ggzw0hrblg42zya9xf"))
- (modules '((guix build utils)))
- ;; delete bundled jars
- (snippet '(begin (for-each delete-file-recursively
- '("bootstrap" "lib"))
- #t))))
- (arguments
- `(#:make-flags ; bootstrap from javacc-4
+ (version "7.0.4")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/javacc/javacc.git")
+ (commit version)))
+ (file-name (git-file-name "javacc" version))
+ (sha256
+ (base32 "18kkak3gda93gr25jrgy6q00g0jr8i24ri2wk4kybz1v234fxx9i"))
+ (modules '((guix build utils)))
+ ;; Delete bundled jars.
+ (snippet '(begin (for-each delete-file-recursively
+ '("bootstrap" "lib"))
+ #t))))
+ (arguments
+ `(#:make-flags ; bootstrap from javacc-4
(list (string-append "-Dbootstrap-jar="
(assoc-ref %build-inputs "javacc")
"/share/java/javacc.jar"))
#:test-target "test"
#:phases
(modify-phases %standard-phases
- (replace 'install (install-jars "target")))))
+ (replace 'install (install-jars "target"))
+ (add-after 'install 'install-bin
+ (lambda* (#:key outputs inputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (dir (string-append out "/share/java"))
+ (bin (string-append out "/bin"))
+ (javacc (string-append bin "/javacc")))
+ (mkdir-p bin)
+ (with-output-to-file javacc
+ (lambda _
+ (display
+ (string-append "#!/bin/sh\n"
+ (assoc-ref inputs "jdk") "/bin/java"
+ " -cp " dir "/javacc.jar" " `basename $0`" " $*"))))
+ (chmod javacc #o755)
+ ;; symlink to different names to affect the first argument and
+ ;; change the behavior of the jar file.
+ (symlink javacc (string-append bin "/jjdoc"))
+ (symlink javacc (string-append bin "/jjtree"))
+ #t))))))
+
(native-inputs
`(("javacc" ,javacc-4)))))
(define-public java-plexus-utils
(package
(name "java-plexus-utils")
- (version "3.0.24")
+ (version "3.2.0")
(source (origin
(method url-fetch)
(uri (string-append "https://github.com/codehaus-plexus/"
version ".tar.gz"))
(sha256
(base32
- "1mlwpc6fms24slygv5yvi6fi9hcha2fh0v73p5znpi78bg36i2js"))))
+ "1ihfigar20lvk4pinii7dq05i173xphhw4iyrk6gjfy04m01j2lz"))))
(build-system ant-build-system)
;; FIXME: The default build.xml does not include a target to install
;; javadoc files.
(delete-file "cli/CommandlineTest.java"))
#t)))))
(native-inputs
- `(("java-junit" ,java-junit)))
+ `(("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-junit" ,java-junit)))
(home-page "http://codehaus-plexus.github.io/plexus-utils/")
(synopsis "Common utilities for the Plexus framework")
(description "This package provides various Java utility classes for the
(define-public java-plexus-archiver
(package
(name "java-plexus-archiver")
- (version "3.5")
+ (version "4.1.0")
(source (origin
(method url-fetch)
(uri (string-append "https://github.com/codehaus-plexus/plexus-archiver"
"/archive/plexus-archiver-" version ".tar.gz"))
(sha256
(base32
- "0iv1j7khra6icqh3jndng3iipfmkc7l5jq2y802cm8r575v75pyv"))))
+ "0ry6i92gli0mvdmfih2vgs0lkf9yvx18h2ajxim66yg6yipnp0hg"))))
(build-system ant-build-system)
(arguments
`(#:jar-name "plexus-archiver.jar"
(delete-file
"src/test/java/org/codehaus/plexus/archiver/DuplicateFilesTest.java")
#t))
+ (add-before 'check 'fix-test-building
+ (lambda _
+ (substitute* "build.xml"
+ (("srcdir=\"src/test\"") "srcdir=\"src/test/java\""))
+ #t))
(add-before 'build 'copy-resources
(lambda _
(mkdir-p "build/classes/META-INF/plexus")
("snappy" ,java-snappy)
("java-jsr305" ,java-jsr305)))
(native-inputs
- `(("junit" ,java-junit)
+ `(("java-hamcrest-core" ,java-hamcrest-core)
+ ("junit" ,java-junit)
("classworld" ,java-plexus-classworlds)
("xbean" ,java-geronimo-xbean-reflect)
("xz" ,java-tukaani-xz)
(package
(name "java-cglib")
(version "3.2.4")
- (source (origin
- (method url-fetch)
- (uri (string-append
- "https://github.com/cglib/cglib/archive/RELEASE_"
- (string-map (lambda (c) (if (char=? c #\.) #\_ c)) version)
- ".tar.gz"))
- (file-name (string-append "cglib-" version ".tar.gz"))
- (sha256
- (base32
- "162dvd4fln76ai8prfharf66pn6r56p3sxx683j5vdyccrd5hi1q"))))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/cglib/cglib.git")
+ (commit (string-append
+ "RELEASE_"
+ (string-map (lambda (c) (if (char=? c #\.) #\_ c))
+ version)))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "186451jms2zfp47yd8kxd77az2cqal1my2br7klgyp8fpl4qfg8v"))))
(build-system ant-build-system)
(arguments
`(;; FIXME: tests fail because junit runs
contexts, DOM etc, including mixtures thereof.")
(license license:asl2.0)))
+(define-public java-commons-pool
+ (package
+ (name "java-commons-pool")
+ (version "2.6.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/pool/source/"
+ "commons-pool2-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1fi1hgqmq01bs6azbj3sfswxzadp2r8sjjfiq6ryilz1m50kvrv6"))))
+ (arguments
+ `(#:jar-name "common-pool.jar"
+ #:source-dir "src/main/java"
+ #:test-exclude
+ (list "**/PerformanceTest.java")))
+ (build-system ant-build-system)
+ (inputs
+ `(("java-cglib" ,java-cglib)))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-asm" ,java-asm)
+ ("java-objenesis" ,java-objenesis)))
+ (home-page "https://commons.apache.org/proper/commons-pool/")
+ (synopsis "Object-pooling API in Java")
+ (description "The commons-pool package provides an object-pooling API
+and a number of object pool implementations. This package defines a
+handful of pooling interfaces and some base classes that may be useful when
+creating new pool implementations.")
+ (license license:asl2.0)))
+
+(define-public java-commons-dbcp
+ (package
+ (name "java-commons-dbcp")
+ (version "2.6.0")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/dbcp/source/"
+ "commons-dbcp2-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "0axbvcbnf2l70fc3ybrlp3siw2w4ka9mia2pnx4py8gz54cpw3rc"))))
+ (arguments
+ `(#:source-dir "src/main/java"
+ #:jar-name "java-commons-dbcp.jar"
+ #:tests? #f)); requires apache-geronimo
+ (inputs
+ `(("java-commons-pool" ,java-commons-pool)
+ ("java-commons-logging" ,java-commons-logging-minimal)
+ ("java-jboss-transaction-api-spec" ,java-jboss-transaction-api-spec)))
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (build-system ant-build-system)
+ (home-page "https://commons.apache.org/proper/commons-dbcp/")
+ (synopsis "Database Connection Pool for Java")
+ (description "Commons-dbcp allows you to share a pool of database
+connections between users. Creating a new connection for each user can be
+time consuming and even unfeasible when the number of simultaneous users is
+very large. This package provides a way to share a poole of connections to
+reduce that load.")
+ (license license:asl2.0)))
+
+(define-public java-commons-jcs
+ (package
+ (name "java-commons-jcs")
+ (version "2.2.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/jcs/source/"
+ "commons-jcs-dist-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "0syhq2npjbrl0azqfjm0gvash1qd5qjy4qmysxcrqjsk0nf9fa1q"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "commons-jcs.jar"
+ #:source-dir "commons-jcs-core/src/main/java"
+ #:test-dir "commons-jcs-core/src/test"
+ #:tests? #f; requires hsqldb
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'prepare
+ (lambda _
+ (with-directory-excursion
+ "commons-jcs-core/src/main/java/org/apache/commons/jcs"
+ (substitute*
+ "auxiliary/disk/jdbc/dsfactory/SharedPoolDataSourceFactory.java"
+ (("commons.dbcp") "commons.dbcp2")
+ ((".*\\.setMaxActive.*") ""))
+ ;;; Remove dependency on velocity-tools
+ (delete-file "admin/servlet/JCSAdminServlet.java"))
+ #t)))))
+ (propagated-inputs
+ `(("java-classpathx-servletapi" ,java-classpathx-servletapi)
+ ("java-commons-logging-minimal" ,java-commons-logging-minimal)
+ ("java-commons-httpclient" ,java-commons-httpclient)
+ ("java-commons-dbcp" ,java-commons-dbcp)))
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (home-page "https://commons.apache.org/proper/commons-jcs/")
+ (synopsis "Distributed caching system in Java")
+ (description "JCS is a distributed caching system written in Java. It
+is intended to speed up applications by providing a means to manage cached
+data of various dynamic natures. Like any caching system, JCS is most useful
+for high read, low put applications. Latency times drop sharply and
+bottlenecks move away from the database in an effectively cached system.")
+ (license license:asl2.0)))
+
(define-public java-jsr250
(package
(name "java-jsr250")
(define-public java-jsch
(package
(name "java-jsch")
- (version "0.1.54")
+ (version "0.1.55")
(source (origin
(method url-fetch)
(uri (string-append "mirror://sourceforge/jsch/jsch/"
version "/jsch-" version ".zip"))
(sha256
(base32
- "029rdddyq1mh3ghryh3ki99kba1xkf1d1swjv2vi6lk6zzjy2wdb"))))
+ "1lxyjwvmwa723wcf3bqn816hkvc03vz4xhbsi7bvfhrz2rpgcfq6"))))
(build-system ant-build-system)
(arguments
`(#:build-target "dist"
- #:tests? #f ; no tests included
+ #:tests? #f ; no tests included
#:phases
(modify-phases %standard-phases
(replace 'install (install-jars "dist")))))
(define-public java-eclipse-equinox-common
(package
(name "java-eclipse-equinox-common")
- (version "3.8.0")
+ (version "3.10.200")
(source (origin
(method url-fetch)
(uri (string-append "https://repo1.maven.org/maven2/"
version "-sources.jar"))
(sha256
(base32
- "12aazpkgw46r1qj0pr421jzwhbmsizd97r37krd7njnbrdgfzksc"))))
+ "1yn8ij6xsljlf35sr2l7wvyvc0ss4n1rv0ry5zkgb49dj4hyrqrj"))))
(build-system ant-build-system)
(arguments
`(#:tests? #f ; no tests included
(define-public java-eclipse-core-runtime
(package
(name "java-eclipse-core-runtime")
- (version "3.12.0")
+ (version "3.15.100")
(source (origin
(method url-fetch)
(uri (string-append "https://repo1.maven.org/maven2/"
version "-sources.jar"))
(sha256
(base32
- "16mkf8jgj35pgzms7w1gyfq0gfm4ixw6c5xbbxzdj1la56c758ya"))))
+ "0l8xayacsbjvz5hypx2fv47vpw2n4dspamcfb3hx30x9hj8vmg7r"))))
(build-system ant-build-system)
(arguments
`(#:tests? #f ; no tests included
(define-public java-eclipse-core-resources
(package
(name "java-eclipse-core-resources")
- (version "3.11.1")
+ (version "3.13.200")
(source (origin
(method url-fetch)
(uri (string-append "https://repo1.maven.org/maven2/"
version "-sources.jar"))
(sha256
(base32
- "1hrfxrll6cpcagfksk2na1ypvkcnsp0fk6n3vcsrn97qayf9mx9l"))))
+ "1sn3b6ky72hkvxcgf9b2jkpbdh3y8lbhi9xxwv1dsiddpkkq91hs"))))
(build-system ant-build-system)
(arguments
`(#:tests? #f ; no tests included
(define-public java-eclipse-jdt-core
(package
(name "java-eclipse-jdt-core")
- (version "3.12.3")
+ (version "3.16.0")
(source (origin
(method url-fetch)
(uri (string-append "https://repo1.maven.org/maven2/"
version "-sources.jar"))
(sha256
(base32
- "191xw4lc7mjjkprh4ji5vnpjvr5r4zvbpwkriy4bvsjqrz35vh1j"))))
+ "1g560yr9v2kzv34gc2m3ifpgnj7krcdd6h4gd4z83pwqacwkfz0k"))))
(build-system ant-build-system)
(arguments
`(#:tests? #f ; no tests included
- #:jar-name "eclipse-jdt-core.jar"))
+ #:jar-name "eclipse-jdt-core.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'move-sources
+ (lambda _
+ (with-directory-excursion "src/jdtCompilerAdaptersrc/"
+ (for-each (lambda (file)
+ (install-file file (string-append "../" (dirname file))))
+ (find-files "." ".*")))
+ (delete-file-recursively "src/jdtCompilerAdaptersrc/")
+ #t))
+ (add-before 'build 'copy-resources
+ (lambda _
+ (with-directory-excursion "src"
+ (for-each (lambda (file)
+ (install-file file (string-append "../build/classes/" (dirname file))))
+ (find-files "." ".*.(props|properties|rsc)")))
+ #t)))))
(inputs
`(("java-eclipse-core-contenttype" ,java-eclipse-core-contenttype)
("java-eclipse-core-filesystem" ,java-eclipse-core-filesystem)
development tools.")
(license license:epl1.0)))
+(define-public java-eclipse-jdt-compiler-apt
+ (package
+ (name "java-eclipse-jdt-compiler-apt")
+ (version "1.3.400")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://repo1.maven.org/maven2/"
+ "org/eclipse/jdt/org.eclipse.jdt.compiler.apt/"
+ version "/org.eclipse.jdt.compiler.apt-"
+ version "-sources.jar"))
+ (sha256
+ (base32
+ "1s285k9p2ixdqrknb40jbbvw682n9a7l5lqpn583a8pvlzg2l6r8"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; no tests included
+ #:jar-name "eclipse-jdt-compiler-apt.jar"
+ #:jdk ,openjdk11))
+ (inputs
+ `(("java-eclipse-jdt-core" ,java-eclipse-jdt-core)))
+ (home-page "https://www.eclipse.org/jdt/apt/")
+ (synopsis "Annotation processing tool")
+ (description "APT stands for Annotation Processing Tool. APT provides a
+means for generating files and compiling new Java classes based on annotations
+found in your source code.")
+ (license license:epl2.0)))
+
(define-public java-javax-mail
(package
(name "java-javax-mail")
(modify-phases %standard-phases
(add-after 'install 'strip-jar-timestamps
(assoc-ref ant:%standard-phases 'strip-jar-timestamps))
+ (add-before 'configure 'fix-timestamp
+ (lambda _
+ (substitute* "configure"
+ (("^TIMESTAMP.*") "TIMESTAMP=19700101\n"))
+ #t))
(add-after 'configure 'fix-bin-ls
(lambda _
(substitute* (find-files "." "Makefile")
(add-before 'build 'fix-build-xml
(lambda _
(substitute* "build.xml"
- (("<exec") "<copy todir=\"${classes.dir}\">
+ (("target name=\"compile\">")
+ "target name=\"compile\">
+<copy todir=\"${classes.dir}\">
<fileset dir=\"tool/src/main/resources\">
<include name=\"**/*.stg\"/>
<include name=\"**/*.st\"/>
<include name=\"**/*.sti\"/>
<include name=\"**/STLexer.tokens\"/>
</fileset>
-</copy><exec"))
+</copy>"))
#t)))))
(native-inputs
`(("antlr" ,antlr2)
(add-before 'build 'fix-build-xml
(lambda _
(substitute* "build.xml"
- (("<exec") "<copy todir=\"${classes.dir}\">
+ (("target name=\"compile\">")
+ "target name=\"compile\">
+<copy todir=\"${classes.dir}\">
<fileset dir=\"tool/src/main/resources\">
<include name=\"**/*.stg\"/>
<include name=\"**/*.st\"/>
<include name=\"**/*.sti\"/>
<include name=\"**/STLexer.tokens\"/>
</fileset>
-</copy><exec"))
+</copy>"))
#t)))))
(native-inputs
`(("antlr" ,antlr2)
("antlr" ,antlr2)
("antlr3" ,antlr3-3.1)))))
-(define antlr3-3.1
+(define-public antlr3-3.1
(package
(inherit antlr3)
(version "3.1")
(add-before 'build 'fix-build-xml
(lambda _
(substitute* "build.xml"
- (("<exec") "<copy todir=\"${classes.dir}\">
+ (("target name=\"compile\">")
+ "target name=\"compile\">
+<copy todir=\"${classes.dir}\">
<fileset dir=\"src\">
<include name=\"**/*.stg\"/>
<include name=\"**/*.st\"/>
<include name=\"**/*.sti\"/>
<include name=\"**/STLexer.tokens\"/>
</fileset>
-</copy><exec"))
+</copy>"))
#t)))))
(native-inputs
`(("antlr" ,antlr2)))
(home-page "https://ops4j1.jira.com/wiki/spaces/ops4j/pages/12060312/Tinybundles")
(synopsis "Java APIs to create OSGi related artifacts")
(description "Tinybundles is all about creating OSGi related artifacts like
-Bundles, Fragments and Deployment Packages with Java Api. It is very convinient
+Bundles, Fragments and Deployment Packages with Java Api. It is very convenient
to create such artifacts on-the-fly inside Tests (like in Pax Exam). On the
other hand, this library can be a foundation of real end user tools that need
to create those artifacts.")
(native-inputs
`(("java-mockito-1" ,java-mockito-1)))))
+(define-public java-xmlunit-matchers
+ (package
+ (inherit java-xmlunit)
+ (name "java-xmlunit-matchers")
+ (arguments
+ `(#:jar-name "java-xmlunit-matchers.jar"
+ #:source-dir "xmlunit-matchers/src/main/java"
+ #:test-dir "xmlunit-matchers/src/test"
+ #:test-exclude
+ ;; Cannot open xsd for http://www.xmlunit.org/test-support/Book.xsd
+ (list "**/ValidationMatcherTest.java")
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'copy-test-class
+ (lambda _
+ (copy-file "xmlunit-core/src/test/java/org/xmlunit/TestResources.java"
+ "xmlunit-matchers/src/test/java/org/xmlunit/TestResources.java")
+ #t))
+ (add-before 'build 'fix-test-resources-path
+ (lambda _
+ (substitute* (find-files "xmlunit-matchers/src/test" ".*.java")
+ (("../test-resources") "test-resources"))
+ #t))
+ (add-before 'check 'copy-test-resources
+ (lambda* (#:key inputs #:allow-other-keys)
+ (copy-recursively (assoc-ref inputs "resources") "test-resources")
+ #t)))))
+ (inputs
+ `(("java-xmlunit" ,java-xmlunit)
+ ("java-junit" ,java-junit)))))
+
(define-public java-openchart2
(package
(name "java-openchart2")
("java-commons-net" ,java-commons-net)
("java-jsch" ,java-jsch)))
(home-page "http://commons.apache.org/proper/commons-vfs/")
- (synopsis "Java filesystem library")
+ (synopsis "Java file system library")
(description "Commons VFS provides a single API for accessing various
different file systems. It presents a uniform view of the files from various
different sources, such as the files on local disk, on an HTTP server, or
(name "java-eclipse-sisu-inject")
(version "0.3.3")
(source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/eclipse/sisu.inject/"
- "archive/releases/" version ".tar.gz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/eclipse/sisu.inject/")
+ (commit "releases/0.3.3")))
+ (file-name (git-file-name name version))
(sha256
(base32
- "11rg6yw5nl13i65xsp4jxxgr341qcnnaan48p767h28kb07s0ajn"))))
+ "0gibc9x0bw0f4ls086fx73610fcspz9g2as7kcpcfhvl5znysvg7"))))
(build-system ant-build-system)
(arguments
`(#:jar-name "eclipse-sisu-inject.jar"
(define-public java-eclipse-sisu-plexus
(package
(name "java-eclipse-sisu-plexus")
- (version "0.3.3")
+ (version "0.3.4")
(source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/eclipse/sisu.plexus/"
- "archive/releases/" version ".tar.gz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/eclipse/sisu.plexus.git")
+ (commit (string-append "releases/" version))))
+ (file-name (git-file-name name version))
(sha256
(base32
- "0lbj7nxy5j0z71k407zbb82icfqh7midrfk0fb3fa3jzdjz0d9d9"))
+ "17mjlajnsqnk07cc58h1qpxrif85yb2m2y0pyba48yjjgikk8r9f"))
(modules '((guix build utils)))
(snippet
'(begin
@code{@@tags}. It is designed to be used by active code generators or
documentation tools.")
(license license:asl2.0)))
+
+(define-public java-jgit
+ (package
+ (name "java-jgit")
+ (version "4.7.0.201704051617-r")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://repo1.maven.org/maven2/"
+ "org/eclipse/jgit/org.eclipse.jgit/"
+ version "/org.eclipse.jgit-"
+ version "-sources.jar"))
+ (sha256
+ (base32
+ "13ii4jn02ynzq6i7gsyi21k2i94jpc85wf6bcm31q4cyvzv0mk4k"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; There are no tests to run.
+ #:jar-name "jgit.jar"
+ ;; JGit must be built with a JDK supporting Java 8.
+ #:jdk ,icedtea-8
+ ;; Target our older default JDK.
+ #:make-flags (list "-Dtarget=1.7")
+ #:phases
+ (modify-phases %standard-phases
+ ;; The jar file generated by the default build.xml does not include
+ ;; the text properties files, so we need to add them.
+ (add-after 'build 'add-properties
+ (lambda* (#:key jar-name #:allow-other-keys)
+ (with-directory-excursion "src"
+ (apply invoke "jar" "-uf"
+ (string-append "../build/jar/" jar-name)
+ (find-files "." "\\.properties$")))
+ #t)))))
+ (inputs
+ `(("java-classpathx-servletapi" ,java-classpathx-servletapi)
+ ("java-javaewah" ,java-javaewah)
+ ("java-jsch" ,java-jsch)
+ ("java-slf4j-api" ,java-slf4j-api)))
+ (home-page "https://eclipse.org/jgit/")
+ (synopsis "Java library implementing the Git version control system")
+ (description "JGit is a lightweight, pure Java library implementing the
+Git version control system, providing repository access routines, support for
+network protocols, and core version control algorithms.")
+ (license license:edl1.0)))
+
+;; For axoloti. This package can still be built with icedtea-7, which is
+;; currently used as the default JDK.
+(define-public java-jgit-4.2
+ (package (inherit java-jgit)
+ (version "4.2.0.201601211800-r")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://repo1.maven.org/maven2/"
+ "org/eclipse/jgit/org.eclipse.jgit/"
+ version "/org.eclipse.jgit-"
+ version "-sources.jar"))
+ (sha256
+ (base32
+ "15gm537iivhnzlkjym4x3wn5jqdjdragsw9pdpzqqg21nrc817mm"))))
+ (build-system ant-build-system)
+ (arguments
+ (substitute-keyword-arguments (package-arguments java-jgit)
+ ;; Build for default JDK.
+ ((#:jdk _) icedtea-7)
+ ((#:phases phases)
+ `(modify-phases ,phases
+ (add-after 'unpack 'use-latest-javaewah-API
+ (lambda _
+ (substitute* "src/org/eclipse/jgit/internal/storage/file/BitmapIndexImpl.java"
+ (("wordinbits") "WORD_IN_BITS"))
+ #t))))))
+ (inputs
+ `(("java-javaewah" ,java-javaewah)
+ ("java-jsch" ,java-jsch)
+ ("java-slf4j-api" ,java-slf4j-api)))))
+
+(define-public abcl
+ (package
+ (name "abcl")
+ (version "1.5.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://abcl.org/releases/"
+ version "/abcl-src-" version ".tar.gz"))
+ (sha256
+ (base32
+ "1hhvcg050nfpjbdmskc1cv2j38qi6qfl77a61b5cxx576kbff3lj"))
+ (patches
+ (search-patches
+ "abcl-fix-build-xml.patch"))))
+ (build-system ant-build-system)
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (arguments
+ `(#:build-target "abcl.jar"
+ #:test-target "abcl.test"
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((share (string-append (assoc-ref outputs "out")
+ "/share/java/"))
+ (bin (string-append (assoc-ref outputs "out")
+ "/bin/")))
+ (mkdir-p share)
+ (install-file "dist/abcl.jar" share)
+ (install-file "dist/abcl-contrib.jar" share)
+ (mkdir-p bin)
+ (with-output-to-file (string-append bin "abcl")
+ (lambda _
+ (let ((classpath (string-append
+ share "abcl.jar"
+ ":"
+ share "abcl-contrib.jar")))
+ (display (string-append
+ "#!" (which "sh") "\n"
+ "if [[ -z $CLASSPATH ]]; then\n"
+ " cp=\"" classpath "\"\n"
+ "else\n"
+ " cp=\"" classpath ":$CLASSPATH\"\n"
+ "fi\n"
+ "exec " (which "java")
+ " -cp $cp org.armedbear.lisp.Main $@\n")))))
+ (chmod (string-append bin "abcl") #o755)
+ #t))))))
+ (home-page "https://abcl.org/")
+ (synopsis "Common Lisp Implementation on the JVM")
+ (description
+ "@dfn{Armed Bear Common Lisp} (ABCL) is a full implementation of the Common
+Lisp language featuring both an interpreter and a compiler, running in the
+JVM. It supports JSR-223 (Java scripting API): it can be a scripting engine
+in any Java application. Additionally, it can be used to implement (parts of)
+the application using Java to Lisp integration APIs.")
+ (license (list license:gpl2+
+ ;; named-readtables is released under 3 clause BSD
+ license:bsd-3
+ ;; jfli is released under CPL 1.0
+ license:cpl1.0))))
+
+(define-public java-jsonp-api
+ (package
+ (name "java-jsonp-api")
+ (version "1.1.5")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/eclipse-ee4j/jsonp")
+ (commit (string-append version "-RELEASE"))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0nxq16lrx7i87hgyj5rzcwilvr67h0i299gygfn8f5vs4n7n59vy"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "jsonp-api.jar"
+ #:tests? #f
+ #:source-dir "api/src/main/java"
+ #:test-dir "api/src/test"))
+ (home-page "https://eclipse-ee4j.github.io/jsonp/")
+ (synopsis "JSON Processing in Java")
+ (description "JSON Processing (JSON-P) is a Java API to process (e.g.
+parse, generate, transform and query) JSON messages. It produces and
+consumes JSON text in a streaming fashion (similar to StAX API for XML)
+and allows to build a Java object model for JSON text using API classes
+(similar to DOM API for XML).")
+ ;; either gpl2 only with classpath exception, or epl2.0.
+ (license (list license:gpl2
+ license:epl2.0))))
+
+(define-public java-jsonp-impl
+ (package
+ (inherit java-jsonp-api)
+ (name "java-jsonp-impl")
+ (arguments
+ `(#:jar-name "jsonp-impl.jar"
+ #:tests? #f
+ #:source-dir "impl/src/main/java"
+ #:test-dir "impl/src/test"))
+ (propagated-inputs
+ `(("java-jsonp-api" ,java-jsonp-api)))
+ (description "JSON Processing (JSON-P) is a Java API to process (e.g.
+parse, generate, transform and query) JSON messages. This package contains
+a reference implementation of that API.")))
+
+(define-public java-xmp
+ (package
+ (name "java-xmp")
+ (version "5.1.3")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://download.macromedia.com/pub/developer"
+ "/xmp/sdk/XMPCoreJava-" version ".zip"))
+ (sha256
+ (base32
+ "14nai2mmsg7l5ya2y5mx4w4lr1az3sk2fjz6hiy4zdrsavgvl1g7"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:build-target "build"
+ #:tests? #f; no tests
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _
+ (chdir "XMPCore")
+ #t))
+ (add-before 'build 'fix-timestamp
+ (lambda _
+ (substitute* "build.xml"
+ (("\\$\\{BuildDate\\}") "1970 Jan 01 00:00:00-GMT"))
+ #t))
+ (replace 'install
+ (install-jars "."))
+ (add-after 'install 'install-doc
+ (lambda* (#:key outputs #:allow-other-keys)
+ (copy-recursively
+ "docs"
+ (string-append (assoc-ref outputs "out") "/share/doc/java-xmp"))
+ #t)))))
+ (native-inputs
+ `(("unzip" ,unzip)))
+ (home-page "https://www.adobe.com/devnet/xmp.html")
+ (synopsis "Extensible Metadat Platform (XMP) support in Java")
+ (description "Adobe's Extensible Metadata Platform (XMP) is a labeling
+technology that allows you to embed data about a file, known as metadata,
+into the file itself. The XMP Toolkit for Java is based on the C++ XMPCore
+library and the API is similar.")
+ (license license:bsd-3)))
+
+(define-public java-metadata-extractor
+ (package
+ (name "java-metadata-extractor")
+ (version "2.11.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/drewnoakes/metadata-extractor")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "06yrq0swrl1r40yjbk5kqzjxr04jlkq9lfi711jvfgjf5kp2qinj"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "metadata-extractor.jar"
+ #:source-dir "Source"
+ #:test-dir "Tests"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'fix-test-dir
+ (lambda _
+ (substitute* "build.xml"
+ (("/java\">") "\">"))
+ #t)))))
+ (propagated-inputs
+ `(("java-xmp" ,java-xmp)))
+ (native-inputs
+ `(("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-junit" ,java-junit)))
+ (home-page "https://github.com/drewnoakes/metadata-extractor")
+ (synopsis "Extract metadata from image and video files")
+ (description "Metadata-extractor is a straightforward Java library for
+reading metadata from image files. It is able to read metadata in Exif,
+IPTC, XMP, ICC and more formats.")
+ (license license:asl2.0)))
+
+(define-public java-svg-salamander
+ (package
+ (name "java-svg-salamander")
+ (version "1.1.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/blackears/svgSalamander")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1zv3kjdkf6iqf02x6ln76254y634j2ji448y706a65lsbfjmmicf"))
+ (modules '((guix build utils)))
+ (snippet
+ `(for-each delete-file (find-files "." ".*.jar")))
+ (patches
+ (search-patches "java-svg-salamander-Fix-non-det.patch"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f; no tests
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _
+ (chdir "svg-core")
+ #t))
+ (add-before 'build 'copy-jars
+ (lambda* (#:key inputs #:allow-other-keys)
+ (copy-file (car (find-files (assoc-ref inputs "javacc") "\\.jar$"))
+ "../libraries/javacc.jar")
+ (copy-file (car (find-files (assoc-ref inputs "ant") "ant\\.jar$"))
+ "../libraries/ant.jar")
+ #t))
+ (replace 'install
+ (install-jars "dist")))))
+ (native-inputs
+ `(("javacc" ,javacc)))
+ (home-page "https://github.com/blackears/svgSalamander")
+ (synopsis "SVG engine for Java")
+ (description "SVG Salamander is an SVG engine for Java that's designed
+to be small, fast, and allow programmers to use it with a minimum of fuss.
+It's in particular targeted for making it easy to integrate SVG into Java
+games and making it much easier for artists to design 2D game content - from
+rich interactive menus to charts and graphcs to complex animations.")
+ (license license:bsd-2)))
+
+(define-public java-jboss-transaction-api-spec
+ (package
+ (name "java-jboss-transaction-api-spec")
+ (version "1.2+1.1.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/jboss/jboss-transaction-api_spec")
+ (commit "jboss-transaction-api_1.2_spec-1.1.1.Final")))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1xbfq5hvb86izflydxrqqv3k26c1ba2m0ap6m97shqrsdi9by4wy"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "java-jboss-transaction-api_spec.jar"
+ #:source-dir "src/main/java"
+ #:tests? #f)); no tests
+ (inputs
+ `(("java-cdi-api" ,java-cdi-api)
+ ("java-jboss-interceptors-api-spec" ,java-jboss-interceptors-api-spec)))
+ (home-page "https://github.com/jboss/jboss-transaction-api_spec")
+ (synopsis "Generic transaction management API in Java")
+ (description "Java-jboss-transaction-api-spec implements the Transactions
+API. A transaction is a unit of work containing one or more operations
+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))))