* bug#26803: [PATCH 02/36] ant-build-system: Add default "check" target.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:28 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 03/36] guix: Add java-utils Ricardo Wurmus
` (34 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* guix/build-system/ant.scm (ant-build): Change default test target to
"check"; add "test-dir" argument.
* guix/build/ant-build-system.scm (default-build.xml): Add "test-dir"
argument; add ant targets "compile-tests" and "check".
(configure): Add "test-dir" argument; pass it to "default-build.xml".
---
guix/build-system/ant.scm | 4 +++-
guix/build/ant-build-system.scm | 40 +++++++++++++++++++++++++++++++++++++---
2 files changed, 40 insertions(+), 4 deletions(-)
diff --git a/guix/build-system/ant.scm b/guix/build-system/ant.scm
index a309a0c86..bf2f3b411 100644
--- a/guix/build-system/ant.scm
+++ b/guix/build-system/ant.scm
@@ -93,12 +93,13 @@
(define* (ant-build store name inputs
#:key
(tests? #t)
- (test-target "tests")
+ (test-target "check")
(configure-flags ''())
(make-flags ''())
(build-target "jar")
(jar-name #f)
(source-dir "src")
+ (test-dir "src/test")
(phases '(@ (guix build ant-build-system)
%standard-phases))
(outputs '("out"))
@@ -128,6 +129,7 @@
#:build-target ,build-target
#:jar-name ,jar-name
#:source-dir ,source-dir
+ #:test-dir ,test-dir
#:phases ,phases
#:outputs %outputs
#:search-paths ',(map search-path-specification->sexp
diff --git a/guix/build/ant-build-system.scm b/guix/build/ant-build-system.scm
index 8ec7a9486..4042630a1 100644
--- a/guix/build/ant-build-system.scm
+++ b/guix/build/ant-build-system.scm
@@ -36,7 +36,7 @@
;; Code:
(define* (default-build.xml jar-name prefix #:optional
- (source-dir "."))
+ (source-dir ".") (test-dir "./test"))
"Create a simple build.xml with standard targets for Ant."
(call-with-output-file "build.xml"
(lambda (port)
@@ -48,6 +48,10 @@
(value "${basedir}/build/jar")))
(property (@ (name "dist.dir")
(value ,prefix)))
+ (property (@ (name "test.home")
+ (value ,test-dir)))
+ (property (@ (name "test.classes.dir")
+ (value "${basedir}/build/test-classes")))
;; respect the CLASSPATH environment variable
(property (@ (name "build.sysclasspath")
@@ -63,6 +67,35 @@
(destdir "${classes.dir}")
(classpath (@ (refid "classpath"))))))
+ (target (@ (name "compile-tests"))
+ (mkdir (@ (dir "${test.classes.dir}")))
+ (javac (@ (includeantruntime "false")
+ (srcdir ,test-dir)
+ (destdir "${test.classes.dir}"))
+ (classpath
+ (pathelement (@ (path "${env.CLASSPATH}")))
+ (pathelement (@ (location "${classes.dir}")))
+ (pathelement (@ (location "${test.classes.dir}"))))))
+
+ (target (@ (name "check")
+ (depends "compile-tests"))
+ (mkdir (@ (dir "${test.home}/test-reports")))
+ (junit (@ (printsummary "true")
+ (showoutput "true")
+ (fork "yes")
+ (haltonfailure "yes"))
+ (classpath
+ (pathelement (@ (path "${env.CLASSPATH}")))
+ (pathelement (@ (location "${test.home}/resources")))
+ (pathelement (@ (location "${classes.dir}")))
+ (pathelement (@ (location "${test.classes.dir}"))))
+ (formatter (@ (type "plain")
+ (usefile "true")))
+ (batchtest (@ (fork "yes")
+ (todir "${test.home}/test-reports"))
+ (fileset (@ (dir "${test.home}/java"))
+ (include (@ (name "**/*Test.java" )))))))
+
(target (@ (name "jar")
(depends "compile"))
(mkdir (@ (dir "${jar.dir}")))
@@ -99,12 +132,13 @@ to the default GNU unpack strategy."
((assq-ref gnu:%standard-phases 'unpack) #:source source)))
(define* (configure #:key inputs outputs (jar-name #f)
- (source-dir "src") #:allow-other-keys)
+ (source-dir "src")
+ (test-dir "src/test") #:allow-other-keys)
(when jar-name
(default-build.xml jar-name
(string-append (assoc-ref outputs "out")
"/share/java")
- source-dir))
+ source-dir test-dir))
(setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
(setenv "CLASSPATH" (generate-classpath inputs)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 02/36] ant-build-system: Add default "check" target.
2017-05-06 15:35 ` bug#26803: [PATCH 02/36] ant-build-system: Add default "check" target Ricardo Wurmus
@ 2017-05-06 20:28 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:28 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * guix/build-system/ant.scm (ant-build): Change default test target to
> "check"; add "test-dir" argument.
> * guix/build/ant-build-system.scm (default-build.xml): Add "test-dir"
> argument; add ant targets "compile-tests" and "check".
> (configure): Add "test-dir" argument; pass it to "default-build.xml".
> ---
> guix/build-system/ant.scm | 4 +++-
> guix/build/ant-build-system.scm | 40 +++++++++++++++++++++++++++++++++++++---
> 2 files changed, 40 insertions(+), 4 deletions(-)
>
> diff --git a/guix/build-system/ant.scm b/guix/build-system/ant.scm
> index a309a0c86..bf2f3b411 100644
> --- a/guix/build-system/ant.scm
> +++ b/guix/build-system/ant.scm
> @@ -93,12 +93,13 @@
> (define* (ant-build store name inputs
> #:key
> (tests? #t)
> - (test-target "tests")
> + (test-target "check")
> (configure-flags ''())
> (make-flags ''())
> (build-target "jar")
> (jar-name #f)
> (source-dir "src")
> + (test-dir "src/test")
> (phases '(@ (guix build ant-build-system)
> %standard-phases))
> (outputs '("out"))
Is this only for 'build.xml' files generated by the ant-build-system?
I'm not sure whether there is a consensus within the Java world about
the name of a test phase. I think 'check' would be good, because it is
consistent with other build systems within Guix.
So.. long story short, it looks good to me.
> @@ -128,6 +129,7 @@
> #:build-target ,build-target
> #:jar-name ,jar-name
> #:source-dir ,source-dir
> + #:test-dir ,test-dir
> #:phases ,phases
> #:outputs %outputs
> #:search-paths ',(map search-path-specification->sexp
> diff --git a/guix/build/ant-build-system.scm b/guix/build/ant-build-system.scm
> index 8ec7a9486..4042630a1 100644
> --- a/guix/build/ant-build-system.scm
> +++ b/guix/build/ant-build-system.scm
> @@ -36,7 +36,7 @@
> ;; Code:
>
> (define* (default-build.xml jar-name prefix #:optional
> - (source-dir "."))
> + (source-dir ".") (test-dir "./test"))
> "Create a simple build.xml with standard targets for Ant."
> (call-with-output-file "build.xml"
> (lambda (port)
> @@ -48,6 +48,10 @@
> (value "${basedir}/build/jar")))
> (property (@ (name "dist.dir")
> (value ,prefix)))
> + (property (@ (name "test.home")
> + (value ,test-dir)))
> + (property (@ (name "test.classes.dir")
> + (value "${basedir}/build/test-classes")))
>
> ;; respect the CLASSPATH environment variable
> (property (@ (name "build.sysclasspath")
> @@ -63,6 +67,35 @@
> (destdir "${classes.dir}")
> (classpath (@ (refid "classpath"))))))
>
> + (target (@ (name "compile-tests"))
> + (mkdir (@ (dir "${test.classes.dir}")))
> + (javac (@ (includeantruntime "false")
> + (srcdir ,test-dir)
> + (destdir "${test.classes.dir}"))
> + (classpath
> + (pathelement (@ (path "${env.CLASSPATH}")))
> + (pathelement (@ (location "${classes.dir}")))
> + (pathelement (@ (location "${test.classes.dir}"))))))
> +
> + (target (@ (name "check")
> + (depends "compile-tests"))
> + (mkdir (@ (dir "${test.home}/test-reports")))
> + (junit (@ (printsummary "true")
> + (showoutput "true")
> + (fork "yes")
> + (haltonfailure "yes"))
> + (classpath
> + (pathelement (@ (path "${env.CLASSPATH}")))
> + (pathelement (@ (location "${test.home}/resources")))
> + (pathelement (@ (location "${classes.dir}")))
> + (pathelement (@ (location "${test.classes.dir}"))))
> + (formatter (@ (type "plain")
> + (usefile "true")))
> + (batchtest (@ (fork "yes")
> + (todir "${test.home}/test-reports"))
> + (fileset (@ (dir "${test.home}/java"))
> + (include (@ (name "**/*Test.java" )))))))
> +
> (target (@ (name "jar")
> (depends "compile"))
> (mkdir (@ (dir "${jar.dir}")))
Cool!
> @@ -99,12 +132,13 @@ to the default GNU unpack strategy."
> ((assq-ref gnu:%standard-phases 'unpack) #:source source)))
>
> (define* (configure #:key inputs outputs (jar-name #f)
> - (source-dir "src") #:allow-other-keys)
> + (source-dir "src")
> + (test-dir "src/test") #:allow-other-keys)
> (when jar-name
> (default-build.xml jar-name
> (string-append (assoc-ref outputs "out")
> "/share/java")
> - source-dir))
> + source-dir test-dir))
> (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
> (setenv "CLASSPATH" (generate-classpath inputs)))
LGTM.
Thanks a lot for this!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 03/36] guix: Add java-utils.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
2017-05-06 15:35 ` bug#26803: [PATCH 02/36] ant-build-system: Add default "check" target Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:31 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 04/36] gnu: Add java-plexus-utils Ricardo Wurmus
` (33 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* guix/build/java-utils.scm: New file.
* guix/build-system/ant.scm: Use it.
* Makefile.am (MODULES): Add it.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
Makefile.am | 1 +
guix/build-system/ant.scm | 2 ++
guix/build/java-utils.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 58 insertions(+)
create mode 100644 guix/build/java-utils.scm
diff --git a/Makefile.am b/Makefile.am
index 8fe9e350c..b09180ba2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -124,6 +124,7 @@ MODULES = \
guix/build/syscalls.scm \
guix/build/gremlin.scm \
guix/build/emacs-utils.scm \
+ guix/build/java-utils.scm \
guix/build/lisp-utils.scm \
guix/build/graft.scm \
guix/build/bournish.scm \
diff --git a/guix/build-system/ant.scm b/guix/build-system/ant.scm
index bf2f3b411..228b4e60d 100644
--- a/guix/build-system/ant.scm
+++ b/guix/build-system/ant.scm
@@ -39,6 +39,7 @@
(define %ant-build-system-modules
;; Build-side modules imported by default.
`((guix build ant-build-system)
+ (guix build java-utils)
(guix build syscalls)
,@%gnu-build-system-modules))
@@ -108,6 +109,7 @@
(guile #f)
(imported-modules %ant-build-system-modules)
(modules '((guix build ant-build-system)
+ (guix build java-utils)
(guix build utils))))
"Build SOURCE with INPUTS."
(define builder
diff --git a/guix/build/java-utils.scm b/guix/build/java-utils.scm
new file mode 100644
index 000000000..402d377bf
--- /dev/null
+++ b/guix/build/java-utils.scm
@@ -0,0 +1,55 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
+;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (guix build java-utils)
+ #:use-module (guix build utils)
+ #:export (ant-build-javadoc
+ install-jars
+ install-javadoc))
+
+;; Copied from haskell-build-system.scm
+(define (package-name-version store-dir)
+ "Given a store directory STORE-DIR return 'name-version' of the package."
+ (let* ((base (basename store-dir)))
+ (string-drop base (+ 1 (string-index base #\-)))))
+
+(define* (ant-build-javadoc #:key (target "javadoc") (make-flags '())
+ #:allow-other-keys)
+ (zero? (apply system* `("ant" ,target ,@make-flags))))
+
+(define* (install-jars jar-directory)
+ "Install jar files from JAR-DIRECTORY to the default target directory. This
+is used in case the build.xml does not include an install target."
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((share (string-append (assoc-ref outputs "out")
+ "/share/java")))
+ (for-each (lambda (f) (install-file f share))
+ (find-files jar-directory "\\.jar$"))
+ #t)))
+
+(define* (install-javadoc apidoc-directory)
+ "Install the APIDOC-DIRECTORY to the target directory. This is used to
+install javadocs when this is not done by the install target."
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (docs (string-append (or (assoc-ref outputs "doc") out)
+ "/share/doc/" (package-name-version out) "/")))
+ (mkdir-p docs)
+ (copy-recursively apidoc-directory docs)
+ #t)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 03/36] guix: Add java-utils.
2017-05-06 15:35 ` bug#26803: [PATCH 03/36] guix: Add java-utils Ricardo Wurmus
@ 2017-05-06 20:31 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:31 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * guix/build/java-utils.scm: New file.
> * guix/build-system/ant.scm: Use it.
> * Makefile.am (MODULES): Add it.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> Makefile.am | 1 +
> guix/build-system/ant.scm | 2 ++
> guix/build/java-utils.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++
> 3 files changed, 58 insertions(+)
> create mode 100644 guix/build/java-utils.scm
>
> diff --git a/Makefile.am b/Makefile.am
> index 8fe9e350c..b09180ba2 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -124,6 +124,7 @@ MODULES = \
> guix/build/syscalls.scm \
> guix/build/gremlin.scm \
> guix/build/emacs-utils.scm \
> + guix/build/java-utils.scm \
> guix/build/lisp-utils.scm \
> guix/build/graft.scm \
> guix/build/bournish.scm \
> diff --git a/guix/build-system/ant.scm b/guix/build-system/ant.scm
> index bf2f3b411..228b4e60d 100644
> --- a/guix/build-system/ant.scm
> +++ b/guix/build-system/ant.scm
> @@ -39,6 +39,7 @@
> (define %ant-build-system-modules
> ;; Build-side modules imported by default.
> `((guix build ant-build-system)
> + (guix build java-utils)
> (guix build syscalls)
> ,@%gnu-build-system-modules))
>
> @@ -108,6 +109,7 @@
> (guile #f)
> (imported-modules %ant-build-system-modules)
> (modules '((guix build ant-build-system)
> + (guix build java-utils)
> (guix build utils))))
> "Build SOURCE with INPUTS."
> (define builder
> diff --git a/guix/build/java-utils.scm b/guix/build/java-utils.scm
> new file mode 100644
> index 000000000..402d377bf
> --- /dev/null
> +++ b/guix/build/java-utils.scm
> @@ -0,0 +1,55 @@
> +;;; GNU Guix --- Functional package management for GNU
> +;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
> +;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
> +;;;
> +;;; This file is part of GNU Guix.
> +;;;
> +;;; GNU Guix is free software; you can redistribute it and/or modify it
> +;;; under the terms of the GNU General Public License as published by
> +;;; the Free Software Foundation; either version 3 of the License, or (at
> +;;; your option) any later version.
> +;;;
> +;;; GNU Guix is distributed in the hope that it will be useful, but
> +;;; WITHOUT ANY WARRANTY; without even the implied warranty of
> +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> +;;; GNU General Public License for more details.
> +;;;
> +;;; You should have received a copy of the GNU General Public License
> +;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
> +
> +(define-module (guix build java-utils)
> + #:use-module (guix build utils)
> + #:export (ant-build-javadoc
> + install-jars
> + install-javadoc))
> +
> +;; Copied from haskell-build-system.scm
> +(define (package-name-version store-dir)
> + "Given a store directory STORE-DIR return 'name-version' of the package."
> + (let* ((base (basename store-dir)))
> + (string-drop base (+ 1 (string-index base #\-)))))
> +
> +(define* (ant-build-javadoc #:key (target "javadoc") (make-flags '())
> + #:allow-other-keys)
> + (zero? (apply system* `("ant" ,target ,@make-flags))))
> +
> +(define* (install-jars jar-directory)
> + "Install jar files from JAR-DIRECTORY to the default target directory. This
(nitpick
"jar" or "JAR")
> +is used in case the build.xml does not include an install target."
> + (lambda* (#:key outputs #:allow-other-keys)
> + (let ((share (string-append (assoc-ref outputs "out")
> + "/share/java")))
> + (for-each (lambda (f) (install-file f share))
> + (find-files jar-directory "\\.jar$"))
> + #t)))
> +
> +(define* (install-javadoc apidoc-directory)
> + "Install the APIDOC-DIRECTORY to the target directory. This is used to
> +install javadocs when this is not done by the install target."
> + (lambda* (#:key outputs #:allow-other-keys)
> + (let* ((out (assoc-ref outputs "out"))
> + (docs (string-append (or (assoc-ref outputs "doc") out)
> + "/share/doc/" (package-name-version out) "/")))
> + (mkdir-p docs)
> + (copy-recursively apidoc-directory docs)
> + #t)))
(nitpick
"javadocs" or "Javadocs")
Either way, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 04/36] gnu: Add java-plexus-utils.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
2017-05-06 15:35 ` bug#26803: [PATCH 02/36] ant-build-system: Add default "check" target Ricardo Wurmus
2017-05-06 15:35 ` bug#26803: [PATCH 03/36] guix: Add java-utils Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:34 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation Ricardo Wurmus
` (32 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-plexus-utils): New variable.
Co-authored-by: Hartmut Goebel <h.goebel@crazy-compilers.com>
---
gnu/packages/java.scm | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 52 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index ad1ccac83..49b953d26 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1180,3 +1180,55 @@ testing frameworks, mocking libraries and UI validation rules.")
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-plexus-utils
+ (package
+ (name "java-plexus-utils")
+ (version "3.0.24")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/codehaus-plexus/"
+ "plexus-utils/archive/plexus-utils-"
+ version ".tar.gz"))
+ (sha256
+ (base32
+ "1mlwpc6fms24slygv5yvi6fi9hcha2fh0v73p5znpi78bg36i2js"))))
+ (build-system ant-build-system)
+ ;; FIXME: The default build.xml does not include a target to install
+ ;; javadoc files.
+ (arguments
+ `(#:jar-name "plexus-utils.jar"
+ #:source-dir "src/main"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'fix-reference-to-/bin-and-/usr
+ (lambda _
+ (substitute* "src/main/java/org/codehaus/plexus/util/\
+cli/shell/BourneShell.java"
+ (("/bin/sh") (which "sh"))
+ (("/usr/") (getcwd)))
+ #t))
+ (add-after 'unpack 'fix-or-disable-broken-tests
+ (lambda _
+ (with-directory-excursion "src/test/java/org/codehaus/plexus/util"
+ (substitute* '("cli/CommandlineTest.java"
+ "cli/shell/BourneShellTest.java")
+ (("/bin/sh") (which "sh"))
+ (("/bin/echo") (which "echo")))
+
+ ;; This test depends on MavenProjectStub, but we don't have
+ ;; a package for Maven.
+ (delete-file "introspection/ReflectionValueExtractorTest.java")
+
+ ;; FIXME: The command line tests fail, maybe because they use
+ ;; absolute paths.
+ (delete-file "cli/CommandlineTest.java"))
+ #t)))))
+ (native-inputs
+ `(("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
+Plexus framework to ease working with strings, files, command lines, XML and
+more.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 04/36] gnu: Add java-plexus-utils.
2017-05-06 15:35 ` bug#26803: [PATCH 04/36] gnu: Add java-plexus-utils Ricardo Wurmus
@ 2017-05-06 20:34 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:34 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-plexus-utils): New variable.
>
> Co-authored-by: Hartmut Goebel <h.goebel@crazy-compilers.com>
> ---
> gnu/packages/java.scm | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 52 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index ad1ccac83..49b953d26 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1180,3 +1180,55 @@ testing frameworks, mocking libraries and UI validation rules.")
> 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-plexus-utils
> + (package
> + (name "java-plexus-utils")
> + (version "3.0.24")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/codehaus-plexus/"
> + "plexus-utils/archive/plexus-utils-"
> + version ".tar.gz"))
> + (sha256
> + (base32
> + "1mlwpc6fms24slygv5yvi6fi9hcha2fh0v73p5znpi78bg36i2js"))))
> + (build-system ant-build-system)
> + ;; FIXME: The default build.xml does not include a target to install
> + ;; javadoc files.
> + (arguments
> + `(#:jar-name "plexus-utils.jar"
> + #:source-dir "src/main"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'fix-reference-to-/bin-and-/usr
> + (lambda _
> + (substitute* "src/main/java/org/codehaus/plexus/util/\
> +cli/shell/BourneShell.java"
> + (("/bin/sh") (which "sh"))
> + (("/usr/") (getcwd)))
> + #t))
> + (add-after 'unpack 'fix-or-disable-broken-tests
> + (lambda _
> + (with-directory-excursion "src/test/java/org/codehaus/plexus/util"
> + (substitute* '("cli/CommandlineTest.java"
> + "cli/shell/BourneShellTest.java")
> + (("/bin/sh") (which "sh"))
> + (("/bin/echo") (which "echo")))
> +
> + ;; This test depends on MavenProjectStub, but we don't have
> + ;; a package for Maven.
> + (delete-file "introspection/ReflectionValueExtractorTest.java")
> +
> + ;; FIXME: The command line tests fail, maybe because they use
> + ;; absolute paths.
> + (delete-file "cli/CommandlineTest.java"))
> + #t)))))
> + (native-inputs
> + `(("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
> +Plexus framework to ease working with strings, files, command lines, XML and
> +more.")
> + (license license:asl2.0)))
I'd prefer moving on rather than fixing the test failure on
cli/CommandlineTest.java.
LGTM. Thanks a lot!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (2 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 04/36] gnu: Add java-plexus-utils Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:36 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 06/36] gnu: Add java-asm Ricardo Wurmus
` (31 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-plexus-interplation): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 49b953d26..2ff9a11a0 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1232,3 +1232,33 @@ cli/shell/BourneShell.java"
Plexus framework to ease working with strings, files, command lines, XML and
more.")
(license license:asl2.0)))
+
+(define-public java-plexus-interpolation
+ (package
+ (name "java-plexus-interpolation")
+ (version "1.23")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/codehaus-plexus/"
+ "plexus-interpolation/archive/"
+ "plexus-interpolation-" version ".tar.gz"))
+ (sha256
+ (base32
+ "1w79ljwk42ymrgy8kqxq4l82pgdj6287gabpfnpkyzbrnclsnfrp"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "plexus-interpolation.jar"
+ #:source-dir "src/main"))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://codehaus-plexus.github.io/plexus-interpolation/")
+ (synopsis "Java components for interpolating ${} strings and the like")
+ (description "Plexus interpolator is a modular, flexible interpolation
+framework for the expression language style commonly seen in Maven, Plexus,
+and other related projects.
+
+It has its foundation in the org.codehaus.plexus.utils.interpolation package
+within plexus-utils, but has been separated in order to allow these two
+libraries to vary independently of one another.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation.
2017-05-06 15:35 ` bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation Ricardo Wurmus
@ 2017-05-06 20:36 ` Roel Janssen
2017-05-10 10:44 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:36 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-plexus-interplation): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 30 ++++++++++++++++++++++++++++++
> 1 file changed, 30 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 49b953d26..2ff9a11a0 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1232,3 +1232,33 @@ cli/shell/BourneShell.java"
> Plexus framework to ease working with strings, files, command lines, XML and
> more.")
> (license license:asl2.0)))
> +
> +(define-public java-plexus-interpolation
> + (package
> + (name "java-plexus-interpolation")
> + (version "1.23")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/codehaus-plexus/"
> + "plexus-interpolation/archive/"
> + "plexus-interpolation-" version ".tar.gz"))
> + (sha256
> + (base32
> + "1w79ljwk42ymrgy8kqxq4l82pgdj6287gabpfnpkyzbrnclsnfrp"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "plexus-interpolation.jar"
> + #:source-dir "src/main"))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://codehaus-plexus.github.io/plexus-interpolation/")
> + (synopsis "Java components for interpolating ${} strings and the like")
> + (description "Plexus interpolator is a modular, flexible interpolation
> +framework for the expression language style commonly seen in Maven, Plexus,
> +and other related projects.
> +
> +It has its foundation in the org.codehaus.plexus.utils.interpolation package
> +within plexus-utils, but has been separated in order to allow these two
> +libraries to vary independently of one another.")
> + (license license:asl2.0)))
Maybe: @code{org.codehaus.plexus.utils.interpolation} and
@code{plexus-utils}?
Either way, LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation.
2017-05-06 20:36 ` Roel Janssen
@ 2017-05-10 10:44 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 10:44 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-plexus-interplation): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
[…]
>> + (description "Plexus interpolator is a modular, flexible interpolation
>> +framework for the expression language style commonly seen in Maven, Plexus,
>> +and other related projects.
>> +
>> +It has its foundation in the org.codehaus.plexus.utils.interpolation package
>> +within plexus-utils, but has been separated in order to allow these two
>> +libraries to vary independently of one another.")
>> + (license license:asl2.0)))
>
> Maybe: @code{org.codehaus.plexus.utils.interpolation} and
> @code{plexus-utils}?
Good catch, thanks!
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 06/36] gnu: Add java-asm.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (3 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 05/36] gnu: Add java-plexus-interpolation Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:39 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 07/36] gnu: Add java-cglib Ricardo Wurmus
` (30 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-asm): New variable.
---
gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 2ff9a11a0..2df07bc38 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1262,3 +1262,47 @@ It has its foundation in the org.codehaus.plexus.utils.interpolation package
within plexus-utils, but has been separated in order to allow these two
libraries to vary independently of one another.")
(license license:asl2.0)))
+
+(define-public java-asm
+ (package
+ (name "java-asm")
+ (version "5.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://download.forge.ow2.org/asm/"
+ "asm-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0kxvmv5275rnjl7jv0442k3wjnq03ngkb7sghs78avf45pzm4qgr"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:build-target "compile"
+ #:test-target "test"
+ ;; The tests require an old version of Janino, which no longer compiles
+ ;; with the JDK7.
+ #:tests? #f
+ ;; We don't need these extra ant tasks, but the build system asks us to
+ ;; provide a path anyway.
+ #:make-flags (list (string-append "-Dobjectweb.ant.tasks.path=foo"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'install 'build-jars
+ (lambda* (#:key make-flags #:allow-other-keys)
+ ;; We cannot use the "jar" target because it depends on a couple
+ ;; of unpackaged, complicated tools.
+ (mkdir "dist")
+ (zero? (system* "jar"
+ "-cf" (string-append "dist/asm-" ,version ".jar")
+ "-C" "output/build/tmp" "."))))
+ (replace 'install
+ (install-jars "dist")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (home-page "http://asm.ow2.org/")
+ (synopsis "Very small and fast Java bytecode manipulation framework")
+ (description "ASM is an all purpose Java bytecode manipulation and
+analysis framework. It can be used to modify existing classes or dynamically
+generate classes, directly in binary form. The provided common
+transformations and analysis algorithms allow to easily assemble custom
+complex transformations and code analysis tools.")
+ (license license:bsd-3)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 06/36] gnu: Add java-asm.
2017-05-06 15:35 ` bug#26803: [PATCH 06/36] gnu: Add java-asm Ricardo Wurmus
@ 2017-05-06 20:39 ` Roel Janssen
2017-05-10 13:58 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:39 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-asm): New variable.
> ---
> gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 44 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 2ff9a11a0..2df07bc38 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1262,3 +1262,47 @@ It has its foundation in the org.codehaus.plexus.utils.interpolation package
> within plexus-utils, but has been separated in order to allow these two
> libraries to vary independently of one another.")
> (license license:asl2.0)))
> +
> +(define-public java-asm
> + (package
> + (name "java-asm")
> + (version "5.2")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "http://download.forge.ow2.org/asm/"
> + "asm-" version ".tar.gz"))
> + (sha256
> + (base32
> + "0kxvmv5275rnjl7jv0442k3wjnq03ngkb7sghs78avf45pzm4qgr"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:build-target "compile"
> + #:test-target "test"
> + ;; The tests require an old version of Janino, which no longer compiles
> + ;; with the JDK7.
> + #:tests? #f
Why set the test-target if you disable the tests?
> + ;; We don't need these extra ant tasks, but the build system asks us to
> + ;; provide a path anyway.
> + #:make-flags (list (string-append "-Dobjectweb.ant.tasks.path=foo"))
> + #:phases
> + (modify-phases %standard-phases
> + (add-before 'install 'build-jars
> + (lambda* (#:key make-flags #:allow-other-keys)
> + ;; We cannot use the "jar" target because it depends on a couple
> + ;; of unpackaged, complicated tools.
Hehe. :-)
> + (mkdir "dist")
> + (zero? (system* "jar"
> + "-cf" (string-append "dist/asm-" ,version ".jar")
> + "-C" "output/build/tmp" "."))))
> + (replace 'install
> + (install-jars "dist")))))
> + (native-inputs
> + `(("java-junit" ,java-junit)))
> + (home-page "http://asm.ow2.org/")
> + (synopsis "Very small and fast Java bytecode manipulation framework")
> + (description "ASM is an all purpose Java bytecode manipulation and
> +analysis framework. It can be used to modify existing classes or dynamically
> +generate classes, directly in binary form. The provided common
> +transformations and analysis algorithms allow to easily assemble custom
> +complex transformations and code analysis tools.")
> + (license license:bsd-3)))
Otherwise LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 06/36] gnu: Add java-asm.
2017-05-06 20:39 ` Roel Janssen
@ 2017-05-10 13:58 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 13:58 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
>> +(define-public java-asm
>> + (package
>> + (name "java-asm")
>> + (version "5.2")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "http://download.forge.ow2.org/asm/"
>> + "asm-" version ".tar.gz"))
>> + (sha256
>> + (base32
>> + "0kxvmv5275rnjl7jv0442k3wjnq03ngkb7sghs78avf45pzm4qgr"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:build-target "compile"
>> + #:test-target "test"
>> + ;; The tests require an old version of Janino, which no longer compiles
>> + ;; with the JDK7.
>> + #:tests? #f
>
> Why set the test-target if you disable the tests?
You’re right, that doesn’t make much sense. I’ll remove it.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 07/36] gnu: Add java-cglib.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (4 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 06/36] gnu: Add java-asm Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:40 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 08/36] gnu: Add java-objenesis Ricardo Wurmus
` (29 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-cglib): New variable.
---
gnu/packages/java.scm | 34 ++++++++++++++++++++++++++++++++++
1 file changed, 34 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 2df07bc38..7f22661b1 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1306,3 +1306,37 @@ generate classes, directly in binary form. The provided common
transformations and analysis algorithms allow to easily assemble custom
complex transformations and code analysis tools.")
(license license:bsd-3)))
+
+(define-public java-cglib
+ (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"))))
+ (build-system ant-build-system)
+ (arguments
+ `(;; FIXME: tests fail because junit runs
+ ;; "net.sf.cglib.transform.AbstractTransformTest", which does not seem
+ ;; to describe a test at all.
+ #:tests? #f
+ #:jar-name "cglib.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "cglib") #t)))))
+ (inputs
+ `(("java-asm" ,java-asm)
+ ("java-junit" ,java-junit)))
+ (home-page "https://github.com/cglib/cglib/")
+ (synopsis "Java byte code generation library")
+ (description "The byte code generation library CGLIB is a high level API
+to generate and transform Java byte code.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 07/36] gnu: Add java-cglib.
2017-05-06 15:35 ` bug#26803: [PATCH 07/36] gnu: Add java-cglib Ricardo Wurmus
@ 2017-05-06 20:40 ` Roel Janssen
2017-05-06 20:49 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:40 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-cglib): New variable.
> ---
> gnu/packages/java.scm | 34 ++++++++++++++++++++++++++++++++++
> 1 file changed, 34 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 2df07bc38..7f22661b1 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1306,3 +1306,37 @@ generate classes, directly in binary form. The provided common
> transformations and analysis algorithms allow to easily assemble custom
> complex transformations and code analysis tools.")
> (license license:bsd-3)))
> +
> +(define-public java-cglib
> + (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"))))
> + (build-system ant-build-system)
> + (arguments
> + `(;; FIXME: tests fail because junit runs
> + ;; "net.sf.cglib.transform.AbstractTransformTest", which does not seem
> + ;; to describe a test at all.
> + #:tests? #f
> + #:jar-name "cglib.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "cglib") #t)))))
> + (inputs
> + `(("java-asm" ,java-asm)
> + ("java-junit" ,java-junit)))
> + (home-page "https://github.com/cglib/cglib/")
> + (synopsis "Java byte code generation library")
> + (description "The byte code generation library CGLIB is a high level API
> +to generate and transform Java byte code.")
> + (license license:asl2.0)))
Not sure, but maybe @code{CGLIB}?
Either way, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 07/36] gnu: Add java-cglib.
2017-05-06 20:40 ` Roel Janssen
@ 2017-05-06 20:49 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 20:49 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
>> + (synopsis "Java byte code generation library")
>> + (description "The byte code generation library CGLIB is a high level API
>> +to generate and transform Java byte code.")
>> + (license license:asl2.0)))
>
> Not sure, but maybe @code{CGLIB}?
It’s not the name of a class, just the name of the library, so I prefer
not to use @code{} here.
> Either way, LGTM!
Thanks for taking the time to review this mess!
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 08/36] gnu: Add java-objenesis.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (5 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 07/36] gnu: Add java-cglib Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 20:41 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 09/36] gnu: Add java-easymock Ricardo Wurmus
` (28 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-objenesis): New variable.
---
gnu/packages/java.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 7f22661b1..303d64016 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1340,3 +1340,32 @@ complex transformations and code analysis tools.")
(description "The byte code generation library CGLIB is a high level API
to generate and transform Java byte code.")
(license license:asl2.0)))
+
+(define-public java-objenesis
+ (package
+ (name "java-objenesis")
+ (version "2.5.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/easymock/objenesis/"
+ "archive/" version ".tar.gz"))
+ (file-name (string-append "objenesis-" version ".tar.gz"))
+ (sha256
+ (base32
+ "1va5qz1i2wawwavhnxfzxnfgrcaflz9p1pg03irrjh4nd3rz8wh6"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "objenesis.jar"
+ #:source-dir "main/src/"
+ #:test-dir "main/src/test/"))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://objenesis.org/")
+ (synopsis "Bypass the constructor when creating an object")
+ (description "Objenesis is a small Java library that serves one purpose:
+to instantiate a new object of a particular class. It is common to see
+restrictions in libraries stating that classes must require a default
+constructor. Objenesis aims to overcome these restrictions by bypassing the
+constructor on object instantiation.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 08/36] gnu: Add java-objenesis.
2017-05-06 15:35 ` bug#26803: [PATCH 08/36] gnu: Add java-objenesis Ricardo Wurmus
@ 2017-05-06 20:41 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:41 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-objenesis): New variable.
> ---
> gnu/packages/java.scm | 29 +++++++++++++++++++++++++++++
> 1 file changed, 29 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 7f22661b1..303d64016 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1340,3 +1340,32 @@ complex transformations and code analysis tools.")
> (description "The byte code generation library CGLIB is a high level API
> to generate and transform Java byte code.")
> (license license:asl2.0)))
> +
> +(define-public java-objenesis
> + (package
> + (name "java-objenesis")
> + (version "2.5.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/easymock/objenesis/"
> + "archive/" version ".tar.gz"))
> + (file-name (string-append "objenesis-" version ".tar.gz"))
> + (sha256
> + (base32
> + "1va5qz1i2wawwavhnxfzxnfgrcaflz9p1pg03irrjh4nd3rz8wh6"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "objenesis.jar"
> + #:source-dir "main/src/"
> + #:test-dir "main/src/test/"))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://objenesis.org/")
> + (synopsis "Bypass the constructor when creating an object")
> + (description "Objenesis is a small Java library that serves one purpose:
> +to instantiate a new object of a particular class. It is common to see
> +restrictions in libraries stating that classes must require a default
> +constructor. Objenesis aims to overcome these restrictions by bypassing the
> +constructor on object instantiation.")
> + (license license:asl2.0)))
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 09/36] gnu: Add java-easymock.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (6 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 08/36] gnu: Add java-objenesis Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 21:28 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 10/36] gnu: Add java-jopt-simple Ricardo Wurmus
` (27 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-easymock): New variable.
---
gnu/packages/java.scm | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 61 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 303d64016..7a1a66027 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1369,3 +1369,64 @@ restrictions in libraries stating that classes must require a default
constructor. Objenesis aims to overcome these restrictions by bypassing the
constructor on object instantiation.")
(license license:asl2.0)))
+
+(define-public java-easymock
+ (package
+ (name "java-easymock")
+ (version "3.4")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/easymock/easymock/"
+ "archive/easymock-" version ".tar.gz"))
+ (sha256
+ (base32
+ "1yzg0kv256ndr57gpav46cyv4a1ns5sj722l50zpxk3j6sk9hnmi"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "easymock.jar"
+ #:source-dir "core/src/main"
+ #:test-dir "core/src/test"
+ #:phases
+ (modify-phases %standard-phases
+ ;; FIXME: Android support requires the following packages to be
+ ;; available: com.google.dexmaker.stock.ProxyBuilder
+ (add-after 'unpack 'delete-android-support
+ (lambda _
+ (with-directory-excursion "core/src/main/java/org/easymock/internal"
+ (substitute* "MocksControl.java"
+ (("AndroidSupport.isAndroid\\(\\)") "false")
+ (("return classProxyFactory = new AndroidClassProxyFactory\\(\\);") ""))
+ (delete-file "AndroidClassProxyFactory.java"))
+ #t))
+ (add-after 'unpack 'delete-broken-tests
+ (lambda _
+ (with-directory-excursion "core/src/test/java/org/easymock"
+ ;; This test depends on dexmaker.
+ (delete-file "tests2/ClassExtensionHelperTest.java")
+
+ ;; This is not a test.
+ (delete-file "tests/BaseEasyMockRunnerTest.java")
+
+ ;; This test should be executed with a different runner...
+ (delete-file "tests2/EasyMockAnnotationsTest.java")
+ ;; ...but deleting it means that we also have to delete these
+ ;; dependent files.
+ (delete-file "tests2/EasyMockRunnerTest.java")
+ (delete-file "tests2/EasyMockRuleTest.java")
+
+ ;; This test fails because the file "easymock.properties" does
+ ;; not exist.
+ (delete-file "tests2/EasyMockPropertiesTest.java"))
+ #t)))))
+ (inputs
+ `(("java-asm" ,java-asm)
+ ("java-cglib" ,java-cglib)
+ ("java-objenesis" ,java-objenesis)))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://easymock.org")
+ (synopsis "Java library providing mock objects for unit tests")
+ (description "EasyMock is a Java library that provides an easy way to use
+mock objects in unit testing.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 09/36] gnu: Add java-easymock.
2017-05-06 15:35 ` bug#26803: [PATCH 09/36] gnu: Add java-easymock Ricardo Wurmus
@ 2017-05-06 21:28 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 21:28 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-easymock): New variable.
> ---
> gnu/packages/java.scm | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 61 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 303d64016..7a1a66027 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1369,3 +1369,64 @@ restrictions in libraries stating that classes must require a default
> constructor. Objenesis aims to overcome these restrictions by bypassing the
> constructor on object instantiation.")
> (license license:asl2.0)))
> +
> +(define-public java-easymock
> + (package
> + (name "java-easymock")
> + (version "3.4")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/easymock/easymock/"
> + "archive/easymock-" version ".tar.gz"))
> + (sha256
> + (base32
> + "1yzg0kv256ndr57gpav46cyv4a1ns5sj722l50zpxk3j6sk9hnmi"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "easymock.jar"
> + #:source-dir "core/src/main"
> + #:test-dir "core/src/test"
> + #:phases
> + (modify-phases %standard-phases
> + ;; FIXME: Android support requires the following packages to be
> + ;; available: com.google.dexmaker.stock.ProxyBuilder
> + (add-after 'unpack 'delete-android-support
> + (lambda _
> + (with-directory-excursion "core/src/main/java/org/easymock/internal"
> + (substitute* "MocksControl.java"
> + (("AndroidSupport.isAndroid\\(\\)") "false")
> + (("return classProxyFactory = new AndroidClassProxyFactory\\(\\);") ""))
> + (delete-file "AndroidClassProxyFactory.java"))
> + #t))
> + (add-after 'unpack 'delete-broken-tests
> + (lambda _
> + (with-directory-excursion "core/src/test/java/org/easymock"
> + ;; This test depends on dexmaker.
> + (delete-file "tests2/ClassExtensionHelperTest.java")
> +
> + ;; This is not a test.
> + (delete-file "tests/BaseEasyMockRunnerTest.java")
> +
> + ;; This test should be executed with a different runner...
> + (delete-file "tests2/EasyMockAnnotationsTest.java")
> + ;; ...but deleting it means that we also have to delete these
> + ;; dependent files.
> + (delete-file "tests2/EasyMockRunnerTest.java")
> + (delete-file "tests2/EasyMockRuleTest.java")
> +
> + ;; This test fails because the file "easymock.properties" does
> + ;; not exist.
> + (delete-file "tests2/EasyMockPropertiesTest.java"))
> + #t)))))
> + (inputs
> + `(("java-asm" ,java-asm)
> + ("java-cglib" ,java-cglib)
> + ("java-objenesis" ,java-objenesis)))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://easymock.org")
> + (synopsis "Java library providing mock objects for unit tests")
> + (description "EasyMock is a Java library that provides an easy way to use
> +mock objects in unit testing.")
> + (license license:asl2.0)))
Thanks for the comments on the excluded tests. :)
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 10/36] gnu: Add java-jopt-simple.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (7 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 09/36] gnu: Add java-easymock Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 21:31 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix Ricardo Wurmus
` (26 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-jopt-simple): New variable.
---
gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 7a1a66027..3dc71e4bc 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1430,3 +1430,31 @@ constructor on object instantiation.")
(description "EasyMock is a Java library that provides an easy way to use
mock objects in unit testing.")
(license license:asl2.0)))
+
+(define-public java-jopt-simple
+ (package
+ (name "java-jopt-simple")
+ (version "5.0.3")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://repo1.maven.org/maven2/"
+ "net/sf/jopt-simple/jopt-simple/"
+ version "/jopt-simple-"
+ version "-sources.jar"))
+ (sha256
+ (base32
+ "1v8bzmwmw6qq20gm42xyay6vrd567dra4vqwhgjnqqjz1gs9f8qa"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; there are no tests
+ #:jar-name "jopt-simple.jar"))
+ (home-page "https://pholser.github.io/jopt-simple/")
+ (synopsis "Java library for parsing command line options")
+ (description "JOpt Simple is a Java library for parsing command line
+options, such as those you might pass to an invocation of @code{javac}. In
+the interest of striving for simplicity, as closely as possible JOpt Simple
+attempts to honor the command line option syntaxes of POSIX @code{getopt} and
+GNU @code{getopt_long}. It also aims to make option parser configuration and
+retrieval of options and their arguments simple and expressive, without being
+overly clever.")
+ (license license:expat)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 10/36] gnu: Add java-jopt-simple.
2017-05-06 15:35 ` bug#26803: [PATCH 10/36] gnu: Add java-jopt-simple Ricardo Wurmus
@ 2017-05-06 21:31 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 21:31 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-jopt-simple): New variable.
> ---
> gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
> 1 file changed, 28 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 7a1a66027..3dc71e4bc 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1430,3 +1430,31 @@ constructor on object instantiation.")
> (description "EasyMock is a Java library that provides an easy way to use
> mock objects in unit testing.")
> (license license:asl2.0)))
> +
> +(define-public java-jopt-simple
> + (package
> + (name "java-jopt-simple")
> + (version "5.0.3")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "http://repo1.maven.org/maven2/"
> + "net/sf/jopt-simple/jopt-simple/"
> + version "/jopt-simple-"
> + version "-sources.jar"))
> + (sha256
> + (base32
> + "1v8bzmwmw6qq20gm42xyay6vrd567dra4vqwhgjnqqjz1gs9f8qa"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:tests? #f ; there are no tests
> + #:jar-name "jopt-simple.jar"))
> + (home-page "https://pholser.github.io/jopt-simple/")
> + (synopsis "Java library for parsing command line options")
> + (description "JOpt Simple is a Java library for parsing command line
> +options, such as those you might pass to an invocation of @code{javac}. In
> +the interest of striving for simplicity, as closely as possible JOpt Simple
> +attempts to honor the command line option syntaxes of POSIX @code{getopt} and
> +GNU @code{getopt_long}. It also aims to make option parser configuration and
> +retrieval of options and their arguments simple and expressive, without being
> +overly clever.")
> + (license license:expat)))
Cool, it is 'syntaxes' indeed!
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (8 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 10/36] gnu: Add java-jopt-simple Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 21:39 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 12/36] gnu: Add java-commons-math3 Ricardo Wurmus
` (25 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-hamcrest-core)[arguments]: Install all three
jars and strip the version suffix.
---
gnu/packages/java.scm | 26 +++++++++++++++++++++-----
1 file changed, 21 insertions(+), 5 deletions(-)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 3dc71e4bc..57ef65336 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1081,7 +1081,10 @@ an Ant task that extends the built-in @code{jar} task.")
#t))))
(build-system ant-build-system)
(arguments
- `(#:tests? #f ; Tests require junit
+ `(#:tests? #f ; Tests require junit
+ #:modules ((guix build ant-build-system)
+ (guix build utils)
+ (srfi srfi-1))
#:make-flags (list (string-append "-Dversion=" ,version))
#:build-target "core"
#:phases
@@ -1133,10 +1136,23 @@ private Method[] allMethods = getSortedMethods();")))))
#t))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
- (install-file (string-append "build/hamcrest-core-"
- ,version ".jar")
- (string-append (assoc-ref outputs "out")
- "/share/java")))))))
+ (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)))))
(native-inputs
`(("java-qdox-1.12" ,java-qdox-1.12)
("java-jarjar" ,java-jarjar)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix.
2017-05-06 15:35 ` bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix Ricardo Wurmus
@ 2017-05-06 21:39 ` Roel Janssen
2017-05-10 14:00 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 21:39 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-hamcrest-core)[arguments]: Install all three
> jars and strip the version suffix.
> ---
> gnu/packages/java.scm | 26 +++++++++++++++++++++-----
> 1 file changed, 21 insertions(+), 5 deletions(-)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 3dc71e4bc..57ef65336 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1081,7 +1081,10 @@ an Ant task that extends the built-in @code{jar} task.")
> #t))))
> (build-system ant-build-system)
> (arguments
> - `(#:tests? #f ; Tests require junit
> + `(#:tests? #f ; Tests require junit
Is this intended?
> + #:modules ((guix build ant-build-system)
> + (guix build utils)
> + (srfi srfi-1))
> #:make-flags (list (string-append "-Dversion=" ,version))
> #:build-target "core"
> #:phases
> @@ -1133,10 +1136,23 @@ private Method[] allMethods = getSortedMethods();")))))
> #t))
> (replace 'install
> (lambda* (#:key outputs #:allow-other-keys)
> - (install-file (string-append "build/hamcrest-core-"
> - ,version ".jar")
> - (string-append (assoc-ref outputs "out")
> - "/share/java")))))))
> + (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)))))
> (native-inputs
> `(("java-qdox-1.12" ,java-qdox-1.12)
> ("java-jarjar" ,java-jarjar)))
Otherwise LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix.
2017-05-06 21:39 ` Roel Janssen
@ 2017-05-10 14:00 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:00 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-hamcrest-core)[arguments]: Install all three
>> jars and strip the version suffix.
>> ---
>> gnu/packages/java.scm | 26 +++++++++++++++++++++-----
>> 1 file changed, 21 insertions(+), 5 deletions(-)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 3dc71e4bc..57ef65336 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1081,7 +1081,10 @@ an Ant task that extends the built-in @code{jar} task.")
>> #t))))
>> (build-system ant-build-system)
>> (arguments
>> - `(#:tests? #f ; Tests require junit
>> + `(#:tests? #f ; Tests require junit
>
> Is this intended?
No (but it’s indented). I’ll remove it.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 12/36] gnu: Add java-commons-math3.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (9 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 11/36] gnu: java-hamcrest-core: Install all jars without version suffix Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-06 21:43 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 13/36] gnu: Add java-jmh Ricardo Wurmus
` (24 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-math3): New variable.
---
gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 57ef65336..5d131929c 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1474,3 +1474,47 @@ GNU @code{getopt_long}. It also aims to make option parser configuration and
retrieval of options and their arguments simple and expressive, without being
overly clever.")
(license license:expat)))
+
+(define-public java-commons-math3
+ (package
+ (name "java-commons-math3")
+ (version "3.6.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/math/source/"
+ "commons-math3-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "19l6yp44qc5g7wg816nbn5z3zq3xxzwimvbm4a8pczgvpi4i85s6"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:build-target "jar"
+ #: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")))
+ #:phases
+ (modify-phases %standard-phases
+ ;; We want to build the jar in the build phase and run the tests
+ ;; later in a separate phase.
+ (add-after 'unpack 'untangle-targets
+ (lambda _
+ (substitute* "build.xml"
+ (("name=\"jar\" depends=\"test\"")
+ "name=\"jar\" depends=\"compile\""))
+ #t))
+ ;; There is no install target.
+ (replace 'install
+ (install-jars "target")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://commons.apache.org/math/")
+ (synopsis "Apache Commons mathematics library")
+ (description "Commons Math is a library of lightweight, self-contained
+mathematics and statistics components addressing the most common problems not
+available in the Java programming language or Commons Lang.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 12/36] gnu: Add java-commons-math3.
2017-05-06 15:35 ` bug#26803: [PATCH 12/36] gnu: Add java-commons-math3 Ricardo Wurmus
@ 2017-05-06 21:43 ` Roel Janssen
2017-05-10 14:01 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 21:43 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-math3): New variable.
> ---
> gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 44 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 57ef65336..5d131929c 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1474,3 +1474,47 @@ GNU @code{getopt_long}. It also aims to make option parser configuration and
> retrieval of options and their arguments simple and expressive, without being
> overly clever.")
> (license license:expat)))
> +
> +(define-public java-commons-math3
> + (package
> + (name "java-commons-math3")
> + (version "3.6.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/math/source/"
> + "commons-math3-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "19l6yp44qc5g7wg816nbn5z3zq3xxzwimvbm4a8pczgvpi4i85s6"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:build-target "jar"
> + #: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")))
> + #:phases
> + (modify-phases %standard-phases
> + ;; We want to build the jar in the build phase and run the tests
> + ;; later in a separate phase.
> + (add-after 'unpack 'untangle-targets
> + (lambda _
> + (substitute* "build.xml"
> + (("name=\"jar\" depends=\"test\"")
> + "name=\"jar\" depends=\"compile\""))
> + #t))
Nice!
> + ;; There is no install target.
> + (replace 'install
> + (install-jars "target")))))
That's odd, isn't it? Anyway, cool!
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://commons.apache.org/math/")
> + (synopsis "Apache Commons mathematics library")
> + (description "Commons Math is a library of lightweight, self-contained
> +mathematics and statistics components addressing the most common problems not
> +available in the Java programming language or Commons Lang.")
> + (license license:asl2.0)))
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 12/36] gnu: Add java-commons-math3.
2017-05-06 21:43 ` Roel Janssen
@ 2017-05-10 14:01 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:01 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-commons-math3): New variable.
>> ---
[…]
>> + ;; There is no install target.
>> + (replace 'install
>> + (install-jars "target")))))
>
> That's odd, isn't it? Anyway, cool!
Unfortunately, in Java land it’s not rare at all.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 13/36] gnu: Add java-jmh.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (10 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 12/36] gnu: Add java-commons-math3 Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-07 19:13 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 14/36] gnu: Add java-commons-collections4 Ricardo Wurmus
` (23 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-jmh): New variable.
---
gnu/packages/java.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 5d131929c..36d80ff1d 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -23,6 +23,7 @@
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
+ #:use-module (guix hg-download)
#:use-module (guix utils)
#:use-module (guix build-system ant)
#:use-module (guix build-system gnu)
@@ -1518,3 +1519,48 @@ overly clever.")
mathematics and statistics components addressing the most common problems not
available in the Java programming language or Commons Lang.")
(license license:asl2.0)))
+
+(define-public java-jmh
+ (package
+ (name "java-jmh")
+ (version "1.17.5")
+ (source (origin
+ (method hg-fetch)
+ (uri (hg-reference
+ (url "http://hg.openjdk.java.net/code-tools/jmh/")
+ (changeset version)))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "1fxyxhg9famwcg1prc4cgwb5wzyxqavn3cjm5vz8605xz7x5k084"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "jmh-core.jar"
+ #:source-dir "jmh-core/src/main"
+ #:test-dir "jmh-core/src/test"
+ #:phases
+ (modify-phases %standard-phases
+ ;; This seems to be a bug in the JDK. It may not be necessary in
+ ;; future versions of the JDK.
+ (add-after 'unpack 'fix-bug
+ (lambda _
+ (with-directory-excursion
+ "jmh-core/src/main/java/org/openjdk/jmh/runner/options"
+ (substitute* '("IntegerValueConverter.java"
+ "ThreadsValueConverter.java")
+ (("public Class<Integer> valueType")
+ "public Class<? extends Integer> valueType")))
+ #t)))))
+ (inputs
+ `(("java-jopt-simple" ,java-jopt-simple)
+ ("java-commons-math3" ,java-commons-math3)))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://openjdk.java.net/projects/code-tools/jmh/")
+ (synopsis "Benchmark harness for the JVM")
+ (description "JMH is a Java harness for building, running, and analysing
+nano/micro/milli/macro benchmarks written in Java and other languages
+targetting the JVM.")
+ ;; GPLv2 only
+ (license license:gpl2)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 13/36] gnu: Add java-jmh.
2017-05-06 15:35 ` bug#26803: [PATCH 13/36] gnu: Add java-jmh Ricardo Wurmus
@ 2017-05-07 19:13 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-07 19:13 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-jmh): New variable.
> ---
> gnu/packages/java.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 46 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 5d131929c..36d80ff1d 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -23,6 +23,7 @@
> #:use-module ((guix licenses) #:prefix license:)
> #:use-module (guix packages)
> #:use-module (guix download)
> + #:use-module (guix hg-download)
> #:use-module (guix utils)
> #:use-module (guix build-system ant)
> #:use-module (guix build-system gnu)
> @@ -1518,3 +1519,48 @@ overly clever.")
> mathematics and statistics components addressing the most common problems not
> available in the Java programming language or Commons Lang.")
> (license license:asl2.0)))
> +
> +(define-public java-jmh
> + (package
> + (name "java-jmh")
> + (version "1.17.5")
> + (source (origin
> + (method hg-fetch)
> + (uri (hg-reference
> + (url "http://hg.openjdk.java.net/code-tools/jmh/")
> + (changeset version)))
> + (file-name (string-append name "-" version "-checkout"))
> + (sha256
> + (base32
> + "1fxyxhg9famwcg1prc4cgwb5wzyxqavn3cjm5vz8605xz7x5k084"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "jmh-core.jar"
> + #:source-dir "jmh-core/src/main"
> + #:test-dir "jmh-core/src/test"
> + #:phases
> + (modify-phases %standard-phases
> + ;; This seems to be a bug in the JDK. It may not be necessary in
> + ;; future versions of the JDK.
> + (add-after 'unpack 'fix-bug
> + (lambda _
> + (with-directory-excursion
> + "jmh-core/src/main/java/org/openjdk/jmh/runner/options"
> + (substitute* '("IntegerValueConverter.java"
> + "ThreadsValueConverter.java")
> + (("public Class<Integer> valueType")
> + "public Class<? extends Integer> valueType")))
> + #t)))))
> + (inputs
> + `(("java-jopt-simple" ,java-jopt-simple)
> + ("java-commons-math3" ,java-commons-math3)))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://openjdk.java.net/projects/code-tools/jmh/")
> + (synopsis "Benchmark harness for the JVM")
> + (description "JMH is a Java harness for building, running, and analysing
> +nano/micro/milli/macro benchmarks written in Java and other languages
> +targetting the JVM.")
> + ;; GPLv2 only
> + (license license:gpl2)))
Unfortunately GPLv2 only.
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 14/36] gnu: Add java-commons-collections4.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (11 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 13/36] gnu: Add java-jmh Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-07 19:16 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 15/36] gnu: Add java-commons-io Ricardo Wurmus
` (22 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-collections4): New variable.
---
gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 36d80ff1d..f595af58c 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1564,3 +1564,63 @@ nano/micro/milli/macro benchmarks written in Java and other languages
targetting the JVM.")
;; GPLv2 only
(license license:gpl2)))
+
+(define-public java-commons-collections4
+ (package
+ (name "java-commons-collections4")
+ (version "4.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/collections/source/"
+ "commons-collections4-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1krfhvggympq4avk7gh6qafzf6b9ip6r1m4lmacikyx04039m0wl"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:test-target "test"
+ #:make-flags
+ (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")
+ (string-append "-Deasymock.jar=" easymock
+ "/share/java/easymock.jar")))
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'install
+ (install-jars "target")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-easymock" ,java-easymock)))
+ (home-page "http://commons.apache.org/collections/")
+ (synopsis "Collections framework")
+ (description "The Java Collections Framework is the recognised standard
+for collection handling in Java. Commons-Collections seek to build upon the
+JDK classes by providing new interfaces, implementations and utilities. There
+are many features, including:
+
+@itemize
+@item @code{Bag} interface for collections that have a number of copies of
+ each object
+@item @code{BidiMap} interface for maps that can be looked up from value to
+ key as well and key to value
+@item @code{MapIterator} interface to provide simple and quick iteration over
+ maps
+@item Transforming decorators that alter each object as it is added to the
+ collection
+@item Composite collections that make multiple collections look like one
+@item Ordered maps and sets that retain the order elements are added in,
+ including an LRU based map
+@item Reference map that allows keys and/or values to be garbage collected
+ under close control
+@item Many comparator implementations
+@item Many iterator implementations
+@item Adapter classes from array and enumerations to collections
+@item Utilities to test or create typical set-theory properties of collections
+ such as union, intersection, and closure.
+@end itemize\n")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 14/36] gnu: Add java-commons-collections4.
2017-05-06 15:35 ` bug#26803: [PATCH 14/36] gnu: Add java-commons-collections4 Ricardo Wurmus
@ 2017-05-07 19:16 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-07 19:16 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-collections4): New variable.
> ---
> gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 60 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 36d80ff1d..f595af58c 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1564,3 +1564,63 @@ nano/micro/milli/macro benchmarks written in Java and other languages
> targetting the JVM.")
> ;; GPLv2 only
> (license license:gpl2)))
> +
> +(define-public java-commons-collections4
> + (package
> + (name "java-commons-collections4")
> + (version "4.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/collections/source/"
> + "commons-collections4-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1krfhvggympq4avk7gh6qafzf6b9ip6r1m4lmacikyx04039m0wl"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:test-target "test"
> + #:make-flags
> + (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")
> + (string-append "-Deasymock.jar=" easymock
> + "/share/java/easymock.jar")))
> + #:phases
Ha! Cool.
> + (modify-phases %standard-phases
> + (replace 'install
> + (install-jars "target")))))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)
> + ("java-easymock" ,java-easymock)))
> + (home-page "http://commons.apache.org/collections/")
> + (synopsis "Collections framework")
> + (description "The Java Collections Framework is the recognised standard
> +for collection handling in Java. Commons-Collections seek to build upon the
> +JDK classes by providing new interfaces, implementations and utilities. There
> +are many features, including:
> +
> +@itemize
> +@item @code{Bag} interface for collections that have a number of copies of
> + each object
> +@item @code{BidiMap} interface for maps that can be looked up from value to
> + key as well and key to value
> +@item @code{MapIterator} interface to provide simple and quick iteration over
> + maps
> +@item Transforming decorators that alter each object as it is added to the
> + collection
> +@item Composite collections that make multiple collections look like one
> +@item Ordered maps and sets that retain the order elements are added in,
> + including an LRU based map
> +@item Reference map that allows keys and/or values to be garbage collected
> + under close control
> +@item Many comparator implementations
> +@item Many iterator implementations
> +@item Adapter classes from array and enumerations to collections
> +@item Utilities to test or create typical set-theory properties of collections
> + such as union, intersection, and closure.
> +@end itemize\n")
> + (license license:asl2.0)))
Very elaborate description. Nice!
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 15/36] gnu: Add java-commons-io.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (12 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 14/36] gnu: Add java-commons-collections4 Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-08 10:41 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 16/36] gnu: Add java-commons-lang Ricardo Wurmus
` (21 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-io): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index f595af58c..c9707d0d2 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1624,3 +1624,44 @@ are many features, including:
such as union, intersection, and closure.
@end itemize\n")
(license license:asl2.0)))
+
+(define-public java-commons-io
+ (package
+ (name "java-commons-io")
+ (version "2.5")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/io/source/"
+ "commons-io-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "0q5y41jrcjvx9hzs47x5kdhnasdy6rm4bzqd2jxl02w717m7a7v3"))))
+ (build-system ant-build-system)
+ (outputs '("out" "doc"))
+ (arguments
+ `(#:test-target "test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'symlink-junit.jar
+ (lambda* (#:key inputs #:allow-other-keys)
+ ;; TODO: don't do this; use make-flags
+ ;; The existence of this file is taken as indicator whether test
+ ;; dependencies will to be downloaded.
+ (let ((junit (assoc-ref inputs "java-junit"))
+ (junit-version "4.12")) ; from build.xml
+ (mkdir-p "lib")
+ (symlink (string-append junit "/share/java/junit.jar")
+ (string-append "lib/junit-" junit-version ".jar"))
+ #t)))
+ (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-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://commons.apache.org/io/")
+ (synopsis "Common useful IO related classes")
+ (description "Commons-IO contains utility classes, stream implementations,
+file filters and endian classes.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 15/36] gnu: Add java-commons-io.
2017-05-06 15:35 ` bug#26803: [PATCH 15/36] gnu: Add java-commons-io Ricardo Wurmus
@ 2017-05-08 10:41 ` Roel Janssen
2017-05-10 14:10 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-08 10:41 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-io): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 41 +++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 41 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index f595af58c..c9707d0d2 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1624,3 +1624,44 @@ are many features, including:
> such as union, intersection, and closure.
> @end itemize\n")
> (license license:asl2.0)))
> +
> +(define-public java-commons-io
> + (package
> + (name "java-commons-io")
> + (version "2.5")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/io/source/"
> + "commons-io-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "0q5y41jrcjvx9hzs47x5kdhnasdy6rm4bzqd2jxl02w717m7a7v3"))))
> + (build-system ant-build-system)
> + (outputs '("out" "doc"))
> + (arguments
> + `(#:test-target "test"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'symlink-junit.jar
> + (lambda* (#:key inputs #:allow-other-keys)
> + ;; TODO: don't do this; use make-flags
> + ;; The existence of this file is taken as indicator whether test
> + ;; dependencies will to be downloaded.
> + (let ((junit (assoc-ref inputs "java-junit"))
> + (junit-version "4.12")) ; from build.xml
> + (mkdir-p "lib")
> + (symlink (string-append junit "/share/java/junit.jar")
> + (string-append "lib/junit-" junit-version ".jar"))
> + #t)))
I'm not sure how the result of the code here could be achieved
using 'make-flags', so is the TODO item referring to an already-removed
piece of code?
> + (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-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://commons.apache.org/io/")
> + (synopsis "Common useful IO related classes")
> + (description "Commons-IO contains utility classes, stream implementations,
> +file filters and endian classes.")
> + (license license:asl2.0)))
Otherwise, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 15/36] gnu: Add java-commons-io.
2017-05-08 10:41 ` Roel Janssen
@ 2017-05-10 14:10 ` Ricardo Wurmus
2017-05-10 14:24 ` Roel Janssen
0 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:10 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-commons-io): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
[…]
>> + (arguments
>> + `(#:test-target "test"
>> + #:phases
>> + (modify-phases %standard-phases
>> + (add-after 'unpack 'symlink-junit.jar
>> + (lambda* (#:key inputs #:allow-other-keys)
>> + ;; TODO: don't do this; use make-flags
>> + ;; The existence of this file is taken as indicator whether test
>> + ;; dependencies will to be downloaded.
>> + (let ((junit (assoc-ref inputs "java-junit"))
>> + (junit-version "4.12")) ; from build.xml
>> + (mkdir-p "lib")
>> + (symlink (string-append junit "/share/java/junit.jar")
>> + (string-append "lib/junit-" junit-version ".jar"))
>> + #t)))
>
> I'm not sure how the result of the code here could be achieved
> using 'make-flags', so is the TODO item referring to an already-removed
> piece of code?
Oh, I forgot about this. It’s actually pretty easy to do this with
make-flags:
#:make-flags
(list (string-append "-Djunit.jar="
(assoc-ref %build-inputs "java-junit")
"/share/java/junit.jar"))
Much nicer than symlinking things!
I’ll push it with this change.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 15/36] gnu: Add java-commons-io.
2017-05-10 14:10 ` Ricardo Wurmus
@ 2017-05-10 14:24 ` Roel Janssen
2017-05-10 14:34 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 14:24 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> Roel Janssen <roel@gnu.org> writes:
>
>> Ricardo Wurmus writes:
>>
>>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>>
>>> * gnu/packages/java.scm (java-commons-io): New variable.
>>>
>>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>>> ---
> […]
>>> + (arguments
>>> + `(#:test-target "test"
>>> + #:phases
>>> + (modify-phases %standard-phases
>>> + (add-after 'unpack 'symlink-junit.jar
>>> + (lambda* (#:key inputs #:allow-other-keys)
>>> + ;; TODO: don't do this; use make-flags
>>> + ;; The existence of this file is taken as indicator whether test
>>> + ;; dependencies will to be downloaded.
>>> + (let ((junit (assoc-ref inputs "java-junit"))
>>> + (junit-version "4.12")) ; from build.xml
>>> + (mkdir-p "lib")
>>> + (symlink (string-append junit "/share/java/junit.jar")
>>> + (string-append "lib/junit-" junit-version ".jar"))
>>> + #t)))
>>
>> I'm not sure how the result of the code here could be achieved
>> using 'make-flags', so is the TODO item referring to an already-removed
>> piece of code?
>
> Oh, I forgot about this. It’s actually pretty easy to do this with
> make-flags:
>
> #:make-flags
> (list (string-append "-Djunit.jar="
> (assoc-ref %build-inputs "java-junit")
> "/share/java/junit.jar"))
>
> Much nicer than symlinking things!
> I’ll push it with this change.
Yes, definitely. Very nice!
Is the "lib" directory automatically created this way?
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 15/36] gnu: Add java-commons-io.
2017-05-10 14:24 ` Roel Janssen
@ 2017-05-10 14:34 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:34 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> Roel Janssen <roel@gnu.org> writes:
>>
>>> Ricardo Wurmus writes:
>>>
>>>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>>>
>>>> * gnu/packages/java.scm (java-commons-io): New variable.
>>>>
>>>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>>>> ---
>> […]
>>>> + (arguments
>>>> + `(#:test-target "test"
>>>> + #:phases
>>>> + (modify-phases %standard-phases
>>>> + (add-after 'unpack 'symlink-junit.jar
>>>> + (lambda* (#:key inputs #:allow-other-keys)
>>>> + ;; TODO: don't do this; use make-flags
>>>> + ;; The existence of this file is taken as indicator whether test
>>>> + ;; dependencies will to be downloaded.
>>>> + (let ((junit (assoc-ref inputs "java-junit"))
>>>> + (junit-version "4.12")) ; from build.xml
>>>> + (mkdir-p "lib")
>>>> + (symlink (string-append junit "/share/java/junit.jar")
>>>> + (string-append "lib/junit-" junit-version ".jar"))
>>>> + #t)))
>>>
>>> I'm not sure how the result of the code here could be achieved
>>> using 'make-flags', so is the TODO item referring to an already-removed
>>> piece of code?
>>
>> Oh, I forgot about this. It’s actually pretty easy to do this with
>> make-flags:
>>
>> #:make-flags
>> (list (string-append "-Djunit.jar="
>> (assoc-ref %build-inputs "java-junit")
>> "/share/java/junit.jar"))
>>
>> Much nicer than symlinking things!
>> I’ll push it with this change.
>
> Yes, definitely. Very nice!
> Is the "lib" directory automatically created this way?
We don’t need it. Instead of putting the file where the defaults want
it to be we just tell it to look elsewhere, so no directory needs to be
created at all.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 16/36] gnu: Add java-commons-lang.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (13 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 15/36] gnu: Add java-commons-io Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-08 10:46 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3 Ricardo Wurmus
` (20 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-lang): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 55 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index c9707d0d2..7a68b6bd6 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1665,3 +1665,58 @@ are many features, including:
(description "Commons-IO contains utility classes, stream implementations,
file filters and endian classes.")
(license license:asl2.0)))
+
+(define-public java-commons-lang
+ (package
+ (name "java-commons-lang")
+ (version "2.6")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/lang/source/"
+ "commons-lang-" version "-src.tar.gz"))
+ (sha256
+ (base32 "1mxwagqadzx1b2al7i0z1v0r235aj2njdyijf02szq0vhmqrfiq5"))))
+ (build-system ant-build-system)
+ (outputs '("out" "doc"))
+ (arguments
+ `(#:test-target "test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'build 'build-javadoc ant-build-javadoc)
+ (add-before 'check 'disable-failing-test
+ (lambda _
+ ;; Disable a failing test
+ (substitute* "src/test/java/org/apache/commons/lang/\
+time/FastDateFormatTest.java"
+ (("public void testFormat\\(\\)")
+ "public void disabled_testFormat()"))
+ #t))
+ (replace 'install (install-jars "target"))
+ (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (home-page "http://commons.apache.org/lang/")
+ (synopsis "Extension of the java.lang package")
+ (description "The Commons Lang components contains a set of Java classes
+that provide helper methods for standard Java classes, especially those found
+in the @code{java.lang} package in the Sun JDK. The following classes are
+included:
+
+@itemize
+@item StringUtils - Helper for @code{java.lang.String}.
+@item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets
+ of characters such as @code{[a-z]} and @code{[abcdez]}.
+@item RandomStringUtils - Helper for creating randomised strings.
+@item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
+@item NumberRange - A range of numbers with an upper and lower bound.
+@item ObjectUtils - Helper for @code{java.lang.Object}.
+@item SerializationUtils - Helper for serializing objects.
+@item SystemUtils - Utility class defining the Java system properties.
+@item NestedException package - A sub-package for the creation of nested
+ exceptions.
+@item Enum package - A sub-package for the creation of enumerated types.
+@item Builder package - A sub-package for the creation of @code{equals},
+ @code{hashCode}, @code{compareTo} and @code{toString} methods.
+@end itemize\n")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 16/36] gnu: Add java-commons-lang.
2017-05-06 15:35 ` bug#26803: [PATCH 16/36] gnu: Add java-commons-lang Ricardo Wurmus
@ 2017-05-08 10:46 ` Roel Janssen
2017-05-10 14:13 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-08 10:46 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-lang): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 55 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index c9707d0d2..7a68b6bd6 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1665,3 +1665,58 @@ are many features, including:
> (description "Commons-IO contains utility classes, stream implementations,
> file filters and endian classes.")
> (license license:asl2.0)))
> +
> +(define-public java-commons-lang
> + (package
> + (name "java-commons-lang")
> + (version "2.6")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/lang/source/"
> + "commons-lang-" version "-src.tar.gz"))
> + (sha256
> + (base32 "1mxwagqadzx1b2al7i0z1v0r235aj2njdyijf02szq0vhmqrfiq5"))))
> + (build-system ant-build-system)
> + (outputs '("out" "doc"))
> + (arguments
> + `(#:test-target "test"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'build 'build-javadoc ant-build-javadoc)
> + (add-before 'check 'disable-failing-test
> + (lambda _
> + ;; Disable a failing test
> + (substitute* "src/test/java/org/apache/commons/lang/\
> +time/FastDateFormatTest.java"
> + (("public void testFormat\\(\\)")
> + "public void disabled_testFormat()"))
> + #t))
Since you're renaming the function, I suppose removing the function
would also work, which would not create any "dead code". But that
probably requires a separate patch file, which will break more easily
on an update.
So long story short: This is OK to me, even though I don't like
producing code that won't be run anyway.
> + (replace 'install (install-jars "target"))
> + (add-after 'install 'install-doc (install-javadoc "target/apidocs")))))
> + (native-inputs
> + `(("java-junit" ,java-junit)))
> + (home-page "http://commons.apache.org/lang/")
> + (synopsis "Extension of the java.lang package")
> + (description "The Commons Lang components contains a set of Java classes
> +that provide helper methods for standard Java classes, especially those found
> +in the @code{java.lang} package in the Sun JDK. The following classes are
> +included:
> +
> +@itemize
> +@item StringUtils - Helper for @code{java.lang.String}.
> +@item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets
> + of characters such as @code{[a-z]} and @code{[abcdez]}.
> +@item RandomStringUtils - Helper for creating randomised strings.
> +@item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
> +@item NumberRange - A range of numbers with an upper and lower bound.
> +@item ObjectUtils - Helper for @code{java.lang.Object}.
> +@item SerializationUtils - Helper for serializing objects.
> +@item SystemUtils - Utility class defining the Java system properties.
> +@item NestedException package - A sub-package for the creation of nested
> + exceptions.
> +@item Enum package - A sub-package for the creation of enumerated types.
> +@item Builder package - A sub-package for the creation of @code{equals},
> + @code{hashCode}, @code{compareTo} and @code{toString} methods.
> +@end itemize\n")
> + (license license:asl2.0)))
I've seen the '\n' on an earlier patch as well. Why is it neccessary?
Otherwise, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 16/36] gnu: Add java-commons-lang.
2017-05-08 10:46 ` Roel Janssen
@ 2017-05-10 14:13 ` Ricardo Wurmus
2017-05-10 14:23 ` Roel Janssen
0 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:13 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-commons-lang): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
[…]
>> + (arguments
>> + `(#:test-target "test"
>> + #:phases
>> + (modify-phases %standard-phases
>> + (add-after 'build 'build-javadoc ant-build-javadoc)
>> + (add-before 'check 'disable-failing-test
>> + (lambda _
>> + ;; Disable a failing test
>> + (substitute* "src/test/java/org/apache/commons/lang/\
>> +time/FastDateFormatTest.java"
>> + (("public void testFormat\\(\\)")
>> + "public void disabled_testFormat()"))
>> + #t))
>
> Since you're renaming the function, I suppose removing the function
> would also work, which would not create any "dead code". But that
> probably requires a separate patch file, which will break more easily
> on an update.
>
> So long story short: This is OK to me, even though I don't like
> producing code that won't be run anyway.
I agree in principle, but this is the Java way of disabling a test.
Tests are considered tests only when the procedures start with the
string “test”, so renaming the test causes it not to be executed.
Removing requires much more effort because it requires an actual patch.
Since it’s just a test (and not library code) I think it’s acceptable
not to delete it.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 16/36] gnu: Add java-commons-lang.
2017-05-10 14:13 ` Ricardo Wurmus
@ 2017-05-10 14:23 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 14:23 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> Roel Janssen <roel@gnu.org> writes:
>
>> Ricardo Wurmus writes:
>>
>>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>>
>>> * gnu/packages/java.scm (java-commons-lang): New variable.
>>>
>>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>>> ---
> […]
>>> + (arguments
>>> + `(#:test-target "test"
>>> + #:phases
>>> + (modify-phases %standard-phases
>>> + (add-after 'build 'build-javadoc ant-build-javadoc)
>>> + (add-before 'check 'disable-failing-test
>>> + (lambda _
>>> + ;; Disable a failing test
>>> + (substitute* "src/test/java/org/apache/commons/lang/\
>>> +time/FastDateFormatTest.java"
>>> + (("public void testFormat\\(\\)")
>>> + "public void disabled_testFormat()"))
>>> + #t))
>>
>> Since you're renaming the function, I suppose removing the function
>> would also work, which would not create any "dead code". But that
>> probably requires a separate patch file, which will break more easily
>> on an update.
>>
>> So long story short: This is OK to me, even though I don't like
>> producing code that won't be run anyway.
>
> I agree in principle, but this is the Java way of disabling a test.
> Tests are considered tests only when the procedures start with the
> string “test”, so renaming the test causes it not to be executed.
> Removing requires much more effort because it requires an actual patch.
> Since it’s just a test (and not library code) I think it’s acceptable
> not to delete it.
I agree. So, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (14 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 16/36] gnu: Add java-commons-lang Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-08 11:20 ` Roel Janssen
2017-05-06 15:35 ` bug#26803: [PATCH 18/36] gnu: Add java-commons-cli Ricardo Wurmus
` (19 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-lang3): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 64 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 7a68b6bd6..3e422ac80 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1720,3 +1720,67 @@ included:
@code{hashCode}, @code{compareTo} and @code{toString} methods.
@end itemize\n")
(license license:asl2.0)))
+
+(define-public java-commons-lang3
+ (package
+ (name "java-commons-lang3")
+ (version "3.4")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/lang/source/"
+ "commons-lang3-" version "-src.tar.gz"))
+ (sha256
+ (base32 "0xpshb9spjhplq5a7mr0y1bgfw8190ik4xj8f569xidfcki1d6kg"))))
+ (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")))
+ #: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)))
+ (home-page "http://commons.apache.org/lang/")
+ (synopsis "Extension of the java.lang package (for Java 5+)")
+ (description "The Commons Lang components contains a set of Java classes
+that provide helper methods for standard Java classes, especially those found
+in the @code{java.lang} package in the JDK 5+. The following classes are
+included:
+
+@itemize
+@item StringUtils - Helper for @code{java.lang.String}.
+@item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets of
+ characters such as @code{[a-z]} and @code{[abcdez]}.
+@item RandomStringUtils - Helper for creating randomised strings.
+@item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
+@item NumberRange - A range of numbers with an upper and lower bound.
+@item ObjectUtils - Helper for @code{java.lang.Object}.
+@item SerializationUtils - Helper for serializing objects.
+@item SystemUtils - Utility class defining the Java system properties.
+@item NestedException package - A sub-package for the creation of nested
+ exceptions.
+@item Enum package - A sub-package for the creation of enumerated types.
+@item Builder package - A sub-package for the creation of @code{equals},
+ @code{hashCode}, @code{compareTo} and @code{toString} methods.
+@end itemize\n")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3.
2017-05-06 15:35 ` bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3 Ricardo Wurmus
@ 2017-05-08 11:20 ` Roel Janssen
2017-05-10 14:23 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-08 11:20 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-lang3): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 64 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 7a68b6bd6..3e422ac80 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1720,3 +1720,67 @@ included:
> @code{hashCode}, @code{compareTo} and @code{toString} methods.
> @end itemize\n")
> (license license:asl2.0)))
> +
> +(define-public java-commons-lang3
> + (package
> + (name "java-commons-lang3")
> + (version "3.4")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/lang/source/"
> + "commons-lang3-" version "-src.tar.gz"))
> + (sha256
> + (base32 "0xpshb9spjhplq5a7mr0y1bgfw8190ik4xj8f569xidfcki1d6kg"))))
> + (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")))
> + #: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)))
> + (home-page "http://commons.apache.org/lang/")
> + (synopsis "Extension of the java.lang package (for Java 5+)")
Is the (for Java 5+) still relevant? Even 6 has been deprecated, so it
seems to be for any supported Java version now.
> + (description "The Commons Lang components contains a set of Java classes
> +that provide helper methods for standard Java classes, especially those found
> +in the @code{java.lang} package in the JDK 5+. The following classes are
Same here.
> +included:
> +
> +@itemize
> +@item StringUtils - Helper for @code{java.lang.String}.
> +@item CharSetUtils - Methods for dealing with @code{CharSets}, which are sets of
> + characters such as @code{[a-z]} and @code{[abcdez]}.
> +@item RandomStringUtils - Helper for creating randomised strings.
> +@item NumberUtils - Helper for @code{java.lang.Number} and its subclasses.
> +@item NumberRange - A range of numbers with an upper and lower bound.
> +@item ObjectUtils - Helper for @code{java.lang.Object}.
> +@item SerializationUtils - Helper for serializing objects.
> +@item SystemUtils - Utility class defining the Java system properties.
> +@item NestedException package - A sub-package for the creation of nested
> + exceptions.
> +@item Enum package - A sub-package for the creation of enumerated types.
> +@item Builder package - A sub-package for the creation of @code{equals},
> + @code{hashCode}, @code{compareTo} and @code{toString} methods.
> +@end itemize\n")
> + (license license:asl2.0)))
Either way, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3.
2017-05-08 11:20 ` Roel Janssen
@ 2017-05-10 14:23 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:23 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-commons-lang3): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
[…]
>> + (home-page "http://commons.apache.org/lang/")
>> + (synopsis "Extension of the java.lang package (for Java 5+)")
>
> Is the (for Java 5+) still relevant? Even 6 has been deprecated, so it
> seems to be for any supported Java version now.
>
>> + (description "The Commons Lang components contains a set of Java classes
>> +that provide helper methods for standard Java classes, especially those found
>> +in the @code{java.lang} package in the JDK 5+. The following classes are
>
> Same here.
I think you’re right. I’ve removed mention of JDK 5+, because it
doesn’t seem very useful any more.
Thanks!
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 18/36] gnu: Add java-commons-cli.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (15 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 17/36] gnu: Add java-commons-lang3 Ricardo Wurmus
@ 2017-05-06 15:35 ` Ricardo Wurmus
2017-05-08 14:13 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 19/36] gnu: Add java-commons-codec Ricardo Wurmus
` (18 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:35 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-cli): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 37 +++++++++++++++++++++++++++++++++++++
1 file changed, 37 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 3e422ac80..0220435af 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1784,3 +1784,40 @@ included:
@code{hashCode}, @code{compareTo} and @code{toString} methods.
@end itemize\n")
(license license:asl2.0)))
+
+(define-public java-commons-cli
+ (package
+ (name "java-commons-cli")
+ (version "1.3.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/cli/source/"
+ "commons-cli-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1fkjn552i12vp3xxk21ws4p70fi0lyjm004vzxsdaz7gdpgyxxyl"))))
+ (build-system ant-build-system)
+ ;; TODO: javadoc
+ (arguments
+ `(#:jar-name "commons-cli.jar"))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://commons.apache.org/cli/")
+ (synopsis "Command line arguments and options parsing library")
+ (description "The Apache Commons CLI library provides an API for parsing
+command line options passed to programs. It is also able to print help
+messages detailing the options available for a command line tool.
+
+Commons CLI supports different types of options:
+
+@itemize
+@item POSIX like options (ie. tar -zxvf foo.tar.gz)
+@item GNU like long options (ie. du --human-readable --max-depth=1)
+@item Java like properties (ie. java -Djava.awt.headless=true Foo)
+@item Short options with value attached (ie. gcc -O2 foo.c)
+@item long options with single hyphen (ie. ant -projecthelp)
+@end itemize
+
+This is a part of the Apache Commons Project.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 18/36] gnu: Add java-commons-cli.
2017-05-06 15:35 ` bug#26803: [PATCH 18/36] gnu: Add java-commons-cli Ricardo Wurmus
@ 2017-05-08 14:13 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-08 14:13 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-cli): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 37 +++++++++++++++++++++++++++++++++++++
> 1 file changed, 37 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 3e422ac80..0220435af 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1784,3 +1784,40 @@ included:
> @code{hashCode}, @code{compareTo} and @code{toString} methods.
> @end itemize\n")
> (license license:asl2.0)))
> +
> +(define-public java-commons-cli
> + (package
> + (name "java-commons-cli")
> + (version "1.3.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/cli/source/"
> + "commons-cli-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1fkjn552i12vp3xxk21ws4p70fi0lyjm004vzxsdaz7gdpgyxxyl"))))
> + (build-system ant-build-system)
> + ;; TODO: javadoc
> + (arguments
> + `(#:jar-name "commons-cli.jar"))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://commons.apache.org/cli/")
> + (synopsis "Command line arguments and options parsing library")
> + (description "The Apache Commons CLI library provides an API for parsing
> +command line options passed to programs. It is also able to print help
> +messages detailing the options available for a command line tool.
> +
> +Commons CLI supports different types of options:
> +
> +@itemize
> +@item POSIX like options (ie. tar -zxvf foo.tar.gz)
> +@item GNU like long options (ie. du --human-readable --max-depth=1)
> +@item Java like properties (ie. java -Djava.awt.headless=true Foo)
> +@item Short options with value attached (ie. gcc -O2 foo.c)
> +@item long options with single hyphen (ie. ant -projecthelp)
> +@end itemize
> +
> +This is a part of the Apache Commons Project.")
> + (license license:asl2.0)))
Even though there's a to-do for the Javadoc documentation stuff, this is
LGTM, because it is not essential to its functioning.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 19/36] gnu: Add java-commons-codec.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (16 preceding siblings ...)
2017-05-06 15:35 ` bug#26803: [PATCH 18/36] gnu: Add java-commons-cli Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 10:09 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon Ricardo Wurmus
` (17 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-codec): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 46 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 0220435af..e4913973d 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1821,3 +1821,49 @@ Commons CLI supports different types of options:
This is a part of the Apache Commons Project.")
(license license:asl2.0)))
+
+(define-public java-commons-codec
+ (package
+ (name "java-commons-codec")
+ (version "1.10")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/codec/source/"
+ "commons-codec-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1w9qg30y4s0x8gnmr2fgj4lyplfn788jqxbcz27lf5kbr6n8xr65"))))
+ (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"))
+ #:phases
+ ;; TODO: I don't like this
+ (modify-phases %standard-phases
+ (add-after 'build 'build-javadoc
+ ant-build-javadoc)
+ (replace 'install
+ (install-jars "dist"))
+ ;; TODO: do this if javadoc argument is given?
+ (add-after 'install 'install-doc
+ (install-javadoc "dist/docs/api")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://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
+various formats such as Base64 and Hexadecimal. In addition to these widely
+used encoders and decoders, the codec package also maintains a collection of
+phonetic encoding utilities.
+
+This is a part of the Apache Commons Project.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 19/36] gnu: Add java-commons-codec.
2017-05-06 15:36 ` bug#26803: [PATCH 19/36] gnu: Add java-commons-codec Ricardo Wurmus
@ 2017-05-10 10:09 ` Roel Janssen
2017-05-10 14:25 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 10:09 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-codec): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 46 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 0220435af..e4913973d 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1821,3 +1821,49 @@ Commons CLI supports different types of options:
>
> This is a part of the Apache Commons Project.")
> (license license:asl2.0)))
> +
> +(define-public java-commons-codec
> + (package
> + (name "java-commons-codec")
> + (version "1.10")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/codec/source/"
> + "commons-codec-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1w9qg30y4s0x8gnmr2fgj4lyplfn788jqxbcz27lf5kbr6n8xr65"))))
> + (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"))
> + #:phases
> + ;; TODO: I don't like this
> + (modify-phases %standard-phases
> + (add-after 'build 'build-javadoc
> + ant-build-javadoc)
> + (replace 'install
> + (install-jars "dist"))
> + ;; TODO: do this if javadoc argument is given?
> + (add-after 'install 'install-doc
> + (install-javadoc "dist/docs/api")))))
Is this a good moment to look into these TODOs? I don't think they are
that bad, and the output includes the Javadoc stuff, right?
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://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
> +various formats such as Base64 and Hexadecimal. In addition to these widely
> +used encoders and decoders, the codec package also maintains a collection of
> +phonetic encoding utilities.
> +
> +This is a part of the Apache Commons Project.")
> + (license license:asl2.0)))
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 19/36] gnu: Add java-commons-codec.
2017-05-10 10:09 ` Roel Janssen
@ 2017-05-10 14:25 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 14:25 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-commons-codec): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
[…]
>> + (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"))
>> + #:phases
>> + ;; TODO: I don't like this
>> + (modify-phases %standard-phases
>> + (add-after 'build 'build-javadoc
>> + ant-build-javadoc)
>> + (replace 'install
>> + (install-jars "dist"))
>> + ;; TODO: do this if javadoc argument is given?
>> + (add-after 'install 'install-doc
>> + (install-javadoc "dist/docs/api")))))
>
> Is this a good moment to look into these TODOs? I don't think they are
> that bad, and the output includes the Javadoc stuff, right?
Yeah, I think I don’t feel so strongly about this any more. I’ve
removed the TODOs.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (17 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 19/36] gnu: Add java-commons-codec Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 10:12 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 21/36] gnu: Add java-jmock-1 Ricardo Wurmus
` (16 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Hartmut Goebel
From: Hartmut Goebel <h.goebel@crazy-compilers.com>
* gnu/packages/java.scm (java-commons-daemon): New variable.
Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
---
gnu/packages/java.scm | 34 ++++++++++++++++++++++++++++++++++
1 file changed, 34 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index e4913973d..af6b0761f 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1867,3 +1867,37 @@ phonetic encoding utilities.
This is a part of the Apache Commons Project.")
(license license:asl2.0)))
+
+(define-public java-commons-daemon
+ (package
+ (name "java-commons-daemon")
+ (version "1.0.15")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/daemon/source/"
+ "commons-daemon-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "0ci46kq8jpz084ccwq0mmkahcgsmh20ziclp2jf5i0djqv95gvhi"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:test-target "test"
+ #: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")))))
+ (native-inputs
+ `(("java-junit" ,java-junit)))
+ (home-page "http://commons.apache.org/daemon/")
+ (synopsis "Library to launch Java applications as daemons")
+ (description "The Daemon package from Apache Commons can be used to
+implement Java applications which can be launched as daemons. For example the
+program will be notified about a shutdown so that it can perform cleanup tasks
+before its process of execution is destroyed by the operation system.
+
+This package contains the java library. You will also need the actual binary
+for your architecture which is provided by the jsvc package.
+
+This is a part of the Apache Commons Project.")
+ (license license:asl2.0)))
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon.
2017-05-06 15:36 ` bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon Ricardo Wurmus
@ 2017-05-10 10:12 ` Roel Janssen
2017-05-10 16:03 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 10:12 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * gnu/packages/java.scm (java-commons-daemon): New variable.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> gnu/packages/java.scm | 34 ++++++++++++++++++++++++++++++++++
> 1 file changed, 34 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index e4913973d..af6b0761f 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1867,3 +1867,37 @@ phonetic encoding utilities.
>
> This is a part of the Apache Commons Project.")
> (license license:asl2.0)))
> +
> +(define-public java-commons-daemon
> + (package
> + (name "java-commons-daemon")
> + (version "1.0.15")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/daemon/source/"
> + "commons-daemon-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "0ci46kq8jpz084ccwq0mmkahcgsmh20ziclp2jf5i0djqv95gvhi"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:test-target "test"
> + #: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")))))
> + (native-inputs
> + `(("java-junit" ,java-junit)))
> + (home-page "http://commons.apache.org/daemon/")
> + (synopsis "Library to launch Java applications as daemons")
> + (description "The Daemon package from Apache Commons can be used to
I'm not sure about the usage of the @code{}, but maybe @code{Daemon} or
'Daemon'?
> +implement Java applications which can be launched as daemons. For example the
> +program will be notified about a shutdown so that it can perform cleanup tasks
> +before its process of execution is destroyed by the operation system.
> +
> +This package contains the java library. You will also need the actual binary
maybe Java instead?
> +for your architecture which is provided by the jsvc package.
maybe @code{jsvc}?
> +
> +This is a part of the Apache Commons Project.")
> + (license license:asl2.0)))
Otherwise LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon.
2017-05-10 10:12 ` Roel Janssen
@ 2017-05-10 16:03 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 16:03 UTC (permalink / raw)
To: Roel Janssen; +Cc: Hartmut Goebel, 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>>
>> * gnu/packages/java.scm (java-commons-daemon): New variable.
>>
>> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
>> ---
>> gnu/packages/java.scm | 34 ++++++++++++++++++++++++++++++++++
>> 1 file changed, 34 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index e4913973d..af6b0761f 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1867,3 +1867,37 @@ phonetic encoding utilities.
>>
>> This is a part of the Apache Commons Project.")
>> (license license:asl2.0)))
>> +
>> +(define-public java-commons-daemon
>> + (package
>> + (name "java-commons-daemon")
>> + (version "1.0.15")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "mirror://apache/commons/daemon/source/"
>> + "commons-daemon-" version "-src.tar.gz"))
>> + (sha256
>> + (base32
>> + "0ci46kq8jpz084ccwq0mmkahcgsmh20ziclp2jf5i0djqv95gvhi"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:test-target "test"
>> + #: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")))))
>> + (native-inputs
>> + `(("java-junit" ,java-junit)))
>> + (home-page "http://commons.apache.org/daemon/")
>> + (synopsis "Library to launch Java applications as daemons")
>> + (description "The Daemon package from Apache Commons can be used to
>
> I'm not sure about the usage of the @code{}, but maybe @code{Daemon} or
> 'Daemon'?
I think it’s fine the way it is. The project name is Daemon; the
jar/class name is different, so @code{} would not be appropriate.
>> +implement Java applications which can be launched as daemons. For example the
>> +program will be notified about a shutdown so that it can perform cleanup tasks
>> +before its process of execution is destroyed by the operation system.
>> +
>> +This package contains the java library. You will also need the actual binary
>
> maybe Java instead?
Yes, you’re right.
>> +for your architecture which is provided by the jsvc package.
>
> maybe @code{jsvc}?
If we had @package{} I would have used it here, but @code{} wouldn’t be
right either. (We also don’t have a jsvc package yet, so … not sure.)
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 21/36] gnu: Add java-jmock-1.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (18 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 20/36] gnu: Add java-commons-daemon Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 10:15 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target Ricardo Wurmus
` (15 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-jmock-1): New variable.
---
gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index af6b0761f..3271dd55c 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1448,6 +1448,42 @@ constructor on object instantiation.")
mock objects in unit testing.")
(license license:asl2.0)))
+(define-public java-jmock-1
+ (package
+ (name "java-jmock")
+ (version "1.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/jmock-developers/"
+ "jmock-library/archive/" version ".tar.gz"))
+ (file-name (string-append "jmock-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0xmrlhq0fszldkbv281k9463mv496143vvmqwpxp62yzjvdkx9w0"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:build-target "jars"
+ #:test-target "run.tests"
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'install (install-jars "build")))))
+ (home-page "http://www.jmock.org")
+ (synopsis "Mock object library for Test Driven Development")
+ (description "JMock is a library that supports test-driven development of
+Java code with mock objects. Mock objects help you design and test the
+interactions between the objects in your programs.
+
+The jMock library
+
+@itemize
+@item makes it quick and easy to define mock objects
+@item lets you precisely specify the interactions between
+ your objects, reducing the brittleness of your tests
+@item plugs into your favourite test framework
+@item is easy to extend.
+@end itemize\n")
+ (license license:bsd-3)))
+
(define-public java-jopt-simple
(package
(name "java-jopt-simple")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 21/36] gnu: Add java-jmock-1.
2017-05-06 15:36 ` bug#26803: [PATCH 21/36] gnu: Add java-jmock-1 Ricardo Wurmus
@ 2017-05-10 10:15 ` Roel Janssen
2017-05-10 16:00 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 10:15 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-jmock-1): New variable.
> ---
> gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
> 1 file changed, 36 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index af6b0761f..3271dd55c 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1448,6 +1448,42 @@ constructor on object instantiation.")
> mock objects in unit testing.")
> (license license:asl2.0)))
>
> +(define-public java-jmock-1
> + (package
> + (name "java-jmock")
> + (version "1.2.0")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "https://github.com/jmock-developers/"
> + "jmock-library/archive/" version ".tar.gz"))
> + (file-name (string-append "jmock-" version ".tar.gz"))
> + (sha256
> + (base32
> + "0xmrlhq0fszldkbv281k9463mv496143vvmqwpxp62yzjvdkx9w0"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:build-target "jars"
> + #:test-target "run.tests"
> + #:phases
> + (modify-phases %standard-phases
> + (replace 'install (install-jars "build")))))
> + (home-page "http://www.jmock.org")
> + (synopsis "Mock object library for Test Driven Development")
I think it should be "test-driven development" (lowercase and a -).
> + (description "JMock is a library that supports test-driven development of
Like on this line.
> +Java code with mock objects. Mock objects help you design and test the
> +interactions between the objects in your programs.
> +
> +The jMock library
> +
> +@itemize
> +@item makes it quick and easy to define mock objects
> +@item lets you precisely specify the interactions between
> + your objects, reducing the brittleness of your tests
> +@item plugs into your favourite test framework
> +@item is easy to extend.
> +@end itemize\n")
> + (license license:bsd-3)))
> +
> (define-public java-jopt-simple
> (package
> (name "java-jopt-simple")
Otherwise LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 21/36] gnu: Add java-jmock-1.
2017-05-10 10:15 ` Roel Janssen
@ 2017-05-10 16:00 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 16:00 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-jmock-1): New variable.
>> ---
[…]
>> + (arguments
>> + `(#:build-target "jars"
>> + #:test-target "run.tests"
>> + #:phases
>> + (modify-phases %standard-phases
>> + (replace 'install (install-jars "build")))))
>> + (home-page "http://www.jmock.org")
>> + (synopsis "Mock object library for Test Driven Development")
>
> I think it should be "test-driven development" (lowercase and a -).
You are right!
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (19 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 21/36] gnu: Add java-jmock-1 Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 10:15 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 23/36] gnu: Add java-hamcrest-all Ricardo Wurmus
` (14 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-hamcrest-core)[arguments]: Add value for
test-target.
---
gnu/packages/java.scm | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 3271dd55c..2a5797a5c 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1087,6 +1087,7 @@ an Ant task that extends the built-in @code{jar} task.")
(guix build utils)
(srfi srfi-1))
#:make-flags (list (string-append "-Dversion=" ,version))
+ #:test-target "unit-test"
#:build-target "core"
#:phases
(modify-phases %standard-phases
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target.
2017-05-06 15:36 ` bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target Ricardo Wurmus
@ 2017-05-10 10:15 ` Roel Janssen
2017-05-10 16:04 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 10:15 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-hamcrest-core)[arguments]: Add value for
> test-target.
> ---
> gnu/packages/java.scm | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 3271dd55c..2a5797a5c 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1087,6 +1087,7 @@ an Ant task that extends the built-in @code{jar} task.")
> (guix build utils)
> (srfi srfi-1))
> #:make-flags (list (string-append "-Dversion=" ,version))
> + #:test-target "unit-test"
> #:build-target "core"
> #:phases
> (modify-phases %standard-phases
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target.
2017-05-10 10:15 ` Roel Janssen
@ 2017-05-10 16:04 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 16:04 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-hamcrest-core)[arguments]: Add value for
>> test-target.
>> ---
>> gnu/packages/java.scm | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 3271dd55c..2a5797a5c 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1087,6 +1087,7 @@ an Ant task that extends the built-in @code{jar} task.")
>> (guix build utils)
>> (srfi srfi-1))
>> #:make-flags (list (string-append "-Dversion=" ,version))
>> + #:test-target "unit-test"
>> #:build-target "core"
>> #:phases
>> (modify-phases %standard-phases
>
> LGTM!
Thank you very much for your review so far! I’ve pushed the packages up
to this one. Less than 14 to go for this patch set :)
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 23/36] gnu: Add java-hamcrest-all.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (20 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 22/36] gnu: java-hamcrest-core: Declare test target Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 18:02 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 24/36] gnu: Add java-jsr305 Ricardo Wurmus
` (13 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-hamcrest-all): New variable.
---
gnu/packages/java.scm | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 2a5797a5c..8006b4d21 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1485,6 +1485,39 @@ The jMock library
@end itemize\n")
(license license:bsd-3)))
+(define-public java-hamcrest-all
+ (package (inherit java-hamcrest-core)
+ (name "java-hamcrest-all")
+ (arguments
+ (substitute-keyword-arguments (package-arguments java-hamcrest-core)
+ ;; FIXME: a range of unit tests fail because
+ ;; org.hamcrest.SelfDescribing is not found, although it is part of the
+ ;; hamcrest-core library that has just been built.
+ ((#:tests? _) #f)
+ ((#:build-target _) "bigjar")
+ ((#:phases phases)
+ `(modify-phases ,phases
+ ;; Some build targets override the classpath, so we need to patch
+ ;; the build.xml to ensure that required dependencies are on the
+ ;; classpath.
+ (add-after 'unpack 'patch-classpath-for-integration
+ (lambda* (#:key inputs #:allow-other-keys)
+ (substitute* "build.xml"
+ (("( build/hamcrest-library-\\$\\{version\\}.jar)" line)
+ (string-join
+ (cons line
+ (append
+ (find-files (assoc-ref inputs "java-junit") "\\.jar$")
+ (find-files (assoc-ref inputs "java-jmock") "\\.jar$")
+ (find-files (assoc-ref inputs "java-easymock") "\\.jar$")))
+ ";")))
+ #t))))))
+ (inputs
+ `(("java-junit" ,java-junit)
+ ("java-jmock" ,java-jmock-1)
+ ("java-easymock" ,java-easymock)
+ ,@(package-inputs java-hamcrest-core)))))
+
(define-public java-jopt-simple
(package
(name "java-jopt-simple")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 23/36] gnu: Add java-hamcrest-all.
2017-05-06 15:36 ` bug#26803: [PATCH 23/36] gnu: Add java-hamcrest-all Ricardo Wurmus
@ 2017-05-10 18:02 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 18:02 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-hamcrest-all): New variable.
> ---
> gnu/packages/java.scm | 33 +++++++++++++++++++++++++++++++++
> 1 file changed, 33 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 2a5797a5c..8006b4d21 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1485,6 +1485,39 @@ The jMock library
> @end itemize\n")
> (license license:bsd-3)))
>
> +(define-public java-hamcrest-all
> + (package (inherit java-hamcrest-core)
> + (name "java-hamcrest-all")
> + (arguments
> + (substitute-keyword-arguments (package-arguments java-hamcrest-core)
> + ;; FIXME: a range of unit tests fail because
> + ;; org.hamcrest.SelfDescribing is not found, although it is part of the
> + ;; hamcrest-core library that has just been built.
This looks like fun.. :-)
> + ((#:tests? _) #f)
> + ((#:build-target _) "bigjar")
> + ((#:phases phases)
> + `(modify-phases ,phases
> + ;; Some build targets override the classpath, so we need to patch
> + ;; the build.xml to ensure that required dependencies are on the
> + ;; classpath.
> + (add-after 'unpack 'patch-classpath-for-integration
> + (lambda* (#:key inputs #:allow-other-keys)
> + (substitute* "build.xml"
> + (("( build/hamcrest-library-\\$\\{version\\}.jar)" line)
> + (string-join
> + (cons line
> + (append
> + (find-files (assoc-ref inputs "java-junit") "\\.jar$")
> + (find-files (assoc-ref inputs "java-jmock") "\\.jar$")
> + (find-files (assoc-ref inputs "java-easymock") "\\.jar$")))
> + ";")))
> + #t))))))
> + (inputs
> + `(("java-junit" ,java-junit)
> + ("java-jmock" ,java-jmock-1)
> + ("java-easymock" ,java-easymock)
> + ,@(package-inputs java-hamcrest-core)))))
> +
> (define-public java-jopt-simple
> (package
> (name "java-jopt-simple")
I learned some new constructs in this patch.
Anyway, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 24/36] gnu: Add java-jsr305.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (21 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 23/36] gnu: Add java-hamcrest-all Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 18:04 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 25/36] gnu: Add java-guava Ricardo Wurmus
` (12 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-jsr305): New variable.
---
gnu/packages/java.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 8006b4d21..3a104f4c5 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1855,6 +1855,29 @@ included:
@end itemize\n")
(license license:asl2.0)))
+(define-public java-jsr305
+ (package
+ (name "java-jsr305")
+ (version "3.0.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://repo1.maven.org/maven2/"
+ "com/google/code/findbugs/"
+ "jsr305/" version "/jsr305-"
+ version "-sources.jar"))
+ (sha256
+ (base32
+ "1rh6jin9v7jqpq3kf1swl868l8i94r636n03pzpsmgr8v0lh9j2n"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; no tests included
+ #:jar-name "jsr305.jar"))
+ (home-page "http://findbugs.sourceforge.net/")
+ (synopsis "Annotations for the static analyzer called findbugs")
+ (description "This package provides annotations for the findbugs package.
+It provides packages in the @code{javax.annotations} namespace.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 24/36] gnu: Add java-jsr305.
2017-05-06 15:36 ` bug#26803: [PATCH 24/36] gnu: Add java-jsr305 Ricardo Wurmus
@ 2017-05-10 18:04 ` Roel Janssen
2017-05-11 9:27 ` julien lepiller
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 18:04 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-jsr305): New variable.
> ---
> gnu/packages/java.scm | 23 +++++++++++++++++++++++
> 1 file changed, 23 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 8006b4d21..3a104f4c5 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1855,6 +1855,29 @@ included:
> @end itemize\n")
> (license license:asl2.0)))
>
> +(define-public java-jsr305
> + (package
> + (name "java-jsr305")
> + (version "3.0.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "http://repo1.maven.org/maven2/"
> + "com/google/code/findbugs/"
> + "jsr305/" version "/jsr305-"
> + version "-sources.jar"))
> + (sha256
> + (base32
> + "1rh6jin9v7jqpq3kf1swl868l8i94r636n03pzpsmgr8v0lh9j2n"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:tests? #f ; no tests included
> + #:jar-name "jsr305.jar"))
> + (home-page "http://findbugs.sourceforge.net/")
> + (synopsis "Annotations for the static analyzer called findbugs")
> + (description "This package provides annotations for the findbugs package.
> +It provides packages in the @code{javax.annotations} namespace.")
Yes! I think I start to understand it now. javax.annotations is
code-related because it's the name of the namespace.. Hence, @code{}.
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
This looks straightforward, so LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 24/36] gnu: Add java-jsr305.
2017-05-10 18:04 ` Roel Janssen
@ 2017-05-11 9:27 ` julien lepiller
0 siblings, 0 replies; 103+ messages in thread
From: julien lepiller @ 2017-05-11 9:27 UTC (permalink / raw)
To: 26803
Le 2017-05-10 20:04, Roel Janssen a écrit :
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-jsr305): New variable.
>> ---
>> gnu/packages/java.scm | 23 +++++++++++++++++++++++
>> 1 file changed, 23 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 8006b4d21..3a104f4c5 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1855,6 +1855,29 @@ included:
>> @end itemize\n")
>> (license license:asl2.0)))
>>
>> +(define-public java-jsr305
>> + (package
>> + (name "java-jsr305")
>> + (version "3.0.1")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "http://repo1.maven.org/maven2/"
>> + "com/google/code/findbugs/"
>> + "jsr305/" version "/jsr305-"
>> + version "-sources.jar"))
>> + (sha256
>> + (base32
>> +
>> "1rh6jin9v7jqpq3kf1swl868l8i94r636n03pzpsmgr8v0lh9j2n"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:tests? #f ; no tests included
>> + #:jar-name "jsr305.jar"))
>> + (home-page "http://findbugs.sourceforge.net/")
>> + (synopsis "Annotations for the static analyzer called findbugs")
>> + (description "This package provides annotations for the findbugs
>> package.
>> +It provides packages in the @code{javax.annotations} namespace.")
>
> Yes! I think I start to understand it now. javax.annotations is
> code-related because it's the name of the namespace.. Hence, @code{}.
>
>> + (license license:asl2.0)))
>> +
>> (define-public java-commons-cli
>> (package
>> (name "java-commons-cli")
>
> This looks straightforward, so LGTM!
>
> Kind regards,
> Roel Janssen
Hi,
I found a version 3.0.2 on github, although I'm not sure whether that's
the "official" jsr305 :
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/amaembo/jsr-305.git")
(commit
"d7734b13c61492982784560ed5b4f4bd6cf9bb2c")))
(file-name (string-append name "-" version))
(sha256
(base32
"1wk159136pgc6i54drbq2whazfmdilvfqlxj3k19s9dfwbayf621"))))
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 25/36] gnu: Add java-guava.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (22 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 24/36] gnu: Add java-jsr305 Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 18:06 ` Roel Janssen
2017-05-11 9:38 ` julien lepiller
2017-05-06 15:36 ` bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal Ricardo Wurmus
` (11 subsequent siblings)
35 siblings, 2 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-guava): New variable.
---
gnu/packages/java.scm | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 52 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 3a104f4c5..a9faf681d 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1878,6 +1878,58 @@ included:
It provides packages in the @code{javax.annotations} namespace.")
(license license:asl2.0)))
+(define-public java-guava
+ (package
+ (name "java-guava")
+ ;; 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"))
+ (sha256
+ (base32
+ "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; no tests included
+ #:jar-name "guava.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'trim-sources
+ (lambda _
+ (with-directory-excursion "src/com/google/common"
+ ;; Remove annotations to avoid extra dependencies:
+ ;; * "j2objc" annotations are used when converting Java to
+ ;; Objective C;
+ ;; * "errorprone" annotations catch common Java mistakes at
+ ;; compile time;
+ ;; * "IgnoreJRERequirement" is used for Android.
+ (substitute* (find-files "." "\\.java$")
+ (("import com.google.j2objc.*") "")
+ (("import com.google.errorprone.annotation.*") "")
+ (("import org.codehaus.mojo.animal_sniffer.*") "")
+ (("@CanIgnoreReturnValue") "")
+ (("@LazyInit") "")
+ (("@WeakOuter") "")
+ (("@RetainedWith") "")
+ (("@Weak") "")
+ (("@ForOverride") "")
+ (("@J2ObjCIncompatible") "")
+ (("@IgnoreJRERequirement") "")))
+ #t)))))
+ (inputs
+ `(("java-jsr305" ,java-jsr305)))
+ (home-page "https://github.com/google/guava")
+ (synopsis "Google core libraries for Java")
+ (description "Guava is a set of core libraries that includes new
+collection types (such as multimap and multiset), immutable collections, a
+graph library, functional types, an in-memory cache, and APIs/utilities for
+concurrency, I/O, hashing, primitives, reflection, string processing, and much
+more!")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 25/36] gnu: Add java-guava.
2017-05-06 15:36 ` bug#26803: [PATCH 25/36] gnu: Add java-guava Ricardo Wurmus
@ 2017-05-10 18:06 ` Roel Janssen
2017-05-10 19:43 ` Ricardo Wurmus
2017-05-11 9:38 ` julien lepiller
1 sibling, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 18:06 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-guava): New variable.
> ---
> gnu/packages/java.scm | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 52 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 3a104f4c5..a9faf681d 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1878,6 +1878,58 @@ included:
> It provides packages in the @code{javax.annotations} namespace.")
> (license license:asl2.0)))
>
> +(define-public java-guava
> + (package
> + (name "java-guava")
> + ;; 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"))
> + (sha256
> + (base32
> + "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:tests? #f ; no tests included
Not really important. But should we indent the comments this way?
> + #:jar-name "guava.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'trim-sources
> + (lambda _
> + (with-directory-excursion "src/com/google/common"
> + ;; Remove annotations to avoid extra dependencies:
> + ;; * "j2objc" annotations are used when converting Java to
> + ;; Objective C;
> + ;; * "errorprone" annotations catch common Java mistakes at
> + ;; compile time;
> + ;; * "IgnoreJRERequirement" is used for Android.
> + (substitute* (find-files "." "\\.java$")
> + (("import com.google.j2objc.*") "")
> + (("import com.google.errorprone.annotation.*") "")
> + (("import org.codehaus.mojo.animal_sniffer.*") "")
> + (("@CanIgnoreReturnValue") "")
> + (("@LazyInit") "")
> + (("@WeakOuter") "")
> + (("@RetainedWith") "")
> + (("@Weak") "")
> + (("@ForOverride") "")
> + (("@J2ObjCIncompatible") "")
> + (("@IgnoreJRERequirement") "")))
> + #t)))))
> + (inputs
> + `(("java-jsr305" ,java-jsr305)))
> + (home-page "https://github.com/google/guava")
> + (synopsis "Google core libraries for Java")
> + (description "Guava is a set of core libraries that includes new
> +collection types (such as multimap and multiset), immutable collections, a
> +graph library, functional types, an in-memory cache, and APIs/utilities for
> +concurrency, I/O, hashing, primitives, reflection, string processing, and much
> +more!")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 25/36] gnu: Add java-guava.
2017-05-10 18:06 ` Roel Janssen
@ 2017-05-10 19:43 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 19:43 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-guava): New variable.
>> ---
>> gnu/packages/java.scm | 52 +++++++++++++++++++++++++++++++++++++++++++++++++++
>> 1 file changed, 52 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 3a104f4c5..a9faf681d 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1878,6 +1878,58 @@ included:
>> It provides packages in the @code{javax.annotations} namespace.")
>> (license license:asl2.0)))
>>
>> +(define-public java-guava
>> + (package
>> + (name "java-guava")
>> + ;; 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"))
>> + (sha256
>> + (base32
>> + "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:tests? #f ; no tests included
>
> Not really important. But should we indent the comments this way?
This is what Emacs does when indenting the whole expression. I have no
preference either way, so I left it.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 25/36] gnu: Add java-guava.
2017-05-06 15:36 ` bug#26803: [PATCH 25/36] gnu: Add java-guava Ricardo Wurmus
2017-05-10 18:06 ` Roel Janssen
@ 2017-05-11 9:38 ` julien lepiller
1 sibling, 0 replies; 103+ messages in thread
From: julien lepiller @ 2017-05-11 9:38 UTC (permalink / raw)
To: 26803
Le 2017-05-06 17:36, Ricardo Wurmus a écrit :
> * gnu/packages/java.scm (java-guava): New variable.
> ---
> gnu/packages/java.scm | 52
> +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 52 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 3a104f4c5..a9faf681d 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1878,6 +1878,58 @@ included:
> It provides packages in the @code{javax.annotations} namespace.")
> (license license:asl2.0)))
>
> +(define-public java-guava
> + (package
> + (name "java-guava")
> + ;; 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"))
> + (sha256
> + (base32
> +
> "1gawrs5gi6j5hcfxdgpnfli75vb9pfi4sn09pnc8xacr669yajwr"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:tests? #f ; no tests included
> + #:jar-name "guava.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'trim-sources
> + (lambda _
> + (with-directory-excursion "src/com/google/common"
> + ;; Remove annotations to avoid extra dependencies:
> + ;; * "j2objc" annotations are used when converting Java
> to
> + ;; Objective C;
> + ;; * "errorprone" annotations catch common Java
> mistakes at
> + ;; compile time;
> + ;; * "IgnoreJRERequirement" is used for Android.
> + (substitute* (find-files "." "\\.java$")
> + (("import com.google.j2objc.*") "")
> + (("import com.google.errorprone.annotation.*") "")
> + (("import org.codehaus.mojo.animal_sniffer.*") "")
> + (("@CanIgnoreReturnValue") "")
> + (("@LazyInit") "")
> + (("@WeakOuter") "")
> + (("@RetainedWith") "")
> + (("@Weak") "")
> + (("@ForOverride") "")
> + (("@J2ObjCIncompatible") "")
> + (("@IgnoreJRERequirement") "")))
> + #t)))))
> + (inputs
> + `(("java-jsr305" ,java-jsr305)))
> + (home-page "https://github.com/google/guava")
> + (synopsis "Google core libraries for Java")
> + (description "Guava is a set of core libraries that includes new
> +collection types (such as multimap and multiset), immutable
> collections, a
> +graph library, functional types, an in-memory cache, and
> APIs/utilities for
> +concurrency, I/O, hashing, primitives, reflection, string processing,
> and much
> +more!")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
Hi, I have a recipe for errorprone, j2objc and animal-sniffer, although
they're still WIP. I simply split them in two, one part with the
annotations only that are required for guava, and the rest that requires
guava. This requires patches to get two separate jar files. I'll send
something this evening. Anyway, if that works, I think we can start by
this recipe and add the annotation packages later.
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (23 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 25/36] gnu: Add java-guava Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-10 18:09 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 27/36] gnu: Add java-mockito-1 Ricardo Wurmus
` (10 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-logging-minimal): New variable.
---
gnu/packages/java.scm | 47 +++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index a9faf681d..859f9934a 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1930,6 +1930,53 @@ concurrency, I/O, hashing, primitives, reflection, string processing, and much
more!")
(license license:asl2.0)))
+;; 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.
+(define-public java-commons-logging-minimal
+ (package
+ (name "java-commons-logging-minimal")
+ (version "1.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/logging/source/"
+ "commons-logging-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "10bwcy5w8d7y39n0krlwhnp8ds3kj5zhmzj0zxnkw0qdlsjmsrj9"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:tests? #f ; avoid dependency on logging frameworks
+ #:jar-name "commons-logging-minimal.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'delete-adapters-and-tests
+ (lambda _
+ ;; Delete all adapters except for NoOpLog, SimpleLog, and
+ ;; LogFactoryImpl. NoOpLog is required to build; LogFactoryImpl
+ ;; is used by applications; SimpleLog is the only actually usable
+ ;; implementation that does not depend on another logging
+ ;; framework.
+ (for-each
+ (lambda (file)
+ (delete-file (string-append
+ "src/main/java/org/apache/commons/logging/impl/" file)))
+ (list "Jdk13LumberjackLogger.java"
+ "WeakHashtable.java"
+ "Log4JLogger.java"
+ "ServletContextCleaner.java"
+ "Jdk14Logger.java"
+ "AvalonLogger.java"
+ "LogKitLogger.java"))
+ (delete-file-recursively "src/test")
+ #t)))))
+ (home-page "http://commons.apache.org/logging/")
+ (synopsis "Common API for logging implementations")
+ (description "The Logging package is a thin bridge between different
+logging implementations. A library that uses the commons-logging API can be
+used with any logging implementation at runtime.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal.
2017-05-06 15:36 ` bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal Ricardo Wurmus
@ 2017-05-10 18:09 ` Roel Janssen
2017-05-10 19:46 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-10 18:09 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-logging-minimal): New variable.
> ---
> gnu/packages/java.scm | 47 +++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 47 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index a9faf681d..859f9934a 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1930,6 +1930,53 @@ concurrency, I/O, hashing, primitives, reflection, string processing, and much
> more!")
> (license license:asl2.0)))
>
> +;; 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.
> +(define-public java-commons-logging-minimal
> + (package
> + (name "java-commons-logging-minimal")
> + (version "1.2")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/logging/source/"
> + "commons-logging-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "10bwcy5w8d7y39n0krlwhnp8ds3kj5zhmzj0zxnkw0qdlsjmsrj9"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:tests? #f ; avoid dependency on logging frameworks
> + #:jar-name "commons-logging-minimal.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'delete-adapters-and-tests
> + (lambda _
> + ;; Delete all adapters except for NoOpLog, SimpleLog, and
> + ;; LogFactoryImpl. NoOpLog is required to build; LogFactoryImpl
> + ;; is used by applications; SimpleLog is the only actually usable
> + ;; implementation that does not depend on another logging
> + ;; framework.
> + (for-each
> + (lambda (file)
> + (delete-file (string-append
> + "src/main/java/org/apache/commons/logging/impl/" file)))
> + (list "Jdk13LumberjackLogger.java"
> + "WeakHashtable.java"
> + "Log4JLogger.java"
> + "ServletContextCleaner.java"
> + "Jdk14Logger.java"
> + "AvalonLogger.java"
> + "LogKitLogger.java"))
> + (delete-file-recursively "src/test")
Interesting.
> + #t)))))
> + (home-page "http://commons.apache.org/logging/")
> + (synopsis "Common API for logging implementations")
> + (description "The Logging package is a thin bridge between different
> +logging implementations. A library that uses the commons-logging API can be
> +used with any logging implementation at runtime.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM!
I have to fix the Guile 2.0 -> 2.2 transition now, so it'll take a
little longer before I can comment on the next patch.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal.
2017-05-10 18:09 ` Roel Janssen
@ 2017-05-10 19:46 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-10 19:46 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-commons-logging-minimal): New variable.
>> ---
[…]
>
> LGTM!
>
> I have to fix the Guile 2.0 -> 2.2 transition now, so it'll take a
> little longer before I can comment on the next patch.
Thank you very much! I’ve pushed the patches up to this point.
10 to go! Lets see if someone else would like to join the party and
review the rest :)
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 27/36] gnu: Add java-mockito-1.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (24 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 26/36] gnu: Add java-commons-logging-minimal Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:13 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 28/36] gnu: Add java-httpcomponents-httpcore Ricardo Wurmus
` (9 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-mockito): New variable.
---
gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 859f9934a..2cf2821c0 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -1977,6 +1977,66 @@ logging implementations. A library that uses the commons-logging API can be
used with any logging implementation at runtime.")
(license license:asl2.0)))
+;; This is the last release of the 1.x series.
+(define-public java-mockito-1
+ (package
+ (name "java-mockito")
+ (version "1.10.19")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://repo1.maven.org/maven2/"
+ "org/mockito/mockito-core/" version
+ "/mockito-core-" version "-sources.jar"))
+ (sha256
+ (base32
+ "0vmiwnwpf83g2q7kj1rislmja8fpvqkixjhawh7nxnygx6pq11kc"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "mockito.jar"
+ #:tests? #f ; no tests included
+ ;; FIXME: patch-and-repack does not support jars, so we have to apply
+ ;; patches in build phases.
+ #:phases
+ (modify-phases %standard-phases
+ ;; Mockito fails to build with our verson of hamcrest without this
+ ;; definition.
+ (add-after 'unpack 'fix-hamcrest-build-error
+ (lambda _
+ (substitute* "src/org/mockito/internal/matchers/LocalizedMatcher.java"
+ (("public Matcher getActualMatcher\\(\\) .*" line)
+ (string-append "
+ public void describeMismatch(Object item, Description description) {
+ actualMatcher.describeMismatch(item, description);
+ }"
+ line)))
+ #t))
+ ;; Mockito bundles cglib. We have a cglib package, so let's use
+ ;; that instead.
+ (add-after 'unpack 'use-system-libraries
+ (lambda _
+ (with-directory-excursion "src/org/mockito/internal/creation/cglib"
+ (substitute* '("CGLIBHacker.java"
+ "CglibMockMaker.java"
+ "ClassImposterizer.java"
+ "DelegatingMockitoMethodProxy.java"
+ "MethodInterceptorFilter.java"
+ "MockitoNamingPolicy.java"
+ "SerializableMockitoMethodProxy.java"
+ "SerializableNoOp.java")
+ (("import org.mockito.cglib") "import net.sf.cglib")))
+ #t)))))
+ (inputs
+ `(("java-junit" ,java-junit)
+ ("java-objenesis" ,java-objenesis)
+ ("java-cglib" ,java-cglib)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://mockito.org")
+ (synopsis "Mockito is a mock library for Java")
+ (description "Mockito is a mocking library for Java which lets you write
+tests with a clean and simple API. It generates mocks using reflection, and
+it records all mock invocations, including methods arguments.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 27/36] gnu: Add java-mockito-1.
2017-05-06 15:36 ` bug#26803: [PATCH 27/36] gnu: Add java-mockito-1 Ricardo Wurmus
@ 2017-05-11 8:13 ` Roel Janssen
2017-05-11 8:22 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:13 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-mockito): New variable.
> ---
> gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 60 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 859f9934a..2cf2821c0 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -1977,6 +1977,66 @@ logging implementations. A library that uses the commons-logging API can be
> used with any logging implementation at runtime.")
> (license license:asl2.0)))
>
> +;; This is the last release of the 1.x series.
> +(define-public java-mockito-1
> + (package
> + (name "java-mockito")
> + (version "1.10.19")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "http://repo1.maven.org/maven2/"
> + "org/mockito/mockito-core/" version
> + "/mockito-core-" version "-sources.jar"))
> + (sha256
> + (base32
> + "0vmiwnwpf83g2q7kj1rislmja8fpvqkixjhawh7nxnygx6pq11kc"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "mockito.jar"
> + #:tests? #f ; no tests included
> + ;; FIXME: patch-and-repack does not support jars, so we have to apply
> + ;; patches in build phases.
> + #:phases
> + (modify-phases %standard-phases
> + ;; Mockito fails to build with our verson of hamcrest without this
> + ;; definition.
> + (add-after 'unpack 'fix-hamcrest-build-error
> + (lambda _
> + (substitute* "src/org/mockito/internal/matchers/LocalizedMatcher.java"
> + (("public Matcher getActualMatcher\\(\\) .*" line)
> + (string-append "
> + public void describeMismatch(Object item, Description description) {
> + actualMatcher.describeMismatch(item, description);
> + }"
> + line)))
> + #t))
I understand this is easier and possibly less error-prone than creating
a patch file instead, but how far are we going with adding/removing code
inside the package recipes?
As far as the actual code addition goes, it is pretty straightforward:
It adds a function that hamcrest expects is available. Maybe add a
comment describing this? Then it's OK to me.
> + ;; Mockito bundles cglib. We have a cglib package, so let's use
> + ;; that instead.
> + (add-after 'unpack 'use-system-libraries
> + (lambda _
> + (with-directory-excursion "src/org/mockito/internal/creation/cglib"
> + (substitute* '("CGLIBHacker.java"
> + "CglibMockMaker.java"
> + "ClassImposterizer.java"
> + "DelegatingMockitoMethodProxy.java"
> + "MethodInterceptorFilter.java"
> + "MockitoNamingPolicy.java"
> + "SerializableMockitoMethodProxy.java"
> + "SerializableNoOp.java")
> + (("import org.mockito.cglib") "import net.sf.cglib")))
> + #t)))))
Nice unbundling!
> + (inputs
> + `(("java-junit" ,java-junit)
> + ("java-objenesis" ,java-objenesis)
> + ("java-cglib" ,java-cglib)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://mockito.org")
> + (synopsis "Mockito is a mock library for Java")
> + (description "Mockito is a mocking library for Java which lets you write
> +tests with a clean and simple API. It generates mocks using reflection, and
> +it records all mock invocations, including methods arguments.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
Otherwise, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 27/36] gnu: Add java-mockito-1.
2017-05-11 8:13 ` Roel Janssen
@ 2017-05-11 8:22 ` Ricardo Wurmus
2017-05-11 8:57 ` Roel Janssen
0 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-11 8:22 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-mockito): New variable.
>> ---
>> gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
>> 1 file changed, 60 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 859f9934a..2cf2821c0 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -1977,6 +1977,66 @@ logging implementations. A library that uses the commons-logging API can be
>> used with any logging implementation at runtime.")
>> (license license:asl2.0)))
>>
>> +;; This is the last release of the 1.x series.
>> +(define-public java-mockito-1
>> + (package
>> + (name "java-mockito")
>> + (version "1.10.19")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "http://repo1.maven.org/maven2/"
>> + "org/mockito/mockito-core/" version
>> + "/mockito-core-" version "-sources.jar"))
>> + (sha256
>> + (base32
>> + "0vmiwnwpf83g2q7kj1rislmja8fpvqkixjhawh7nxnygx6pq11kc"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:jar-name "mockito.jar"
>> + #:tests? #f ; no tests included
>> + ;; FIXME: patch-and-repack does not support jars, so we have to apply
>> + ;; patches in build phases.
>> + #:phases
>> + (modify-phases %standard-phases
>> + ;; Mockito fails to build with our verson of hamcrest without this
>> + ;; definition.
>> + (add-after 'unpack 'fix-hamcrest-build-error
>> + (lambda _
>> + (substitute* "src/org/mockito/internal/matchers/LocalizedMatcher.java"
>> + (("public Matcher getActualMatcher\\(\\) .*" line)
>> + (string-append "
>> + public void describeMismatch(Object item, Description description) {
>> + actualMatcher.describeMismatch(item, description);
>> + }"
>> + line)))
>> + #t))
>
> I understand this is easier and possibly less error-prone than creating
> a patch file instead, but how far are we going with adding/removing code
> inside the package recipes?
There’s a FIXME comment above the #:phases. I would like to use a patch
in this case, but patch-and-repack does not support jars. We usually
unpack the sources, apply the patches, and then repack the sources, but
this currently doesn’t work for jars.
This is why I must do this in build phases.
> As far as the actual code addition goes, it is pretty straightforward:
> It adds a function that hamcrest expects is available. Maybe add a
> comment describing this? Then it's OK to me.
Okay, I’ll add a better comment here.
Thanks!
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 27/36] gnu: Add java-mockito-1.
2017-05-11 8:22 ` Ricardo Wurmus
@ 2017-05-11 8:57 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:57 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> Roel Janssen <roel@gnu.org> writes:
>
>> Ricardo Wurmus writes:
>>
>>> * gnu/packages/java.scm (java-mockito): New variable.
>>> ---
>>> gnu/packages/java.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
>>> 1 file changed, 60 insertions(+)
>>>
>>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>>> index 859f9934a..2cf2821c0 100644
>>> --- a/gnu/packages/java.scm
>>> +++ b/gnu/packages/java.scm
>>> @@ -1977,6 +1977,66 @@ logging implementations. A library that uses the commons-logging API can be
>>> used with any logging implementation at runtime.")
>>> (license license:asl2.0)))
>>>
>>> +;; This is the last release of the 1.x series.
>>> +(define-public java-mockito-1
>>> + (package
>>> + (name "java-mockito")
>>> + (version "1.10.19")
>>> + (source (origin
>>> + (method url-fetch)
>>> + (uri (string-append "http://repo1.maven.org/maven2/"
>>> + "org/mockito/mockito-core/" version
>>> + "/mockito-core-" version "-sources.jar"))
>>> + (sha256
>>> + (base32
>>> + "0vmiwnwpf83g2q7kj1rislmja8fpvqkixjhawh7nxnygx6pq11kc"))))
>>> + (build-system ant-build-system)
>>> + (arguments
>>> + `(#:jar-name "mockito.jar"
>>> + #:tests? #f ; no tests included
>>> + ;; FIXME: patch-and-repack does not support jars, so we have to apply
>>> + ;; patches in build phases.
>>> + #:phases
>>> + (modify-phases %standard-phases
>>> + ;; Mockito fails to build with our verson of hamcrest without this
>>> + ;; definition.
>>> + (add-after 'unpack 'fix-hamcrest-build-error
>>> + (lambda _
>>> + (substitute* "src/org/mockito/internal/matchers/LocalizedMatcher.java"
>>> + (("public Matcher getActualMatcher\\(\\) .*" line)
>>> + (string-append "
>>> + public void describeMismatch(Object item, Description description) {
>>> + actualMatcher.describeMismatch(item, description);
>>> + }"
>>> + line)))
>>> + #t))
>>
>> I understand this is easier and possibly less error-prone than creating
>> a patch file instead, but how far are we going with adding/removing code
>> inside the package recipes?
>
> There’s a FIXME comment above the #:phases. I would like to use a patch
> in this case, but patch-and-repack does not support jars. We usually
> unpack the sources, apply the patches, and then repack the sources, but
> this currently doesn’t work for jars.
>
> This is why I must do this in build phases.
Right. Too bad this doesn't work for Java archives.
>> As far as the actual code addition goes, it is pretty straightforward:
>> It adds a function that hamcrest expects is available. Maybe add a
>> comment describing this? Then it's OK to me.
>
> Okay, I’ll add a better comment here.
>
> Thanks!
Okay. LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 28/36] gnu: Add java-httpcomponents-httpcore.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (25 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 27/36] gnu: Add java-mockito-1 Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:16 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 29/36] gnu: Add java-httpcomponents-httpcore-nio Ricardo Wurmus
` (8 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-httpcomponents-httpcore): New variable.
---
gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 2cf2821c0..a770cd4cc 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2037,6 +2037,42 @@ tests with a clean and simple API. It generates mocks using reflection, and
it records all mock invocations, including methods arguments.")
(license license:asl2.0)))
+(define-public java-httpcomponents-httpcore
+ (package
+ (name "java-httpcomponents-httpcore")
+ (version "4.4.6")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache//httpcomponents/httpcore/"
+ "source/httpcomponents-core-"
+ version "-src.tar.gz"))
+ (sha256
+ (base32
+ "02bwcf38y4vgwq7kj2s6q7qrmma641r5lacivm16kgxvb2j6h1vy"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "httpcomponents-httpcore.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "httpcore") #t)))))
+ (inputs
+ `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
+ ("java-commons-lang3" ,java-commons-lang3)))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-mockito" ,java-mockito-1)))
+ (home-page "https://hc.apache.org/httpcomponents-core-4.4.x/index.html")
+ (synopsis "Low level HTTP transport components")
+ (description "HttpCore is a set of low level HTTP transport components
+that can be used to build custom client and server side HTTP services with a
+minimal footprint. HttpCore supports two I/O models: blocking I/O model based
+on the classic Java I/O and non-blocking, event driven I/O model based on Java
+NIO.
+
+This package provides the blocking I/O model library.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 28/36] gnu: Add java-httpcomponents-httpcore.
2017-05-06 15:36 ` bug#26803: [PATCH 28/36] gnu: Add java-httpcomponents-httpcore Ricardo Wurmus
@ 2017-05-11 8:16 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:16 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-httpcomponents-httpcore): New variable.
> ---
> gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
> 1 file changed, 36 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 2cf2821c0..a770cd4cc 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2037,6 +2037,42 @@ tests with a clean and simple API. It generates mocks using reflection, and
> it records all mock invocations, including methods arguments.")
> (license license:asl2.0)))
>
> +(define-public java-httpcomponents-httpcore
> + (package
> + (name "java-httpcomponents-httpcore")
> + (version "4.4.6")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache//httpcomponents/httpcore/"
> + "source/httpcomponents-core-"
> + version "-src.tar.gz"))
> + (sha256
> + (base32
> + "02bwcf38y4vgwq7kj2s6q7qrmma641r5lacivm16kgxvb2j6h1vy"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "httpcomponents-httpcore.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "httpcore") #t)))))
> + (inputs
> + `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
> + ("java-commons-lang3" ,java-commons-lang3)))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-mockito" ,java-mockito-1)))
> + (home-page "https://hc.apache.org/httpcomponents-core-4.4.x/index.html")
> + (synopsis "Low level HTTP transport components")
> + (description "HttpCore is a set of low level HTTP transport components
> +that can be used to build custom client and server side HTTP services with a
> +minimal footprint. HttpCore supports two I/O models: blocking I/O model based
> +on the classic Java I/O and non-blocking, event driven I/O model based on Java
> +NIO.
I think you're referring to "HttpCore" as in the API. Is an API
@code{}?
> +
> +This package provides the blocking I/O model library.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 29/36] gnu: Add java-httpcomponents-httpcore-nio.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (26 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 28/36] gnu: Add java-httpcomponents-httpcore Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:18 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 30/36] gnu: Add java-httpcomponents-httpcore-ab Ricardo Wurmus
` (7 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-httpcomponents-httpcore-nio): New variable.
---
gnu/packages/java.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index a770cd4cc..620a276d0 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2073,6 +2073,28 @@ NIO.
This package provides the blocking I/O model library.")
(license license:asl2.0)))
+(define-public java-httpcomponents-httpcore-nio
+ (package (inherit java-httpcomponents-httpcore)
+ (name "java-httpcomponents-httpcore-nio")
+ (arguments
+ `(#:jar-name "httpcomponents-httpcore-nio.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "httpcore-nio") #t)))))
+ (inputs
+ `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ,@(package-inputs java-httpcomponents-httpcore)))
+ (description "HttpCore is a set of low level HTTP transport components
+that can be used to build custom client and server side HTTP services with a
+minimal footprint. HttpCore supports two I/O models: blocking I/O model based
+on the classic Java I/O and non-blocking, event driven I/O model based on Java
+NIO.
+
+This package provides the non-blocking I/O model library based on Java
+NIO.")))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 29/36] gnu: Add java-httpcomponents-httpcore-nio.
2017-05-06 15:36 ` bug#26803: [PATCH 29/36] gnu: Add java-httpcomponents-httpcore-nio Ricardo Wurmus
@ 2017-05-11 8:18 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:18 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-httpcomponents-httpcore-nio): New variable.
> ---
> gnu/packages/java.scm | 22 ++++++++++++++++++++++
> 1 file changed, 22 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index a770cd4cc..620a276d0 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2073,6 +2073,28 @@ NIO.
> This package provides the blocking I/O model library.")
> (license license:asl2.0)))
>
> +(define-public java-httpcomponents-httpcore-nio
> + (package (inherit java-httpcomponents-httpcore)
> + (name "java-httpcomponents-httpcore-nio")
> + (arguments
> + `(#:jar-name "httpcomponents-httpcore-nio.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "httpcore-nio") #t)))))
> + (inputs
> + `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
> + ("java-hamcrest-core" ,java-hamcrest-core)
> + ,@(package-inputs java-httpcomponents-httpcore)))
> + (description "HttpCore is a set of low level HTTP transport components
> +that can be used to build custom client and server side HTTP services with a
> +minimal footprint. HttpCore supports two I/O models: blocking I/O model based
> +on the classic Java I/O and non-blocking, event driven I/O model based on Java
> +NIO.
> +
> +This package provides the non-blocking I/O model library based on Java
> +NIO.")))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
Same suggestion as the 'java-httpcomponents-httpcore'
patch. @code{HttpCore} or just HttpCore? I don't know, so it's up to
you. :-)
Otherwise, LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 30/36] gnu: Add java-httpcomponents-httpcore-ab.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (27 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 29/36] gnu: Add java-httpcomponents-httpcore-nio Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:30 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient Ricardo Wurmus
` (6 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-httpcomponents-httpcore-ab): New variable.
---
gnu/packages/java.scm | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 620a276d0..19642cbfc 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2095,6 +2095,24 @@ NIO.
This package provides the non-blocking I/O model library based on Java
NIO.")))
+(define-public java-httpcomponents-httpcore-ab
+ (package (inherit java-httpcomponents-httpcore)
+ (name "java-httpcomponents-httpcore-ab")
+ (arguments
+ `(#:jar-name "httpcomponents-httpcore-ab.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "httpcore-ab") #t)))))
+ (inputs
+ `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
+ ("java-commons-cli" ,java-commons-cli)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ,@(package-inputs java-httpcomponents-httpcore)))
+ (synopsis "Apache HttpCore benchmarking tool")
+ (description "This package provides the HttpCore benchmarking tool. It is
+an Apache AB clone based on HttpCore.")))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 30/36] gnu: Add java-httpcomponents-httpcore-ab.
2017-05-06 15:36 ` bug#26803: [PATCH 30/36] gnu: Add java-httpcomponents-httpcore-ab Ricardo Wurmus
@ 2017-05-11 8:30 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:30 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-httpcomponents-httpcore-ab): New variable.
> ---
> gnu/packages/java.scm | 18 ++++++++++++++++++
> 1 file changed, 18 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 620a276d0..19642cbfc 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2095,6 +2095,24 @@ NIO.
> This package provides the non-blocking I/O model library based on Java
> NIO.")))
>
> +(define-public java-httpcomponents-httpcore-ab
> + (package (inherit java-httpcomponents-httpcore)
> + (name "java-httpcomponents-httpcore-ab")
> + (arguments
> + `(#:jar-name "httpcomponents-httpcore-ab.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "httpcore-ab") #t)))))
> + (inputs
> + `(("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
> + ("java-commons-cli" ,java-commons-cli)
> + ("java-hamcrest-core" ,java-hamcrest-core)
> + ,@(package-inputs java-httpcomponents-httpcore)))
> + (synopsis "Apache HttpCore benchmarking tool")
> + (description "This package provides the HttpCore benchmarking tool. It is
> +an Apache AB clone based on HttpCore.")))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
HttpCore again.
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (28 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 30/36] gnu: Add java-httpcomponents-httpcore-ab Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:32 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 32/36] gnu: Add java-httpcomponents-httpmime Ricardo Wurmus
` (5 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-httpcomponents-httpclient): New variable.
---
gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
1 file changed, 36 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 19642cbfc..ee3a2bd2b 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2113,6 +2113,42 @@ NIO.")))
(description "This package provides the HttpCore benchmarking tool. It is
an Apache AB clone based on HttpCore.")))
+(define-public java-httpcomponents-httpclient
+ (package
+ (name "java-httpcomponents-httpclient")
+ (version "4.5.3")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/httpcomponents/httpclient/"
+ "source/httpcomponents-client-"
+ version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "httpcomponents-httpclient.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "httpclient") #t)))))
+ (inputs
+ `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
+ ("java-commons-codec" ,java-commons-codec)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
+ ("java-mockito" ,java-mockito-1)
+ ("java-junit" ,java-junit)))
+ (home-page "https://hc.apache.org/httpcomponents-client-ga/")
+ (synopsis "HTTP client library for Java")
+ (description "Although the @code{java.net} package provides basic
+functionality for accessing resources via HTTP, it doesn't provide the full
+flexibility or functionality needed by many applications. @code{HttpClient}
+seeks to fill this void by providing an efficient, up-to-date, and
+feature-rich package implementing the client side of the most recent HTTP
+standards and recommendations.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient.
2017-05-06 15:36 ` bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient Ricardo Wurmus
@ 2017-05-11 8:32 ` Roel Janssen
2017-05-15 19:44 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:32 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-httpcomponents-httpclient): New variable.
> ---
> gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
> 1 file changed, 36 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 19642cbfc..ee3a2bd2b 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2113,6 +2113,42 @@ NIO.")))
> (description "This package provides the HttpCore benchmarking tool. It is
> an Apache AB clone based on HttpCore.")))
>
> +(define-public java-httpcomponents-httpclient
> + (package
> + (name "java-httpcomponents-httpclient")
> + (version "4.5.3")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/httpcomponents/httpclient/"
> + "source/httpcomponents-client-"
> + version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "httpcomponents-httpclient.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "httpclient") #t)))))
> + (inputs
> + `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
> + ("java-commons-codec" ,java-commons-codec)
> + ("java-hamcrest-core" ,java-hamcrest-core)
> + ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
> + ("java-mockito" ,java-mockito-1)
> + ("java-junit" ,java-junit)))
> + (home-page "https://hc.apache.org/httpcomponents-client-ga/")
> + (synopsis "HTTP client library for Java")
> + (description "Although the @code{java.net} package provides basic
I thought package names weren't supposed to be @code{}ed.
> +functionality for accessing resources via HTTP, it doesn't provide the full
> +flexibility or functionality needed by many applications. @code{HttpClient}
> +seeks to fill this void by providing an efficient, up-to-date, and
> +feature-rich package implementing the client side of the most recent HTTP
> +standards and recommendations.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
Otherwise, LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient.
2017-05-11 8:32 ` Roel Janssen
@ 2017-05-15 19:44 ` Ricardo Wurmus
2017-05-15 21:26 ` Roel Janssen
0 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-15 19:44 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-httpcomponents-httpclient): New variable.
>> ---
>> gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
>> 1 file changed, 36 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 19642cbfc..ee3a2bd2b 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -2113,6 +2113,42 @@ NIO.")))
>> (description "This package provides the HttpCore benchmarking tool. It is
>> an Apache AB clone based on HttpCore.")))
>>
>> +(define-public java-httpcomponents-httpclient
>> + (package
>> + (name "java-httpcomponents-httpclient")
>> + (version "4.5.3")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "mirror://apache/httpcomponents/httpclient/"
>> + "source/httpcomponents-client-"
>> + version "-src.tar.gz"))
>> + (sha256
>> + (base32
>> + "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:jar-name "httpcomponents-httpclient.jar"
>> + #:phases
>> + (modify-phases %standard-phases
>> + (add-after 'unpack 'chdir
>> + (lambda _ (chdir "httpclient") #t)))))
>> + (inputs
>> + `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
>> + ("java-commons-codec" ,java-commons-codec)
>> + ("java-hamcrest-core" ,java-hamcrest-core)
>> + ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
>> + ("java-mockito" ,java-mockito-1)
>> + ("java-junit" ,java-junit)))
>> + (home-page "https://hc.apache.org/httpcomponents-client-ga/")
>> + (synopsis "HTTP client library for Java")
>> + (description "Although the @code{java.net} package provides basic
>
> I thought package names weren't supposed to be @code{}ed.
This is a Java namespace, not a Guix package. It is only used in import
statements, so it’s code. “java.net” belongs to the standard library,
so it also doesn’t have a separate project name (unlike these Apache
projects).
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient.
2017-05-15 19:44 ` Ricardo Wurmus
@ 2017-05-15 21:26 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-15 21:26 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> Roel Janssen <roel@gnu.org> writes:
>
>> Ricardo Wurmus writes:
>>
>>> * gnu/packages/java.scm (java-httpcomponents-httpclient): New variable.
>>> ---
>>> gnu/packages/java.scm | 36 ++++++++++++++++++++++++++++++++++++
>>> 1 file changed, 36 insertions(+)
>>>
>>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>>> index 19642cbfc..ee3a2bd2b 100644
>>> --- a/gnu/packages/java.scm
>>> +++ b/gnu/packages/java.scm
>>> @@ -2113,6 +2113,42 @@ NIO.")))
>>> (description "This package provides the HttpCore benchmarking tool. It is
>>> an Apache AB clone based on HttpCore.")))
>>>
>>> +(define-public java-httpcomponents-httpclient
>>> + (package
>>> + (name "java-httpcomponents-httpclient")
>>> + (version "4.5.3")
>>> + (source (origin
>>> + (method url-fetch)
>>> + (uri (string-append "mirror://apache/httpcomponents/httpclient/"
>>> + "source/httpcomponents-client-"
>>> + version "-src.tar.gz"))
>>> + (sha256
>>> + (base32
>>> + "1428399s7qy3cim5wc6f3ks4gl9nf9vkjpfmnlap3jflif7g2pj1"))))
>>> + (build-system ant-build-system)
>>> + (arguments
>>> + `(#:jar-name "httpcomponents-httpclient.jar"
>>> + #:phases
>>> + (modify-phases %standard-phases
>>> + (add-after 'unpack 'chdir
>>> + (lambda _ (chdir "httpclient") #t)))))
>>> + (inputs
>>> + `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
>>> + ("java-commons-codec" ,java-commons-codec)
>>> + ("java-hamcrest-core" ,java-hamcrest-core)
>>> + ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
>>> + ("java-mockito" ,java-mockito-1)
>>> + ("java-junit" ,java-junit)))
>>> + (home-page "https://hc.apache.org/httpcomponents-client-ga/")
>>> + (synopsis "HTTP client library for Java")
>>> + (description "Although the @code{java.net} package provides basic
>>
>> I thought package names weren't supposed to be @code{}ed.
>
> This is a Java namespace, not a Guix package. It is only used in import
> statements, so it’s code. “java.net” belongs to the standard library,
> so it also doesn’t have a separate project name (unlike these Apache
> projects).
Maybe the "... @code{java.net} >>>package<<<" should be rephrased to
"... @code{java.net} namespace provided by this package ...".
Either way is fine though, this is nitpicking at its finest.. ;)
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 32/36] gnu: Add java-httpcomponents-httpmime.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (29 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 31/36] gnu: Add java-httpcomponents-httpclient Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:32 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient Ricardo Wurmus
` (4 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-httpcomponents-httpmime): New variable.
---
gnu/packages/java.scm | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index ee3a2bd2b..4bc03e5ca 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2149,6 +2149,21 @@ feature-rich package implementing the client side of the most recent HTTP
standards and recommendations.")
(license license:asl2.0)))
+(define-public java-httpcomponents-httpmime
+ (package (inherit java-httpcomponents-httpclient)
+ (name "java-httpcomponents-httpmime")
+ (arguments
+ `(#:jar-name "httpcomponents-httpmime.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _ (chdir "httpmime") #t)))))
+ (inputs
+ `(("java-httpcomponents-httpclient" ,java-httpcomponents-httpclient)
+ ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
+ ("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 32/36] gnu: Add java-httpcomponents-httpmime.
2017-05-06 15:36 ` bug#26803: [PATCH 32/36] gnu: Add java-httpcomponents-httpmime Ricardo Wurmus
@ 2017-05-11 8:32 ` Roel Janssen
0 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:32 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-httpcomponents-httpmime): New variable.
> ---
> gnu/packages/java.scm | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index ee3a2bd2b..4bc03e5ca 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2149,6 +2149,21 @@ feature-rich package implementing the client side of the most recent HTTP
> standards and recommendations.")
> (license license:asl2.0)))
>
> +(define-public java-httpcomponents-httpmime
> + (package (inherit java-httpcomponents-httpclient)
> + (name "java-httpcomponents-httpmime")
> + (arguments
> + `(#:jar-name "httpcomponents-httpmime.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'chdir
> + (lambda _ (chdir "httpmime") #t)))))
> + (inputs
> + `(("java-httpcomponents-httpclient" ,java-httpcomponents-httpclient)
> + ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
> + ("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (30 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 32/36] gnu: Add java-httpcomponents-httpmime Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:35 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 34/36] gnu: Add java-commons-net Ricardo Wurmus
` (3 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-httpclient): New variable.
---
gnu/packages/java.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 55 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 4bc03e5ca..1639570f9 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2164,6 +2164,61 @@ standards and recommendations.")
("java-junit" ,java-junit)
("java-hamcrest-core" ,java-hamcrest-core)))))
+(define-public java-commons-httpclient
+ (package
+ (name "java-commons-httpclient")
+ (version "3.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/"
+ "httpcomponents/commons-httpclient/source/"
+ "commons-httpclient-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1wlpn3cfy3d4inxy6g7wxcsa8p7sshn6aldk9y4ia3lb879rd97r"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:make-flags
+ (let ((junit (assoc-ref %build-inputs "java-junit"))
+ (codec (assoc-ref %build-inputs "java-commons-codec"))
+ (logging (assoc-ref %build-inputs "java-commons-logging-minimal")))
+ (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
+ (string-append "-Dcommons-codec.jar=" codec
+ "/share/java/commons-codec.jar")
+ (string-append "-Dcommons-logging.jar=" logging
+ "/share/java/commons-logging-minimal.jar")))
+ #:build-target "dist"
+ #:test-target "test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'fix-utf8-problems
+ (lambda _
+ ;; These files contain invalid characters.
+ (with-fluids ((%default-port-encoding "ISO-8859-1"))
+ (substitute* '("src/examples/ClientApp.java"
+ "src/examples/TrivialApp.java"
+ "src/test/org/apache/commons/httpclient/TestHttps.java"
+ "src/test/org/apache/commons/httpclient/TestURIUtil2.java"
+ "src/java/org/apache/commons/httpclient/\
+HttpContentTooLargeException.java")
+ (("Ortwin Gl.") "Ortwin Glue"))
+ (substitute* "src/test/org/apache/commons/httpclient/TestURIUtil2.java"
+ (("\xe4") "")
+ (("%C3%A4") "")))
+ #t))
+ (replace 'install (install-jars "dist")))))
+ (inputs
+ `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
+ ("java-commons-codec" ,java-commons-codec)
+ ("java-junit" ,java-junit)))
+ (home-page "http://hc.apache.org/httpclient-3.x/")
+ (synopsis "Deprecated HTTP client library for Java")
+ (description "The Commons HttpClient project is now end of life, and is
+no longer being developed. It has been replaced by the Apache HttpComponents
+project in its HttpClient and HttpCore modules, which offer better performance
+and more flexibility.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient.
2017-05-06 15:36 ` bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient Ricardo Wurmus
@ 2017-05-11 8:35 ` Roel Janssen
2017-05-15 19:50 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:35 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-httpclient): New variable.
> ---
> gnu/packages/java.scm | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 55 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 4bc03e5ca..1639570f9 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2164,6 +2164,61 @@ standards and recommendations.")
> ("java-junit" ,java-junit)
> ("java-hamcrest-core" ,java-hamcrest-core)))))
>
> +(define-public java-commons-httpclient
> + (package
> + (name "java-commons-httpclient")
> + (version "3.1")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/"
> + "httpcomponents/commons-httpclient/source/"
> + "commons-httpclient-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1wlpn3cfy3d4inxy6g7wxcsa8p7sshn6aldk9y4ia3lb879rd97r"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:make-flags
> + (let ((junit (assoc-ref %build-inputs "java-junit"))
> + (codec (assoc-ref %build-inputs "java-commons-codec"))
> + (logging (assoc-ref %build-inputs "java-commons-logging-minimal")))
> + (list (string-append "-Djunit.jar=" junit "/share/java/junit.jar")
> + (string-append "-Dcommons-codec.jar=" codec
> + "/share/java/commons-codec.jar")
> + (string-append "-Dcommons-logging.jar=" logging
> + "/share/java/commons-logging-minimal.jar")))
> + #:build-target "dist"
> + #:test-target "test"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'fix-utf8-problems
> + (lambda _
> + ;; These files contain invalid characters.
> + (with-fluids ((%default-port-encoding "ISO-8859-1"))
> + (substitute* '("src/examples/ClientApp.java"
> + "src/examples/TrivialApp.java"
> + "src/test/org/apache/commons/httpclient/TestHttps.java"
> + "src/test/org/apache/commons/httpclient/TestURIUtil2.java"
> + "src/java/org/apache/commons/httpclient/\
> +HttpContentTooLargeException.java")
> + (("Ortwin Gl.") "Ortwin Glue"))
> + (substitute* "src/test/org/apache/commons/httpclient/TestURIUtil2.java"
> + (("\xe4") "")
> + (("%C3%A4") "")))
> + #t))
> + (replace 'install (install-jars "dist")))))
> + (inputs
> + `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
> + ("java-commons-codec" ,java-commons-codec)
> + ("java-junit" ,java-junit)))
> + (home-page "http://hc.apache.org/httpclient-3.x/")
> + (synopsis "Deprecated HTTP client library for Java")
Now that sound wonderful.. ;)
> + (description "The Commons HttpClient project is now end of life, and is
> +no longer being developed. It has been replaced by the Apache HttpComponents
> +project in its HttpClient and HttpCore modules, which offer better performance
> +and more flexibility.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
I guess we need it for some dependency. Is it possible to use the
java-httpcomponents-httpclient for these?
If we really need this package, then the recipe looks good to me, but I
think it'be better to not need an already deprecated version of
something that does networking stuff.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient.
2017-05-11 8:35 ` Roel Janssen
@ 2017-05-15 19:50 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-15 19:50 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-commons-httpclient): New variable.
>> ---
[…]
> I guess we need it for some dependency. Is it possible to use the
> java-httpcomponents-httpclient for these?
Unfortunately, java-httpcomponents-httpclient has a completely different
API, so it cannot be used as a drop-in replacement.
> If we really need this package, then the recipe looks good to me, but I
> think it'be better to not need an already deprecated version of
> something that does networking stuff.
I agree. My current patch sets do not include packages that need it, so
I’ll drop it.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 34/36] gnu: Add java-commons-net.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (31 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 33/36] gnu: Add java-commons-httpclient Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:40 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 35/36] gnu: Add java-jsch Ricardo Wurmus
` (2 subsequent siblings)
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-net): New variable.
---
gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 1639570f9..287a7ae69 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2219,6 +2219,34 @@ project in its HttpClient and HttpCore modules, which offer better performance
and more flexibility.")
(license license:asl2.0)))
+(define-public java-commons-net
+ (package
+ (name "java-commons-net")
+ (version "3.6")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/net/source/"
+ "commons-net-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "0n0cmnddk9qdqhjvka8pc6hd9mn2qi3166f1s6xk32h7rfy1adxr"))))
+ (build-system ant-build-system)
+ (arguments
+ `(;; FIXME: MainTest.java tries to read "examples.properties" (which
+ ;; should be "resources/examples/examples.properties"), but gets "null"
+ ;; instead.
+ #:tests? #f
+ #:jar-name "commons-net.jar"))
+ (native-inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)))
+ (home-page "http://commons.apache.org/net/")
+ (synopsis "Client library for many basic Internet protocols")
+ (description "The Apache Commons Net library implements the client side of
+many basic Internet protocols. The purpose of the library is to provide
+fundamental protocol access, not higher-level abstractions.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 34/36] gnu: Add java-commons-net.
2017-05-06 15:36 ` bug#26803: [PATCH 34/36] gnu: Add java-commons-net Ricardo Wurmus
@ 2017-05-11 8:40 ` Roel Janssen
2017-05-15 19:53 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:40 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-net): New variable.
> ---
> gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
> 1 file changed, 28 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 1639570f9..287a7ae69 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2219,6 +2219,34 @@ project in its HttpClient and HttpCore modules, which offer better performance
> and more flexibility.")
> (license license:asl2.0)))
>
> +(define-public java-commons-net
> + (package
> + (name "java-commons-net")
> + (version "3.6")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/net/source/"
> + "commons-net-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "0n0cmnddk9qdqhjvka8pc6hd9mn2qi3166f1s6xk32h7rfy1adxr"))))
> + (build-system ant-build-system)
> + (arguments
> + `(;; FIXME: MainTest.java tries to read "examples.properties" (which
> + ;; should be "resources/examples/examples.properties"), but gets "null"
> + ;; instead.
This sounds fixable in a substitute construct. But maybe I am wrong
about it. Would you like to try that first?
> + #:tests? #f
> + #:jar-name "commons-net.jar"))
> + (native-inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)))
> + (home-page "http://commons.apache.org/net/")
> + (synopsis "Client library for many basic Internet protocols")
> + (description "The Apache Commons Net library implements the client side of
> +many basic Internet protocols. The purpose of the library is to provide
> +fundamental protocol access, not higher-level abstractions.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
Otherwise, LGTM.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 34/36] gnu: Add java-commons-net.
2017-05-11 8:40 ` Roel Janssen
@ 2017-05-15 19:53 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-15 19:53 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-commons-net): New variable.
>> ---
[…]
>> + (arguments
>> + `(;; FIXME: MainTest.java tries to read "examples.properties" (which
>> + ;; should be "resources/examples/examples.properties"), but gets "null"
>> + ;; instead.
>
> This sounds fixable in a substitute construct. But maybe I am wrong
> about it. Would you like to try that first?
I tried it, but it’s more complicated than just a substitution. It
could be a problem of the ant-build-system’s default “build.xml”, which
might not include do the right thing for resources. I don’t know yet
what the right thing would be, and it’s just a guess.
Although I don’t like the ambiguity, I’d rather investigate this later
and keep the FIXME for now. We’ll be able to detect problems with the
ant-build-system only once we have enough Java packages to actually
build big applications.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 35/36] gnu: Add java-jsch.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (32 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 34/36] gnu: Add java-commons-net Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:41 ` Roel Janssen
2017-05-06 15:36 ` bug#26803: [PATCH 36/36] gnu: Add java-commons-compress Ricardo Wurmus
2017-05-06 20:22 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Roel Janssen
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-jsch): New variable.
---
gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 287a7ae69..8ecd5bbfc 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2247,6 +2247,34 @@ many basic Internet protocols. The purpose of the library is to provide
fundamental protocol access, not higher-level abstractions.")
(license license:asl2.0)))
+(define-public java-jsch
+ (package
+ (name "java-jsch")
+ (version "0.1.54")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://sourceforge/jsch/jsch/"
+ version "/jsch-" version ".zip"))
+ (sha256
+ (base32
+ "029rdddyq1mh3ghryh3ki99kba1xkf1d1swjv2vi6lk6zzjy2wdb"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:build-target "dist"
+ #:tests? #f ; no tests included
+ #:phases
+ (modify-phases %standard-phases
+ (replace 'install (install-jars "dist")))))
+ (native-inputs
+ `(("unzip" ,unzip)))
+ (home-page "http://www.jcraft.com/jsch/")
+ (synopsis "Pure Java implementation of SSH2")
+ (description "JSch is a pure Java implementation of SSH2. JSch allows you
+to connect to an SSH server and use port forwarding, X11 forwarding, file
+transfer, etc., and you can integrate its functionality into your own Java
+programs.")
+ (license license:bsd-3)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 35/36] gnu: Add java-jsch.
2017-05-06 15:36 ` bug#26803: [PATCH 35/36] gnu: Add java-jsch Ricardo Wurmus
@ 2017-05-11 8:41 ` Roel Janssen
2017-05-15 19:54 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:41 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-jsch): New variable.
> ---
> gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
> 1 file changed, 28 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 287a7ae69..8ecd5bbfc 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2247,6 +2247,34 @@ many basic Internet protocols. The purpose of the library is to provide
> fundamental protocol access, not higher-level abstractions.")
> (license license:asl2.0)))
>
> +(define-public java-jsch
> + (package
> + (name "java-jsch")
> + (version "0.1.54")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://sourceforge/jsch/jsch/"
> + version "/jsch-" version ".zip"))
> + (sha256
> + (base32
> + "029rdddyq1mh3ghryh3ki99kba1xkf1d1swjv2vi6lk6zzjy2wdb"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:build-target "dist"
> + #:tests? #f ; no tests included
> + #:phases
> + (modify-phases %standard-phases
> + (replace 'install (install-jars "dist")))))
> + (native-inputs
> + `(("unzip" ,unzip)))
> + (home-page "http://www.jcraft.com/jsch/")
> + (synopsis "Pure Java implementation of SSH2")
> + (description "JSch is a pure Java implementation of SSH2. JSch allows you
> +to connect to an SSH server and use port forwarding, X11 forwarding, file
> +transfer, etc., and you can integrate its functionality into your own Java
> +programs.")
> + (license license:bsd-3)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM! And this looks like an interesting library.
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 35/36] gnu: Add java-jsch.
2017-05-11 8:41 ` Roel Janssen
@ 2017-05-15 19:54 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-15 19:54 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-jsch): New variable.
>> ---
>> gnu/packages/java.scm | 28 ++++++++++++++++++++++++++++
>> 1 file changed, 28 insertions(+)
>>
>> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
>> index 287a7ae69..8ecd5bbfc 100644
>> --- a/gnu/packages/java.scm
>> +++ b/gnu/packages/java.scm
>> @@ -2247,6 +2247,34 @@ many basic Internet protocols. The purpose of the library is to provide
>> fundamental protocol access, not higher-level abstractions.")
>> (license license:asl2.0)))
>>
>> +(define-public java-jsch
>> + (package
>> + (name "java-jsch")
>> + (version "0.1.54")
>> + (source (origin
>> + (method url-fetch)
>> + (uri (string-append "mirror://sourceforge/jsch/jsch/"
>> + version "/jsch-" version ".zip"))
>> + (sha256
>> + (base32
>> + "029rdddyq1mh3ghryh3ki99kba1xkf1d1swjv2vi6lk6zzjy2wdb"))))
>> + (build-system ant-build-system)
>> + (arguments
>> + `(#:build-target "dist"
>> + #:tests? #f ; no tests included
>> + #:phases
>> + (modify-phases %standard-phases
>> + (replace 'install (install-jars "dist")))))
>> + (native-inputs
>> + `(("unzip" ,unzip)))
>> + (home-page "http://www.jcraft.com/jsch/")
>> + (synopsis "Pure Java implementation of SSH2")
>> + (description "JSch is a pure Java implementation of SSH2. JSch allows you
>> +to connect to an SSH server and use port forwarding, X11 forwarding, file
>> +transfer, etc., and you can integrate its functionality into your own Java
>> +programs.")
>> + (license license:bsd-3)))
>> +
>> (define-public java-commons-cli
>> (package
>> (name "java-commons-cli")
>
> LGTM! And this looks like an interesting library.
Yes, but it cannot only be used with Java… :)
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 36/36] gnu: Add java-commons-compress.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (33 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 35/36] gnu: Add java-jsch Ricardo Wurmus
@ 2017-05-06 15:36 ` Ricardo Wurmus
2017-05-11 8:53 ` Roel Janssen
2017-05-06 20:22 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Roel Janssen
35 siblings, 1 reply; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-06 15:36 UTC (permalink / raw)
To: 26803; +Cc: Ricardo Wurmus
* gnu/packages/java.scm (java-commons-compress): New variable.
---
gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
index 8ecd5bbfc..35e1c315e 100644
--- a/gnu/packages/java.scm
+++ b/gnu/packages/java.scm
@@ -2275,6 +2275,50 @@ transfer, etc., and you can integrate its functionality into your own Java
programs.")
(license license:bsd-3)))
+(define-public java-commons-compress
+ (package
+ (name "java-commons-compress")
+ (version "1.13")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "mirror://apache/commons/compress/source/"
+ "commons-compress-" version "-src.tar.gz"))
+ (sha256
+ (base32
+ "1vjqvavrn0babffn1kciz6v52ibwq2vwhzlb95hazis3lgllnxc8"))))
+ (build-system ant-build-system)
+ (arguments
+ `(#:jar-name "commons-compress.jar"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'delete-bad-tests
+ (lambda _
+ (with-directory-excursion "src/test/java/org/apache/commons/compress/"
+ ;; FIXME: These tests really should not fail. Maybe they are
+ ;; indicative of problems with our Java packaging work.
+
+ ;; This test fails with a null pointer exception.
+ (delete-file "archivers/sevenz/SevenZOutputFileTest.java")
+ ;; This test fails to open test resources.
+ (delete-file "archivers/zip/ExplodeSupportTest.java")
+
+ ;; FIXME: This test adds a dependency on powermock, which is hard to
+ ;; package at this point.
+ ;; https://github.com/powermock/powermock
+ (delete-file "archivers/sevenz/SevenZNativeHeapTest.java"))
+ #t)))))
+ (inputs
+ `(("java-junit" ,java-junit)
+ ("java-hamcrest-core" ,java-hamcrest-core)
+ ("java-mockito" ,java-mockito-1)
+ ("java-xz" ,java-xz)))
+ (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
+working with compressed files such as ar, cpio, Unix dump, tar, zip, gzip, XZ,
+Pack200, bzip2, 7z, arj, lzma, snappy, DEFLATE, lz4 and Z files.")
+ (license license:asl2.0)))
+
(define-public java-commons-cli
(package
(name "java-commons-cli")
--
2.12.2
^ permalink raw reply related [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 36/36] gnu: Add java-commons-compress.
2017-05-06 15:36 ` bug#26803: [PATCH 36/36] gnu: Add java-commons-compress Ricardo Wurmus
@ 2017-05-11 8:53 ` Roel Janssen
2017-05-15 19:56 ` Ricardo Wurmus
0 siblings, 1 reply; 103+ messages in thread
From: Roel Janssen @ 2017-05-11 8:53 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: 26803
Ricardo Wurmus writes:
> * gnu/packages/java.scm (java-commons-compress): New variable.
> ---
> gnu/packages/java.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 44 insertions(+)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index 8ecd5bbfc..35e1c315e 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -2275,6 +2275,50 @@ transfer, etc., and you can integrate its functionality into your own Java
> programs.")
> (license license:bsd-3)))
>
> +(define-public java-commons-compress
> + (package
> + (name "java-commons-compress")
> + (version "1.13")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append "mirror://apache/commons/compress/source/"
> + "commons-compress-" version "-src.tar.gz"))
> + (sha256
> + (base32
> + "1vjqvavrn0babffn1kciz6v52ibwq2vwhzlb95hazis3lgllnxc8"))))
> + (build-system ant-build-system)
> + (arguments
> + `(#:jar-name "commons-compress.jar"
> + #:phases
> + (modify-phases %standard-phases
> + (add-after 'unpack 'delete-bad-tests
> + (lambda _
> + (with-directory-excursion "src/test/java/org/apache/commons/compress/"
> + ;; FIXME: These tests really should not fail. Maybe they are
> + ;; indicative of problems with our Java packaging work.
We should definitely take note of this.
> + ;; This test fails with a null pointer exception.
> + (delete-file "archivers/sevenz/SevenZOutputFileTest.java")
> +
> + ;; This test fails to open test resources.
> + (delete-file "archivers/zip/ExplodeSupportTest.java")
> +
> + ;; FIXME: This test adds a dependency on powermock, which is hard to
> + ;; package at this point.
> + ;; https://github.com/powermock/powermock
> + (delete-file "archivers/sevenz/SevenZNativeHeapTest.java"))
> + #t)))))
> + (inputs
> + `(("java-junit" ,java-junit)
> + ("java-hamcrest-core" ,java-hamcrest-core)
> + ("java-mockito" ,java-mockito-1)
> + ("java-xz" ,java-xz)))
> + (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
> +working with compressed files such as ar, cpio, Unix dump, tar, zip, gzip, XZ,
> +Pack200, bzip2, 7z, arj, lzma, snappy, DEFLATE, lz4 and Z files.")
> + (license license:asl2.0)))
> +
> (define-public java-commons-cli
> (package
> (name "java-commons-cli")
LGTM.
I think this concludes the first batch of Java packages.
Thanks a lot for this very important work!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 36/36] gnu: Add java-commons-compress.
2017-05-11 8:53 ` Roel Janssen
@ 2017-05-15 19:56 ` Ricardo Wurmus
0 siblings, 0 replies; 103+ messages in thread
From: Ricardo Wurmus @ 2017-05-15 19:56 UTC (permalink / raw)
To: Roel Janssen; +Cc: 26803-done
Roel Janssen <roel@gnu.org> writes:
> Ricardo Wurmus writes:
>
>> * gnu/packages/java.scm (java-commons-compress): New variable.
>> ---
[…]
>> + (arguments
>> + `(#:jar-name "commons-compress.jar"
>> + #:phases
>> + (modify-phases %standard-phases
>> + (add-after 'unpack 'delete-bad-tests
>> + (lambda _
>> + (with-directory-excursion "src/test/java/org/apache/commons/compress/"
>> + ;; FIXME: These tests really should not fail. Maybe they are
>> + ;; indicative of problems with our Java packaging work.
>
> We should definitely take note of this.
Indeed. This really looks like a problem with the ant-build-system as I
wrote in another email.
> I think this concludes the first batch of Java packages.
>
> Thanks a lot for this very important work!
Yay! Thank you so much for taking the time to review this mess!
I’m closing this bug and will push the remaining packages in a moment.
--
Ricardo
GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC
https://elephly.net
^ permalink raw reply [flat|nested] 103+ messages in thread
* bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory.
2017-05-06 15:35 ` bug#26803: [PATCH 01/36] ant-build-system: Allow specifying source directory Ricardo Wurmus
` (34 preceding siblings ...)
2017-05-06 15:36 ` bug#26803: [PATCH 36/36] gnu: Add java-commons-compress Ricardo Wurmus
@ 2017-05-06 20:22 ` Roel Janssen
35 siblings, 0 replies; 103+ messages in thread
From: Roel Janssen @ 2017-05-06 20:22 UTC (permalink / raw)
To: Ricardo Wurmus; +Cc: Hartmut Goebel, 26803
Ricardo Wurmus writes:
> From: Hartmut Goebel <h.goebel@crazy-compilers.com>
>
> * guix/build-system/ant.scm (ant-build),
> guix/build/ant-build-system.scm (default-build.xml): Add parameter
> source-dir.
> * guix/build/ant-build-system.scm (configure): Pass source-dir on to
> default-build.xml.
> * doc/guix.texi (Build Systems): Document it.
>
> Co-authored-by: Ricardo Wurmus <rekado@elephly.net>
> ---
> doc/guix.texi | 3 ++-
> guix/build-system/ant.scm | 2 ++
> guix/build/ant-build-system.scm | 10 ++++++----
> 3 files changed, 10 insertions(+), 5 deletions(-)
>
> diff --git a/doc/guix.texi b/doc/guix.texi
> index 4446909ed..d2699c048 100644
> --- a/doc/guix.texi
> +++ b/doc/guix.texi
> @@ -3325,7 +3325,8 @@ parameters, respectively.
> When the original package does not provide a suitable Ant build file,
> the parameter @code{#:jar-name} can be used to generate a minimal Ant
> build file @file{build.xml} with tasks to build the specified jar
> -archive.
> +archive. In this case the parameter @code{#:source-dir} can be used to
> +specify the source sub-directory, defaulting to ``src''.
>
> The parameter @code{#:build-target} can be used to specify the Ant task
> that should be run during the @code{build} phase. By default the
> diff --git a/guix/build-system/ant.scm b/guix/build-system/ant.scm
> index 550f92bc7..a309a0c86 100644
> --- a/guix/build-system/ant.scm
> +++ b/guix/build-system/ant.scm
> @@ -98,6 +98,7 @@
> (make-flags ''())
> (build-target "jar")
> (jar-name #f)
> + (source-dir "src")
> (phases '(@ (guix build ant-build-system)
> %standard-phases))
> (outputs '("out"))
> @@ -126,6 +127,7 @@
> #:test-target ,test-target
> #:build-target ,build-target
> #:jar-name ,jar-name
> + #:source-dir ,source-dir
> #:phases ,phases
> #:outputs %outputs
> #:search-paths ',(map search-path-specification->sexp
> diff --git a/guix/build/ant-build-system.scm b/guix/build/ant-build-system.scm
> index 00a4a46d8..8ec7a9486 100644
> --- a/guix/build/ant-build-system.scm
> +++ b/guix/build/ant-build-system.scm
> @@ -35,7 +35,8 @@
> ;;
> ;; Code:
>
> -(define (default-build.xml jar-name prefix)
> +(define* (default-build.xml jar-name prefix #:optional
> + (source-dir "."))
> "Create a simple build.xml with standard targets for Ant."
> (call-with-output-file "build.xml"
> (lambda (port)
> @@ -58,7 +59,7 @@
> (target (@ (name "compile"))
> (mkdir (@ (dir "${classes.dir}")))
> (javac (@ (includeantruntime "false")
> - (srcdir "src")
> + (srcdir ,source-dir)
> (destdir "${classes.dir}")
> (classpath (@ (refid "classpath"))))))
>
> @@ -98,11 +99,12 @@ to the default GNU unpack strategy."
> ((assq-ref gnu:%standard-phases 'unpack) #:source source)))
>
> (define* (configure #:key inputs outputs (jar-name #f)
> - #:allow-other-keys)
> + (source-dir "src") #:allow-other-keys)
> (when jar-name
> (default-build.xml jar-name
> (string-append (assoc-ref outputs "out")
> - "/share/java")))
> + "/share/java")
> + source-dir))
> (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
> (setenv "CLASSPATH" (generate-classpath inputs)))
LGTM!
Kind regards,
Roel Janssen
^ permalink raw reply [flat|nested] 103+ messages in thread