Package: guix-patches;
Reported by: Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de>
Date: Wed, 22 Nov 2017 11:23:02 UTC
Severity: normal
Tags: patch
Done: Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 29394 in the body.
You can then email your comments to 29394 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
View this report as an mbox folder, status mbox, maintainer mbox
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:23:02 GMT) Full text and rfc822 format available.Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de>
:guix-patches <at> gnu.org
.
(Wed, 22 Nov 2017 11:23:02 GMT) Full text and rfc822 format available.Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
From: Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de> To: <guix-patches <at> gnu.org> Subject: [PATCH 00/12] Add Java dependencies for FastQC Date: Wed, 22 Nov 2017 12:21:58 +0100
The following patch series adds dependencies for the popular bioinfo tool FastQC. Ricardo Wurmus (12): gnu: Add java-snappy-1. gnu: Add javacc. gnu: Add javacc-4. gnu: Add java-commons-jexl-2. gnu: java-htsjdk: Update to 2.3.0. gnu: Add java-picard. gnu: Add java-cofoja. gnu: Add java-commons-bcel. gnu: Add ant-apache-bcel. gnu: Add ant-junit. gnu: Add java-picard-1.113. gnu: Add java-jbzip2. gnu/packages/bioinformatics.scm | 216 +++++++++++++++++++++++++++++++- gnu/packages/compression.scm | 98 +++++++++++++++ gnu/packages/java.scm | 268 ++++++++++++++++++++++++++++++++++++++++ 3 files changed, 576 insertions(+), 6 deletions(-) -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:32:01 GMT) Full text and rfc822 format available.Message #8 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 01/12] gnu: Add java-snappy-1. Date: Wed, 22 Nov 2017 12:30:31 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/compression.scm (java-snappy-1): New variable. --- gnu/packages/compression.scm | 58 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm index 748c75a74..193d36797 100644 --- a/gnu/packages/compression.scm +++ b/gnu/packages/compression.scm @@ -1206,6 +1206,64 @@ install: libbitshuffle.so compresser/decompresser.") (license license:asl2.0))) +(define-public java-snappy-1 + (package + (inherit java-snappy) + (version "1.0.3-rc3") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/xerial/snappy-java/archive/" + "snappy-java-" version ".tar.gz")) + (sha256 + (base32 + "08hsxlqidiqck0q57fshwyv3ynyxy18vmhrai9fyc8mz17m7gsa3")))) + (arguments + `(#:jar-name "snappy.jar" + #:source-dir "src/main/java" + #:phases + (modify-phases %standard-phases + (add-before 'build 'remove-binaries + (lambda _ + (delete-file "lib/org/xerial/snappy/OSInfo.class") + (delete-file-recursively "src/main/resources/org/xerial/snappy/native") + #t)) + (add-before 'build 'build-jni + (lambda _ + ;; Rebuild one of the binaries we removed earlier + (system* "javac" "src/main/java/org/xerial/snappy/OSInfo.java" + "-d" "lib") + ;; Link to the dynamic snappy, not the static ones + (substitute* "Makefile.common" + (("-shared") "-shared -lsnappy")) + (substitute* "Makefile" + ;; Don't download the sources here. + (("\\$\\(SNAPPY_UNPACKED\\) ") "") + ((": \\$\\(SNAPPY_UNPACKED\\) ") ":") + ;; What we actually want to build + (("SNAPPY_OBJ:=.*") + "SNAPPY_OBJ:=$(addprefix $(SNAPPY_OUT)/, SnappyNative.o)\n") + ;; Since we removed the directory structure in "native" during + ;; the previous phase, we need to recreate it. + (("NAME\\): \\$\\(SNAPPY_OBJ\\)") + "NAME): $(SNAPPY_OBJ)\n\t <at> mkdir -p $(@D)")) + ;; Finally we can run the Makefile to build the dynamic library. + (zero? (system* "make" "native")))) + ;; Once we have built the shared library, we need to place it in the + ;; "build" directory so it can be added to the jar file. + (add-after 'build-jni 'copy-jni + (lambda _ + (copy-recursively "src/main/resources/org/xerial/snappy/native" + "build/classes/org/xerial/snappy/native") + #t)) + (add-before 'check 'fix-tests + (lambda _ + (mkdir-p "src/test/resources/org/xerial/snappy/") + (copy-recursively "src/test/java/org/xerial/snappy/testdata" + "src/test/resources/org/xerial/snappy/testdata") + (install-file "src/test/java/org/xerial/snappy/alice29.txt" + "src/test/resources/org/xerial/snappy/") + #t))))))) + (define-public java-iq80-snappy (package (name "java-iq80-snappy") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:32:02 GMT) Full text and rfc822 format available.Message #11 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 02/12] gnu: Add javacc. Date: Wed, 22 Nov 2017 12:30:32 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (javacc): New variable. --- gnu/packages/java.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index bd6c00365..eae4aa750 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1893,6 +1893,38 @@ designs.") license:asl2.0 license:cpl1.0))))) +(define-public javacc + (package + (name "javacc") + (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")))) + (build-system ant-build-system) + (arguments + `(#:test-target "test" + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'delete-bundled-libs + (lambda _ + (delete-file-recursively "lib") #t)) + (replace 'install (install-jars "target"))))) + (home-page "https://javacc.org/") + (synopsis "Java parser generator") + (description "Java Compiler Compiler (JavaCC) is the most popular parser +generator for use with Java applications. A parser generator is a tool that +reads a grammar specification and converts it to a Java program that can +recognize matches to the grammar. In addition to the parser generator itself, +JavaCC provides other standard capabilities related to parser generation such +as tree building (via a tool called JJTree included with JavaCC), actions, +debugging, etc.") + (license license:bsd-3))) + (define-public java-classpathx-servletapi (package (name "java-classpathx-servletapi") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:32:02 GMT) Full text and rfc822 format available.Message #14 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 03/12] gnu: Add javacc-4. Date: Wed, 22 Nov 2017 12:30:33 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (javacc-4): New variable. --- gnu/packages/java.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index eae4aa750..2691f2f39 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1925,6 +1925,30 @@ as tree building (via a tool called JJTree included with JavaCC), actions, debugging, etc.") (license license:bsd-3))) +(define-public javacc-4 + (package (inherit javacc) + (version "4.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/javacc/javacc.git") + (commit "release_41"))) + (file-name (string-append "javacc-" version "-checkout")) + (sha256 + (base32 + "07ysav7j8r1c6h8qxrgqk6lwdp74ly0ad1935lragxml0qqc3ka0")))) + ;; Tests fail with + ;; /tmp/guix-build-javacc-4.1.drv-0/source/test/javacodeLA/build.xml:60: + ;; JAVACODE failed + (arguments + `(#:tests? #f + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'delete-bundled-libs + (lambda _ + (delete-file-recursively "lib") #t)) + (replace 'install (install-jars "bin/lib"))))))) + (define-public java-classpathx-servletapi (package (name "java-classpathx-servletapi") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:32:03 GMT) Full text and rfc822 format available.Message #17 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 04/12] gnu: Add java-commons-jexl-2. Date: Wed, 22 Nov 2017 12:30:34 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (java-commons-jexl-2): New variable. --- gnu/packages/java.scm | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 2691f2f39..f78f63c72 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -6991,6 +6991,63 @@ In addition to the expression language, MVEL serves as a templating language for configuration and string construction.") (license license:asl2.0))) +(define-public java-commons-jexl-2 + (package + (name "java-commons-jexl") + (version "2.1.1") + (source (origin + (method url-fetch) + (uri (string-append "mirror://apache/commons/jexl/source/" + "commons-jexl-" version "-src.tar.gz")) + (sha256 + (base32 + "1ai7632bwwaxglb0nbpblpr2jw5g20afrsaq372ipkphi3ncy1jz")))) + (build-system ant-build-system) + (arguments + `(#:jar-name "commons-jexl-2.jar" + #:jdk ,icedtea-8 + #:source-dir "src/main/java" + #:phases + (modify-phases %standard-phases + (add-before 'check 'disable-broken-tests + (lambda* (#:key inputs #:allow-other-keys) + (with-directory-excursion "src/test/java/org/apache/commons/jexl2/" + (substitute* "ArithmeticTest.java" + (("asserter.assertExpression\\(\"3 / 0\"") "//") + (("asserter.assertExpression\\(\"imanull") "//")) + ;; This test fails with "ambiguous method invocation" + (delete-file "CacheTest.java") + ;; This test doesn't have access to the temp directory + (substitute* "ClassCreatorTest.java" + (("java.io.tmpdir") "user.dir")) + ;; This test fails in trying to detect whether it can run. + (substitute* "ClassCreator.java" + (("boolean canRun =.*") "boolean canRun = false;\n")) + ;; ...and these tests depend on it. + (delete-file "scripting/JexlScriptEngineOptionalTest.java") + (delete-file "scripting/JexlScriptEngineTest.java")) + #t)) + (add-before 'build 'run-javacc + (lambda _ + (with-directory-excursion "src/main/java/org/apache/commons/jexl2/parser/" + (and (zero? (system* "java" "jjtree" "Parser.jjt")) + (zero? (system* "java" "javacc" "Parser.jj"))))))))) + (inputs + `(("java-commons-logging-minimal" ,java-commons-logging-minimal))) + (native-inputs + `(("java-junit" ,java-junit) + ("java-hamcrest-core" ,java-hamcrest-core) + ("javacc" ,javacc-4))) + (home-page "https://commons.apache.org/proper/commons-jexl/") + (synopsis "Java Expression Language ") + (description "JEXL is a library intended to facilitate the implementation +of dynamic and scripting features in applications and frameworks written in +Java. JEXL implements an Expression Language based on some extensions to the +JSTL Expression Language supporting most of the constructs seen in +shell-script or ECMAScript. Its goal is to expose scripting features usable +by technical operatives or consultants working with enterprise platforms.") + (license license:asl2.0))) + (define-public java-lz4 (package (name "java-lz4") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:33:02 GMT) Full text and rfc822 format available.Message #20 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 05/12] gnu: java-htsjdk: Update to 2.3.0. Date: Wed, 22 Nov 2017 12:30:35 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/bioinformatics.scm (java-htsjdk): Update to 2.3.0. [arguments]: Build with JDK 8. [inputs]: Add java-ngs, java-snappy, java-commons-compress, java-commons-logging-minimal, java-commons-jexl-2, and java-xz. [native-inputs]: Add java-testng. --- gnu/packages/bioinformatics.scm | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index a8d7361ff..6c71d7362 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -2961,7 +2961,7 @@ from high-throughput sequencing assays.") (define-public java-htsjdk (package (name "java-htsjdk") - (version "1.129") + (version "2.3.0") ; last version without build dependency on gradle (source (origin (method url-fetch) (uri (string-append @@ -2970,15 +2970,18 @@ from high-throughput sequencing assays.") (file-name (string-append name "-" version ".tar.gz")) (sha256 (base32 - "0asdk9b8jx2ij7yd6apg9qx03li8q7z3ml0qy2r2qczkra79y6fw")) + "1ibhzzxsfc38nqyk9r8zqj6blfc1kh26iirypd4q6n90hs2m6nyq")) (modules '((guix build utils))) - ;; remove build dependency on git - (snippet '(substitute* "build.xml" - (("failifexecutionfails=\"true\"") - "failifexecutionfails=\"false\""))))) + (snippet + ;; Delete pre-built binaries + '(begin + (delete-file-recursively "lib") + (mkdir-p "lib") + #t)))) (build-system ant-build-system) (arguments `(#:tests? #f ; test require Internet access + #:jdk ,icedtea-8 #:make-flags (list (string-append "-Ddist=" (assoc-ref %outputs "out") "/share/java/htsjdk/")) @@ -2987,6 +2990,15 @@ from high-throughput sequencing assays.") (modify-phases %standard-phases ;; The build phase also installs the jars (delete 'install)))) + (inputs + `(("java-ngs" ,java-ngs) + ("java-snappy-1" ,java-snappy-1) + ("java-commons-compress" ,java-commons-compress) + ("java-commons-logging-minimal" ,java-commons-logging-minimal) + ("java-commons-jexl-2" ,java-commons-jexl-2) + ("java-xz" ,java-xz))) + (native-inputs + `(("java-testng" ,java-testng))) (home-page "http://samtools.github.io/htsjdk/") (synopsis "Java API for high-throughput sequencing data (HTS) formats") (description -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:34:01 GMT) Full text and rfc822 format available.Message #23 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 06/12] gnu: Add java-picard. Date: Wed, 22 Nov 2017 12:30:36 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/bioinformatics.scm (java-picard): New variable. --- gnu/packages/bioinformatics.scm | 78 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 6c71d7362..0896edf25 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -3008,6 +3008,84 @@ sequencing (HTS) data. There are also an number of useful utilities for manipulating HTS data.") (license license:expat))) +;; This version matches java-htsjdk 2.3.0. Later versions also require a more +;; recent version of java-htsjdk, which depends on gradle. +(define-public java-picard + (package + (name "java-picard") + (version "2.3.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/broadinstitute/picard.git") + (commit version))) + (file-name (string-append "java-picard-" version "-checkout")) + (sha256 + (base32 + "1ll7mf4r3by92w2nhlmpa591xd1f46xlkwh59mq6fvbb5pdwzvx6")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Delete pre-built binaries. + (delete-file-recursively "lib") + (mkdir-p "lib") + (substitute* "build.xml" + ;; Remove build-time dependency on git. + (("failifexecutionfails=\"true\"") + "failifexecutionfails=\"false\"") + ;; Use our htsjdk. + (("depends=\"compile-htsjdk, ") + "depends=\"") + (("depends=\"compile-htsjdk-tests, ") + "depends=\"") + ;; Build picard-lib.jar before building picard.jar + (("name=\"picard-jar\" depends=\"" line) + (string-append line "picard-lib-jar, "))) + #t)))) + (build-system ant-build-system) + (arguments + `(#:build-target "picard-jar" + #:test-target "test" + ;; Tests require jacoco:coverage. + #:tests? #f + #:make-flags + (list (string-append "-Dhtsjdk_lib_dir=" + (assoc-ref %build-inputs "java-htsjdk") + "/share/java/htsjdk/") + "-Dhtsjdk-classes=dist/tmp" + (string-append "-Dhtsjdk-version=" + ,(package-version java-htsjdk))) + #:jdk ,icedtea-8 + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'use-our-htsjdk + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "build.xml" + (("\\$\\{htsjdk\\}/lib") + (string-append (assoc-ref inputs "java-htsjdk") + "/share/java/htsjdk/"))) + #t)) + (add-after 'unpack 'make-test-target-independent + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "build.xml" + (("name=\"test\" depends=\"compile, ") + "name=\"test\" depends=\"")) + #t)) + (replace 'install (install-jars "dist"))))) + (inputs + `(("java-htsjdk" ,java-htsjdk) + ("java-guava" ,java-guava))) + (native-inputs + `(("java-testng" ,java-testng))) + (home-page "http://broadinstitute.github.io/picard/") + (synopsis "Tools for manipulating high-throughput sequencing data and formats") + (description "Picard is a set of Java command line tools for manipulating +high-throughput sequencing (HTS) data and formats. Picard is implemented +using the HTSJDK Java library to support accessing file formats that are +commonly used for high-throughput sequencing data such as SAM, BAM, CRAM and +VCF.") + (license license:expat))) + (define-public htslib (package (name "htslib") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:34:02 GMT) Full text and rfc822 format available.Message #26 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 07/12] gnu: Add java-cofoja. Date: Wed, 22 Nov 2017 12:30:37 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (java-cofoja): New variable. --- gnu/packages/java.scm | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index f78f63c72..0cc9adf19 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -6515,6 +6515,62 @@ provides control over value quantization behavior across the value range and the subsequent value resolution at any given level.") (license license:public-domain))) +(define-public java-cofoja + (package + (name "java-cofoja") + (version "1.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/nhatminhle/cofoja.git") + (commit (string-append "v" version)))) + (file-name (string-append "java-cofoja-" version "-checkout")) + (sha256 + (base32 + "0p7sz8y5xgpi5rx1qwn6587fkd52qr3ha3ybh14gqcyxhikl525w")))) + (build-system ant-build-system) + (arguments + `(#:build-target "dist" + #:test-target "test" + #:jdk ,icedtea-8 + #:make-flags + (list "-Ddist.dir=dist") + #:modules ((guix build ant-build-system) + (guix build java-utils) + (guix build utils) + (srfi srfi-1) + (ice-9 match)) + #:phases + (modify-phases %standard-phases + ;; The bulid system ignores the class path the ant-build-system sets + ;; up and instead expects to find all dependencies in the "lib" + ;; directory. + (add-after 'unpack 'create-libdir + (lambda* (#:key inputs #:allow-other-keys) + (mkdir-p "lib") + (for-each + (lambda (file) + (let ((target (string-append "lib/" (basename file)))) + (unless (file-exists? target) + (symlink file target)))) + (append-map (match-lambda + ((label . dir) + (find-files dir "\\.jar$"))) + inputs)) + #t)) + (replace 'install (install-jars "dist"))))) + (inputs + `(("java-asm" ,java-asm))) + (native-inputs + `(("java-junit" ,java-junit))) + (home-page "https://github.com/nhatminhle/cofoja") + (synopsis "Contracts for Java") + (description "Contracts for Java, or Cofoja for short, is a contract +programming framework and test tool for Java, which uses annotation processing +and bytecode instrumentation to provide run-time checking. (In particular, +this is not a static analysis tool.)") + (license license:lgpl3+))) + (define-public java-aopalliance (package (name "java-aopalliance") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:34:02 GMT) Full text and rfc822 format available.Message #29 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 08/12] gnu: Add java-commons-bcel. Date: Wed, 22 Nov 2017 12:30:38 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (java-commons-bcel): New variable. --- gnu/packages/java.scm | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index 0cc9adf19..d37a76aef 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -7235,6 +7235,41 @@ for high performance inter-thread communication that avoids the need for message queues or resource locking.") (license license:asl2.0))) +(define-public java-commons-bcel + (package + (name "java-commons-bcel") + (version "6.1") + (source (origin + (method url-fetch) + (uri (string-append "mirror://apache/commons/bcel/source/bcel-" + version "-src.tar.gz")) + (sha256 + (base32 + "0j3x1rxd673k07psclk8k13rqh0x0mf2yy5qiwkiw4z3afa568jy")))) + (build-system ant-build-system) + (arguments + `(#:jar-name "bcel.jar" + #:jdk ,icedtea-8 + #:source-dir "src/main/java" + #:test-dir "src/test/java" + ;; FIXME: Tests require the unpackaged jna. + #:tests? #f)) + (home-page "https://commons.apache.org/proper/commons-bcel/") + (synopsis "Byte code engineering library") + (description "The Byte Code Engineering Library (Apache Commons BCEL) is +intended to give users a convenient way to analyze, create, and +manipulate (binary) Java class files. Classes are represented by objects +which contain all the symbolic information of the given class: methods, fields +and byte code instructions, in particular. + +Such objects can be read from an existing file, be transformed by a +program (e.g. a class loader at run-time) and written to a file again. An +even more interesting application is the creation of classes from scratch at +run-time. The @dfn{Byte Code Engineering Library} (BCEL) may be also useful +if you want to learn about the @dfn{Java Virtual Machine} (JVM) and the format +of Java @code{.class} files.") + (license license:asl2.0))) + (define-public java-xerial-core (package (name "java-xerial-core") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:35:02 GMT) Full text and rfc822 format available.Message #32 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 09/12] gnu: Add ant-apache-bcel. Date: Wed, 22 Nov 2017 12:30:39 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (ant-apache-bcel): New variable. --- gnu/packages/java.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index d37a76aef..eca23d9da 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1752,6 +1752,38 @@ IcedTea build harness.") (native-inputs `(("jdk" ,icedtea-7 "jdk"))))) +(define-public ant-apache-bcel + (package + (inherit ant/java8) + (name "ant-apache-bcel") + (arguments + (substitute-keyword-arguments (package-arguments ant/java8) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'unpack 'link-bcel + (lambda* (#:key inputs #:allow-other-keys) + (for-each (lambda (file) + (symlink file + (string-append "lib/optional/" + (basename file)))) + (find-files (assoc-ref inputs "java-commons-bcel") + "\\.jar$")) + #t)) + (add-after 'build 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (share (string-append out "/share/java")) + (bin (string-append out "/bin")) + (lib (string-append out "/lib"))) + (mkdir-p share) + (install-file (string-append lib "/ant-apache-bcel.jar") share) + (delete-file-recursively bin) + (delete-file-recursively lib) + #t))))))) + (inputs + `(("java-commons-bcel" ,java-commons-bcel) + ,@(package-inputs ant/java8))))) + (define-public clojure (let* ((remove-archives '(begin (for-each delete-file -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:35:02 GMT) Full text and rfc822 format available.Message #35 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 10/12] gnu: Add ant-junit. Date: Wed, 22 Nov 2017 12:30:40 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/java.scm (ant-junit): New variable. --- gnu/packages/java.scm | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index eca23d9da..8cf723074 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1784,6 +1784,38 @@ IcedTea build harness.") `(("java-commons-bcel" ,java-commons-bcel) ,@(package-inputs ant/java8))))) +(define-public ant-junit + (package + (inherit ant/java8) + (name "ant-junit") + (arguments + (substitute-keyword-arguments (package-arguments ant/java8) + ((#:phases phases) + `(modify-phases ,phases + (add-after 'unpack 'link-junit + (lambda* (#:key inputs #:allow-other-keys) + (for-each (lambda (file) + (symlink file + (string-append "lib/optional/" + (basename file)))) + (find-files (assoc-ref inputs "java-junit") + "\\.jar$")) + #t)) + (add-after 'build 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (share (string-append out "/share/java")) + (bin (string-append out "/bin")) + (lib (string-append out "/lib"))) + (mkdir-p share) + (install-file (string-append lib "/ant-junit.jar") share) + (delete-file-recursively bin) + (delete-file-recursively lib) + #t))))))) + (inputs + `(("java-junit" ,java-junit) + ,@(package-inputs ant/java8))))) + (define-public clojure (let* ((remove-archives '(begin (for-each delete-file -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:35:03 GMT) Full text and rfc822 format available.Message #38 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 11/12] gnu: Add java-picard-1.113. Date: Wed, 22 Nov 2017 12:30:41 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/bioinformatics.scm (java-picard-1.113): New variable. --- gnu/packages/bioinformatics.scm | 114 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm index 0896edf25..16e20c189 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -3086,6 +3086,120 @@ commonly used for high-throughput sequencing data such as SAM, BAM, CRAM and VCF.") (license license:expat))) +;; This is the last version of Picard to provide net.sf.samtools +(define-public java-picard-1.113 + (package (inherit java-picard) + (name "java-picard") + (version "1.113") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/broadinstitute/picard.git") + (commit version))) + (file-name (string-append "java-picard-" version "-checkout")) + (sha256 + (base32 + "0lkpvin2fz3hhly4l02kk56fqy8lmlgyzr9kmvljk6ry6l1hw973")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Delete pre-built binaries. + (delete-file-recursively "lib") + (mkdir-p "lib") + #t)))) + (build-system ant-build-system) + (arguments + `(#:build-target "picard-jar" + #:test-target "test" + ;; FIXME: the class path at test time is wrong. + ;; [testng] Error: A JNI error has occurred, please check your installation and try again + ;; [testng] Exception in thread "main" java.lang.NoClassDefFoundError: com/beust/jcommander/ParameterException + #:tests? #f + #:jdk ,icedtea-8 + ;; This is only used for tests. + #:make-flags + (list "-Dsamjdk.intel_deflater_so_path=lib/jni/libIntelDeflater.so") + #:phases + (modify-phases %standard-phases + ;; Do not use bundled ant bzip2. + (add-after 'unpack 'use-ant-bzip + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "build.xml" + (("\\$\\{lib\\}/apache-ant-1.8.2-bzip2.jar") + (string-append (assoc-ref inputs "ant") + "/lib/ant.jar"))) + #t)) + (add-after 'unpack 'make-test-target-independent + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "build.xml" + (("name=\"test\" depends=\"compile, ") + "name=\"test\" depends=\"compile-tests, ") + (("name=\"compile\" depends=\"compile-src, compile-tests\"") + "name=\"compile\" depends=\"compile-src\"")) + #t)) + (add-after 'unpack 'fix-deflater-path + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "src/java/net/sf/samtools/Defaults.java" + (("getStringProperty\\(\"intel_deflater_so_path\", null\\)") + (string-append "getStringProperty(\"intel_deflater_so_path\", \"" + (assoc-ref outputs "out") + "/lib/jni/libIntelDeflater.so" + "\")"))) + #t)) + ;; Build the deflater library, because we've previously deleted the + ;; pre-built one. This can only be built with access to the JDK + ;; sources. + (add-after 'build 'build-jni + (lambda* (#:key inputs #:allow-other-keys) + (mkdir-p "lib/jni") + (mkdir-p "jdk-src") + (and (zero? (system* "tar" "--strip-components=1" "-C" "jdk-src" + "-xf" (assoc-ref inputs "jdk-src"))) + (zero? (system* "javah" "-jni" + "-classpath" "classes" + "-d" "lib/" + "net.sf.samtools.util.zip.IntelDeflater")) + (with-directory-excursion "src/c/inteldeflater" + (zero? (system* "gcc" "-I../../../lib" "-I." + (string-append "-I" (assoc-ref inputs "jdk") + "/include/linux") + "-I../../../jdk-src/src/share/native/common/" + "-I../../../jdk-src/src/solaris/native/common/" + "-c" "-O3" "-fPIC" "IntelDeflater.c")) + (zero? (system* "gcc" "-shared" + "-o" "../../../lib/jni/libIntelDeflater.so" + "IntelDeflater.o" "-lz" "-lstdc++")))))) + ;; We can only build everything else after building the JNI library. + (add-after 'build-jni 'build-rest + (lambda* (#:key make-flags #:allow-other-keys) + (zero? (apply system* `("ant" "all" ,@make-flags))))) + (add-before 'build 'set-JAVA6_HOME + (lambda _ + (setenv "JAVA6_HOME" (getenv "JAVA_HOME")) + #t)) + (replace 'install (install-jars "dist")) + (add-after 'install 'install-jni-lib + (lambda* (#:key outputs #:allow-other-keys) + (let ((jni (string-append (assoc-ref outputs "out") + "/lib/jni"))) + (mkdir-p jni) + (install-file "lib/jni/libIntelDeflater.so" jni) + #t)))))) + (inputs + `(("java-snappy-1" ,java-snappy-1) + ("java-commons-jexl-2" ,java-commons-jexl-2) + ("java-cofoja" ,java-cofoja) + ("ant" ,ant) ; for bzip2 support at runtime + ("zlib" ,zlib))) + (native-inputs + `(("ant-apache-bcel" ,ant-apache-bcel) + ("ant-junit" ,ant-junit) + ("java-testng" ,java-testng) + ("java-commons-bcel" ,java-commons-bcel) + ("java-jcommander" ,java-jcommander) + ("jdk" ,icedtea-8 "jdk") + ("jdk-src" ,(car (assoc-ref (package-native-inputs icedtea-8) "jdk-drop"))))))) + (define-public htslib (package (name "htslib") -- 2.14.1
guix-patches <at> gnu.org
:bug#29394
; Package guix-patches
.
(Wed, 22 Nov 2017 11:35:03 GMT) Full text and rfc822 format available.Message #41 received at 29394 <at> debbugs.gnu.org (full text, mbox):
From: <ricardo.wurmus <at> mdc-berlin.de> To: <29394 <at> debbugs.gnu.org> Cc: Ricardo Wurmus <rekado <at> elephly.net> Subject: [PATCH 12/12] gnu: Add java-jbzip2. Date: Wed, 22 Nov 2017 12:30:42 +0100
From: Ricardo Wurmus <rekado <at> elephly.net> * gnu/packages/compression.scm (java-jbzip2): New variable. --- gnu/packages/compression.scm | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm index 193d36797..4ea4b105f 100644 --- a/gnu/packages/compression.scm +++ b/gnu/packages/compression.scm @@ -1314,6 +1314,46 @@ Java. This compression code produces a byte-for-byte exact copy of the output created by the original C++ code, and extremely fast.") (license license:asl2.0))) +(define-public java-jbzip2 + (package + (name "java-jbzip2") + (version "0.9.1") + (source (origin + (method url-fetch) + (uri (string-append "https://storage.googleapis.com/" + "google-code-archive-source/v2/" + "code.google.com/jbzip2/" + "source-archive.zip")) + (file-name (string-append name "-" version ".zip")) + (sha256 + (base32 + "0ncmhlqmrfmj96nqf6p77b9ws35lcfsvpfxzwxi2asissc83z1l3")))) + (build-system ant-build-system) + (native-inputs + `(("unzip" ,unzip) + ("java-junit" ,java-junit))) + (arguments + `(#:tests? #f ; no tests + #:jar-name "jbzip2.jar" + #:source-dir "tags/release-0.9.1/src" + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-encoding-problems + (lambda _ + ;; Some of the files we're patching are + ;; ISO-8859-1-encoded, so choose it as the default + ;; encoding so the byte encoding is preserved. + (with-fluids ((%default-port-encoding #f)) + (substitute* "tags/release-0.9.1/src/org/itadaki/bzip2/HuffmanAllocator.java" + (("Milidi.") "Milidiu"))) + #t))))) + (home-page "https://code.google.com/archive/p/jbzip2/") + (synopsis "Java bzip2 compression/decompression library") + (description "Jbzip2 is a Java bzip2 compression/decompression library. +It can be used as a replacement for the Apache @code{CBZip2InputStream} / +@code{CBZip2OutputStream} classes.") + (license license:expat))) + (define-public p7zip (package (name "p7zip") -- 2.14.1
Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de>
:Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de>
:Message #46 received at 29394-done <at> debbugs.gnu.org (full text, mbox):
From: Ricardo Wurmus <ricardo.wurmus <at> mdc-berlin.de> To: <29394-done <at> debbugs.gnu.org> Subject: Re: [PATCH 12/12] gnu: Add java-jbzip2. Date: Mon, 27 Nov 2017 21:56:21 +0100
Pushed them all to the master branch. -- Ricardo
Debbugs Internal Request <help-debbugs <at> gnu.org>
to internal_control <at> debbugs.gnu.org
.
(Tue, 26 Dec 2017 12:24:06 GMT) Full text and rfc822 format available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.