[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#31333] [PATCH 10/22] gnu: Add groovy-swing.
From: |
Julien Lepiller |
Subject: |
[bug#31333] [PATCH 10/22] gnu: Add groovy-swing. |
Date: |
Tue, 1 May 2018 17:44:37 +0200 |
* gnu/packages/groovy.scm (groovy-swing): New variable.
---
gnu/packages/groovy.scm | 54 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 54 insertions(+)
diff --git a/gnu/packages/groovy.scm b/gnu/packages/groovy.scm
index 232137d29..dcca41eae 100644
--- a/gnu/packages/groovy.scm
+++ b/gnu/packages/groovy.scm
@@ -495,3 +495,57 @@ similar to javadoc.")))
(synopsis "Groovy BSF engine")
(description "This package defines the BSF engine for using Groovy inside
any @dfn{Bean Scripting Framework} (BSF) application.")))
+
+(define groovy-swing
+ (package
+ (inherit groovy-bootstrap)
+ (name "groovy-swing")
+ (arguments
+ `(#:jar-name "groovy-swing.jar"
+ #:jdk ,icedtea-8
+ ;; FIXME: tests are not run
+ #:test-dir "src/test"
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'configure 'chdir
+ (lambda _
+ (chdir "subprojects/groovy-swing")))
+ (replace 'build
+ (lambda _
+ (mkdir-p "build/classes")
+ (mkdir-p "build/jar")
+ (and
+ (zero? (apply system* "java" "-cp" (getenv "CLASSPATH")
+ "org.codehaus.groovy.tools.FileSystemCompiler"
+ "-d" "build/classes"
+ "-j"; joint compilation
+ (find-files "src/main"
+ ".*\\.(groovy|java)$")))
+ (zero? (system* "jar" "-cf" "build/jar/groovy-swing.jar"
+ "-C" "build/classes" ".")))))
+ (replace 'check
+ (lambda _
+ (mkdir-p "build/test-classes")
+ (substitute*
"src/test/groovy/groovy/util/GroovySwingTestCase.groovy"
+ (("HeadlessTestSupport.headless") "isHeadless()"))
+ (substitute* "build.xml"
+ (("depends=\"compile-tests\"") "depends=\"\"")
+ (("}/java") "}/groovy"))
+ (and
+ (zero? (apply system* "java" "-cp"
+ (string-append (getenv "CLASSPATH")
":build/classes")
+ "org.codehaus.groovy.tools.FileSystemCompiler"
+ "-d" "build/test-classes"
+ "-j"
+ (find-files "src/test"
+ ".*\\.(groovy|java)$")))
+ (zero? (system* "ant" "check"))))))))
+ (native-inputs
+ `(("groovy-bootstrap" ,groovy-bootstrap)
+ ("groovy-test" ,groovy-test)
+ ("groovy-tests-bootstrap" ,groovy-tests-bootstrap)
+ ("java-commons-logging-minimal" ,java-commons-logging-minimal)
+ ,@(package-native-inputs groovy-java-bootstrap)))
+ (synopsis "Groovy graphical library")
+ (description "This package contains the groovy bindings to Java Swing, a
+library used to build graphical interfaces.")))
--
2.17.0
- [bug#31333] [PATCH] Add groovy, Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 01/22] gnu: Add groovy-java-bootstrap., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 09/22] gnu: Add groovy-bsf., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 10/22] gnu: Add groovy-swing.,
Julien Lepiller <=
- [bug#31333] [PATCH 12/22] gnu: Add groovy-docgenerator., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 07/22] gnu: Add groovy-groovydoc., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 13/22] gnu: Add groovy-groovysh., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 14/22] gnu: Add groovy-jmx., Julien Lepiller, 2018/05/01
- [bug#31333] [PATCH 15/22] gnu: Add groovy-json., Julien Lepiller, 2018/05/01