gnu: classpath-jamvm-wrappers: Use G-Expression.

* gnu/packages/java.scm (classpath-jamvm-wrappers)[arguments]: Use a gexp to
remove references to %build-inputs and %outputs.
[native-inputs]: Replace bash with bash-minimal; use label-less style.
This commit is contained in:
Ricardo Wurmus 2021-12-18 17:29:11 +01:00
parent de48029bb3
commit 380c52e901
No known key found for this signature in database
GPG key ID: 197A5888235FACAC

View file

@ -622,20 +622,20 @@ (define classpath-jamvm-wrappers
(source #f) (source #f)
(build-system trivial-build-system) (build-system trivial-build-system)
(arguments (arguments
`(#:modules ((guix build utils)) (list
#:modules '((guix build utils))
#:builder #:builder
(begin #~(begin
(use-modules (guix build utils)) (use-modules (guix build utils))
(let* ((bash (assoc-ref %build-inputs "bash")) (let ((bash #$(this-package-native-input "bash-minimal"))
(jamvm (assoc-ref %build-inputs "jamvm")) (jamvm #$(this-package-native-input "jamvm"))
(classpath (assoc-ref %build-inputs "classpath")) (classpath #$(this-package-native-input "classpath"))
(bin (string-append (assoc-ref %outputs "out") (bin (string-append #$output "/bin/")))
"/bin/")))
(mkdir-p bin) (mkdir-p bin)
(for-each (lambda (tool) (for-each (lambda (tool)
(with-output-to-file (string-append bin tool) (with-output-to-file (string-append bin tool)
(lambda _ (lambda _
,@(if (string-prefix? "armhf" (or (%current-system) #$@(if (string-prefix? "armhf" (or (%current-system)
(%current-target-system))) (%current-target-system)))
`((format #t "#!~a/bin/sh `((format #t "#!~a/bin/sh
~a/bin/jamvm -Xnocompact -classpath ~a/share/classpath/tools.zip \ ~a/bin/jamvm -Xnocompact -classpath ~a/share/classpath/tools.zip \
@ -655,12 +655,9 @@ (define classpath-jamvm-wrappers
"rmid" "rmid"
"orbd" "orbd"
"rmiregistry" "rmiregistry"
"native2ascii")) "native2ascii"))))))
#t))))
(native-inputs (native-inputs
`(("bash" ,bash) (list bash-minimal jamvm-1-bootstrap classpath-0.99))
("jamvm" ,jamvm-1-bootstrap)
("classpath" ,classpath-0.99)))
(inputs '()) (inputs '())
(synopsis "Executables from GNU Classpath") (synopsis "Executables from GNU Classpath")
(description "This package provides wrappers around the tools provided by (description "This package provides wrappers around the tools provided by