gnu: java-commons-jcs: Update to 3.1.

* gnu/packages/java.scm (java-commons-jcs): Update to 3.1.
(josm)[arguments]: Remove now unneeded phase.
This commit is contained in:
Julien Lepiller 2022-10-15 23:32:07 +02:00
parent 82d9fcd9b7
commit 10c82778ab
No known key found for this signature in database
GPG key ID: 53D457B2D636EE82
2 changed files with 11 additions and 24 deletions

View file

@ -1756,15 +1756,6 @@ (define-public josm
"<date>1970-01-01 00:00:00 +0000</date>" "<date>1970-01-01 00:00:00 +0000</date>"
"</commit></entry></info>")))) "</commit></entry></info>"))))
#t)) #t))
(add-before 'build 'fix-jcs
(lambda _
;; This version of JOSM uses an unreleased version of commons-jcs,
;; which has renamed its classes to another namespace. Rename them
;; back so they can be used with our version of jcs.
(substitute* (find-files "." ".*.java$")
(("jcs3") "jcs")
(("ICache.NAME_COMPONENT_DELIMITER") "\":\""))
#t))
(add-before 'build 'fix-classpath (add-before 'build 'fix-classpath
(lambda* (#:key inputs #:allow-other-keys) (lambda* (#:key inputs #:allow-other-keys)
(setenv "CLASSPATH" (setenv "CLASSPATH"

View file

@ -6369,14 +6369,14 @@ (define-public java-commons-dbcp
(define-public java-commons-jcs (define-public java-commons-jcs
(package (package
(name "java-commons-jcs") (name "java-commons-jcs")
(version "2.2.1") (version "3.1")
(source (origin (source (origin
(method url-fetch) (method url-fetch)
(uri (string-append "mirror://apache/commons/jcs/source/" (uri (string-append "mirror://apache/commons/jcs/source/"
"commons-jcs-dist-" version "-src.tar.gz")) "commons-jcs3-dist-" version "-src.tar.gz"))
(sha256 (sha256
(base32 (base32
"0syhq2npjbrl0azqfjm0gvash1qd5qjy4qmysxcrqjsk0nf9fa1q")))) "0y1lm1xnsj99bf7y9mkvbzqfy8dr7ac8zcbkpsjgzb9vhabfsbac"))))
(build-system ant-build-system) (build-system ant-build-system)
(arguments (arguments
`(#:jar-name "commons-jcs.jar" `(#:jar-name "commons-jcs.jar"
@ -6385,20 +6385,16 @@ (define-public java-commons-jcs
#:tests? #f; requires hsqldb #:tests? #f; requires hsqldb
#:phases #:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(add-before 'build 'prepare (add-before 'build 'copy-resources
(lambda _ (lambda _
(with-directory-excursion (copy-recursively "commons-jcs-core/src/main/resources"
"commons-jcs-core/src/main/java/org/apache/commons/jcs" "build/classes"))))))
(substitute*
"auxiliary/disk/jdbc/dsfactory/SharedPoolDataSourceFactory.java"
(("commons.dbcp") "commons.dbcp2")
((".*\\.setMaxActive.*") ""))
;;; Remove dependency on velocity-tools
(delete-file "admin/servlet/JCSAdminServlet.java"))
#t)))))
(propagated-inputs (propagated-inputs
(list java-classpathx-servletapi java-commons-logging-minimal (list java-classpathx-servletapi
java-commons-httpclient java-commons-dbcp)) java-commons-dbcp
java-httpcomponents-httpclient
java-httpcomponents-httpcore
java-log4j-api))
(native-inputs (native-inputs
(list java-junit)) (list java-junit))
(home-page "https://commons.apache.org/proper/commons-jcs/") (home-page "https://commons.apache.org/proper/commons-jcs/")