aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/groovy.scm
diff options
context:
space:
mode:
authorJulien Lepiller <julien@lepiller.eu>2018-03-16 14:37:54 +0100
committerJulien Lepiller <julien@lepiller.eu>2018-05-09 13:37:07 +0200
commit4ab3b0c544765363d7435712261b0022598c163e (patch)
treefcc249c46d4b828d0fb76f63a4beb35f318ac012 /gnu/packages/groovy.scm
parent3537fb61fc8a27137bb38329867ef6fa845ecdd3 (diff)
downloadpatches-4ab3b0c544765363d7435712261b0022598c163e.tar
patches-4ab3b0c544765363d7435712261b0022598c163e.tar.gz
gnu: Add groovy-nio.
* gnu/packages/groovy.scm (groovy-nio): New variable.
Diffstat (limited to 'gnu/packages/groovy.scm')
-rw-r--r--gnu/packages/groovy.scm35
1 files changed, 35 insertions, 0 deletions
diff --git a/gnu/packages/groovy.scm b/gnu/packages/groovy.scm
index c74fa11c97..ecaa9429ee 100644
--- a/gnu/packages/groovy.scm
+++ b/gnu/packages/groovy.scm
@@ -844,3 +844,38 @@ management and monitoring of JVM-based solutions.")))
(synopsis "Groovy's own JSR223 implementation")
(description "This package contains Groovy's own JSR223 implementation. This
module is used for interaction between Groovy and Java code.")))
+
+(define groovy-nio
+ (package
+ (inherit groovy-bootstrap)
+ (name "groovy-nio")
+ (arguments
+ `(#:jar-name "groovy-nio.jar"
+ #:test-dir "src/test"
+ #:jdk ,icedtea-8
+ #:tests? #f; Requires spock-framework
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'configure 'chdir
+ (lambda _
+ (chdir "subprojects/groovy-nio")
+ #t))
+ (replace 'build
+ (lambda _
+ (mkdir-p "build/classes")
+ (mkdir-p "build/jar")
+ (apply invoke "java" "-cp" (getenv "CLASSPATH")
+ "org.codehaus.groovy.tools.FileSystemCompiler"
+ "-d" "build/classes" "-j"; joint compilation
+ (find-files "src/main" ".*\\.(groovy|java)$"))
+ (invoke "jar" "-cf" "build/jar/groovy-nio.jar"
+ "-C" "build/classes" ".")
+ #t)))))
+ (native-inputs
+ `(("groovy-bootstrap" ,groovy-bootstrap)
+ ("groovy-test" ,groovy-test)
+ ("groovy-tests-bootstrap" ,groovy-tests-bootstrap)
+ ,@(package-native-inputs java-groovy-bootstrap)))
+ (synopsis "Groovy input-output library")
+ (description "This package implements an input/output library that extends
+the functionality of the common library of Java.")))