more java packages

Julien LepillerTue Oct 23 23:04:23+0200 2018

77f4414

more java packages

more/packages/java.scm

5252
  #:use-module (more packages maven)
5353
  #:use-module (more packages python))
5454
55+
(define-public java-httpcomponents-httpasyncclient
56+
  (package
57+
    (name "java-httpcomponents-httpasyncclient")
58+
    (version "4.1.4")
59+
    (source (origin
60+
              (method url-fetch)
61+
              (uri (string-append "mirror://apache/httpcomponents/httpasyncclient/"
62+
                                  "source/httpcomponents-asyncclient-"
63+
                                  version "-src.tar.gz"))
64+
              (sha256
65+
               (base32
66+
                "0xfc20zrwdym6g00sz5y38mdmcn4y2jikkmfgqyh9zm4nkyj7ci5"))))
67+
    (build-system ant-build-system)
68+
    (arguments
69+
     `(#:jar-name "httpcomponents-httpasyncclient.jar"
70+
       #:phases
71+
       (modify-phases %standard-phases
72+
         (add-after 'unpack 'chdir
73+
           (lambda _ (chdir "httpasyncclient") #t)))))
74+
    (inputs
75+
     `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
76+
       ("java-commons-codec" ,java-commons-codec)
77+
       ("java-commons-io" ,java-commons-io)
78+
       ("java-hamcrest-core" ,java-hamcrest-core)
79+
       ("java-httpcomponents-httpclient" ,java-httpcomponents-httpclient)
80+
       ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
81+
       ("java-httpcomponents-httpcore-nio" ,java-httpcomponents-httpcore-nio)
82+
       ("java-mockito" ,java-mockito-1)
83+
       ("java-junit" ,java-junit)))
84+
    (home-page "https://hc.apache.org/httpcomponents-asyncclient-ga/")
85+
    (synopsis "HTTP client library for Java")
86+
    (description "Although the @code{java.net} package provides basic
87+
functionality for accessing resources via HTTP, it doesn't provide the full
88+
flexibility or functionality needed by many applications.  @code{HttpAsyncClient}
89+
seeks to fill this void by providing an efficient, up-to-date, and
90+
feature-rich package implementing the client side of the most recent HTTP
91+
standards and recommendations.")
92+
    (license license:asl2.0)))
93+
5594
(define-public java-fastutil
5695
  (package
5796
    (name "java-fastutil")

27622801
             ;; Needed because tests look for data in src/... directly.
27632802
             (chdir "spring-core")
27642803
             #t))
2804+
         (add-before 'configure 'unbundle-asm
2805+
           (lambda _
2806+
             (with-directory-excursion "src/main/java/org/springframework/asm"
2807+
               (for-each delete-file
2808+
                         (filter (lambda (file) (not (string=? file "./SpringAsmInfo.java")))
2809+
                           (find-files "." ".*.java")))
2810+
               (substitute* "SpringAsmInfo.java"
2811+
                 (("package org.springframework.asm;")
2812+
                  "package org.springframework.asm;
2813+
2814+
import org.objectweb.asm.Opcodes;")))
2815+
             #t))
27652816
         (add-before 'configure 'rename-dep
27662817
           (lambda _
27672818
             (substitute* "src/main/java/org/springframework/objenesis/SpringObjenesis.java"
2768-
               (("org.springframework.objenesis") "org.objenesis"))
2819+
               (("org.springframework.objenesis\\.") "org.objenesis.")
2820+
               (("import org.springframework.util.ConcurrentReferenceHashMap;")
2821+
                "import org.springframework.util.ConcurrentReferenceHashMap;
2822+
import org.objenesis.Objenesis;
2823+
import org.objenesis.ObjenesisException;"))
2824+
             (substitute* (find-files "." ".*.java")
2825+
               (("org.springframework.asm\\.") "org.objectweb.asm.")
2826+
               (("org.objectweb.asm.SpringAsmInfo")
2827+
                "org.springframework.asm.SpringAsmInfo"))
27692828
             #t))
27702829
         (add-before 'configure 'add-import
27712830
           (lambda _

27892848
                   (find-files "." ".*"))))
27902849
             #t)))))
27912850
    (inputs
2792-
     `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
2793-
       ("java-jopt-simple" ,java-jopt-simple)
2851+
     `(("java-asm" ,java-asm)
2852+
       ("java-aspectj-weaver" ,java-aspectj-weaver)
2853+
       ("java-cglib" ,java-cglib)
27942854
       ("java-commons-codec" ,java-commons-codec)
2855+
       ("java-commons-logging-minimal" ,java-commons-logging-minimal)
2856+
       ("java-jopt-simple" ,java-jopt-simple)
27952857
       ("java-log4j-1.2-api" ,java-log4j-1.2-api)
2796-
       ("java-objenesis" ,java-objenesis)
2797-
       ("java-cglib" ,java-cglib)
2798-
       ("java-aspectj-weaver" ,java-aspectj-weaver)))
2858+
       ("java-objenesis" ,java-objenesis)))
27992859
    (native-inputs
28002860
     `(("java-junit" ,java-junit)
28012861
       ("java-hamcrest-all" ,java-hamcrest-all)
2802-
       ("java-asm" ,java-asm)
28032862
       ("java-jboss-annotations-api-spec" ,java-jboss-annotations-api-spec)
28042863
       ("java-xmlunit-legacy" ,java-xmlunit-legacy)
28052864
       ("java-xmlunit" ,java-xmlunit)

29453004
               (("org.springframework.cglib") "net.sf.cglib")
29463005
               (("net.sf.cglib.core.SpringNamingPolicy") "org.springframework.cglib.core.SpringNamingPolicy"))
29473006
             (substitute* "src/main/java/org/springframework/aop/framework/ObjenesisCglibAopProxy.java"
2948-
               (("org.springframework.objenesis") "org.objenesis"))
3007+
               (("org.springframework.objenesis") "org.objenesis")
3008+
               (("org.objenesis.SpringObjenesis")
3009+
                "org.springframework.objenesis.SpringObjenesis"))
29493010
             #t))
29503011
         (add-before 'check 'copy-test-classes
29513012
           (lambda _

30043065
       ("java-objenesis" ,java-objenesis)
30053066
       ;; Note: for javax-el (el-api)
30063067
       ("java-tomcat" ,java-tomcat)))
3068+
    (native-inputs
3069+
     `(("java-asm" ,java-asm)
3070+
       ,@(package-native-inputs java-spring-framework-core)))
3071+
    (description "")))
3072+
3073+
(define-public java-spring-framework-instrument
3074+
  (package
3075+
    (inherit java-spring-framework-core)
3076+
    (name "java-spring-framework-instrument")
3077+
    (arguments
3078+
     `(#:jar-name "java-spring-framework-instrument.jar"
3079+
       #:jdk ,icedtea-8
3080+
       #:source-dir "src/main/java"
3081+
       #:test-dir "src/test"
3082+
       #:phases
3083+
       (modify-phases %standard-phases
3084+
         (add-before 'configure 'chdir
3085+
           (lambda _
3086+
             ;; Needed because tests look for data in src/... directly.
3087+
             (chdir "spring-instrument")
3088+
             #t))
3089+
         (add-before 'build 'copy-resources
3090+
           (lambda _
3091+
             (copy-recursively "src/main/resources" "build/classes")
3092+
             #t))
3093+
         (add-before 'check 'copy-test-resources
3094+
           (lambda* (#:key inputs #:allow-other-keys)
3095+
             (copy-recursively "src/test/resources"
3096+
                               "build/test-classes")
3097+
             #t)))))
3098+
    (inputs '())
3099+
    (description "")))
3100+
3101+
(define-public java-spring-framework-test
3102+
  (package
3103+
    (inherit java-spring-framework-core)
3104+
    (name "java-spring-framework-test")
3105+
    (arguments
3106+
     `(#:jar-name "java-spring-framework-test.jar"
3107+
       #:jdk ,icedtea-8
3108+
       #:source-dir "src/main/java"
3109+
       #:test-dir "src/test"
3110+
       #:phases
3111+
       (modify-phases %standard-phases
3112+
         (add-before 'configure 'chdir
3113+
           (lambda _
3114+
             ;; Needed because tests look for data in src/... directly.
3115+
             (chdir "spring-test")
3116+
             #t))
3117+
         (add-before 'build 'copy-resources
3118+
           (lambda _
3119+
             (copy-recursively "src/main/resources" "build/classes")
3120+
             #t))
3121+
         (add-before 'check 'copy-test-resources
3122+
           (lambda* (#:key inputs #:allow-other-keys)
3123+
             (copy-recursively "src/test/resources"
3124+
                               "build/test-classes")
3125+
             #t)))))
3126+
    (inputs
3127+
     `(("java-spring-framework-core" ,java-spring-framework-core)
3128+
       ("java-spring-framework-web" ,java-spring-framework-web)))
30073129
    (description "")))
30083130
30093131
(define-public java-spring-framework-context

30153137
       #:jdk ,icedtea-8
30163138
       #:source-dir "src/main/java"
30173139
       #:test-dir "src/test"
3140+
       #:tests? #f; TODO: require spring-framework-test
30183141
       #:phases
30193142
       (modify-phases %standard-phases
30203143
         (add-before 'configure 'chdir

30273150
             (with-directory-excursion "src/main/java/org/springframework"
30283151
               (substitute*
30293152
                 (list
3153+
                   "context/expression/MapAccessor.java"
30303154
                   "context/annotation/ConfigurationClassEnhancer.java"
30313155
                   "scripting/support/ScriptFactoryPostProcessor.java")
3156+
                 (("org.springframework.objenesis.ObjenesisException")
3157+
                  "org.objenesis.ObjenesisException")
3158+
                 (("org.springframework.asm") "org.objectweb.asm")
30323159
                 (("org.springframework.cglib") "net.sf.cglib")
30333160
                 (("net.sf.cglib.core.SpringNamingPolicy")
30343161
                  "org.springframework.cglib.core.SpringNamingPolicy")))

30493176
             #t)))))
30503177
    (inputs
30513178
     `(("groovy" ,groovy)
3179+
       ("java-asm" ,java-asm)
30523180
       ("java-aspectj-weaver" ,java-aspectj-weaver)
30533181
       ("java-bsh" ,java-bsh)
30543182
       ("java-cglib" ,java-cglib)

30583186
       ("java-javax-ejb" ,java-javax-ejb)
30593187
       ("java-javax-inject" ,java-javax-inject)
30603188
       ("java-javax-interceptor" ,java-javax-interceptor)
3061-
       ("java-javax-validation" ,java-javax-validation)
3189+
       ("java-javax-validation-1" ,java-javax-validation-1)
30623190
       ("java-joda-time" ,java-joda-time)
3191+
       ("java-objenesis" ,java-objenesis)
30633192
       ("java-snakeyaml" ,java-snakeyaml)
30643193
       ("java-spring-framework-aop" ,java-spring-framework-aop)
30653194
       ("java-spring-framework-beans" ,java-spring-framework-beans)
30663195
       ("java-spring-framework-beans-groovy" ,java-spring-framework-beans-groovy)
30673196
       ("java-spring-framework-core" ,java-spring-framework-core)
30683197
       ("java-spring-framework-expression" ,java-spring-framework-expression)
3198+
       ("java-spring-framework-instrument" ,java-spring-framework-instrument)
30693199
       ;; Note: for javax-el (el-api)
30703200
       ("java-tomcat" ,java-tomcat)))
3201+
    ;(native-inputs
3202+
    ; `(("java-spring-framework-test" ,java-spring-framework-test)
3203+
    ;   ,@(package-native-inputs java-spring-framework-core)))
30713204
    (description "")))
30723205
3073-
(define-public java-spring-framework-test
3206+
(define-public java-spring-framework-web
30743207
  (package
30753208
    (inherit java-spring-framework-core)
3076-
    (name "java-spring-framework-test")
3209+
    (name "java-spring-framework-web")
30773210
    (arguments
3078-
     `(#:jar-name "java-spring-framework-test.jar"
3211+
     `(#:jar-name "java-spring-framework-web.jar"
30793212
       #:jdk ,icedtea-8
30803213
       #:source-dir "src/main/java"
30813214
       #:test-dir "src/test"

30843217
         (add-before 'configure 'chdir
30853218
           (lambda _
30863219
             ;; Needed because tests look for data in src/... directly.
3087-
             (chdir "spring-test")
3220+
             (chdir "spring-web")
30883221
             #t))
30893222
         (add-before 'build 'copy-resources
30903223
           (lambda _
30913224
             (copy-recursively "src/main/resources" "build/classes")
30923225
             #t))
3226+
         ;(add-before 'check 'copy-test-classes
3227+
         ;  (lambda _
3228+
         ;    (mkdir-p "src/test/java/org/springframework/tests")
3229+
         ;    (copy-file "../spring-core/src/test/java/org/springframework/tests/TestGroup.java"
3230+
         ;               "src/test/java/org/springframework/tests/TestGroup.java")
3231+
         ;    (copy-file "../spring-core/src/test/java/org/springframework/tests/Assume.java"
3232+
         ;               "src/test/java/org/springframework/tests/Assume.java")
3233+
         ;    #t))
30933234
         (add-before 'check 'copy-test-resources
30943235
           (lambda* (#:key inputs #:allow-other-keys)
3095-
             (copy-recursively "src/test/resources"
3096-
                               "build/test-classes")
3236+
             (copy-recursively "src/test/resources" "build/test-classes")
30973237
             #t)))))
30983238
    (inputs
3099-
     `(("java-spring-framework-core" ,java-spring-framework-core)
3100-
       ("java-spring-framework-web" ,java-spring-framework-web)))
3239+
     `(("java-spring-framework-beans" ,java-spring-framework-beans)
3240+
       ("java-spring-framework-core" ,java-spring-framework-core)
3241+
       ("java-httpcomponents-httpasyncclient" ,java-httpcomponents-httpasyncclient)
3242+
       ("java-httpcomponents-httpclient" ,java-httpcomponents-httpclient)
3243+
       ("java-httpcomponents-httpcore" ,java-httpcomponents-httpcore)
3244+
       ("java-httpcomponents-httpcore-nio" ,java-httpcomponents-httpcore-nio)))
31013245
    (description "")))
31023246
31033247
(define-public java-spring-framework-expression

31163260
             ;; Needed because tests look for data in src/... directly.
31173261
             (chdir "spring-expression")
31183262
             #t))
3263+
         (add-before 'build 'fix-asm
3264+
           (lambda _
3265+
             (substitute* (find-files "." ".*.java")
3266+
               (("org.springframework.asm") "org.objectweb.asm"))
3267+
             (substitute* "src/main/java/org/springframework/expression/spel/standard/SpelCompiler.java"
3268+
               (("@Override") ""))
3269+
             #t))
31193270
         (add-before 'build 'copy-resources
31203271
           (lambda _
31213272
             (copy-recursively "src/main/resources" "build/classes")

31343285
                               "build/test-classes")
31353286
             #t)))))
31363287
    (inputs
3137-
     `(("java-commons-logging-minimal" ,java-commons-logging-minimal)
3288+
     `(("java-asm" ,java-asm)
3289+
       ("java-commons-logging-minimal" ,java-commons-logging-minimal)
31383290
       ("java-spring-framework-core" ,java-spring-framework-core)))
31393291
    (description "")))
31403292

36673819
       #:test-dir "src/core/src/test"
36683820
       #:jdk ,icedtea-8))
36693821
    (inputs
3670-
     `(("java-log4j-api" ,java-log4j-api)
3822+
     `(("java-apache-freemarker" ,java-apache-freemarker)
3823+
       ("java-log4j-api" ,java-log4j-api)
36713824
       ("java-commons-lang3" ,java-commons-lang3)
36723825
       ("java-commons-io" ,java-commons-io)
36733826
       ("java-commons-logging-minimal" ,java-commons-logging-minimal)

36763829
       ("java-spring-framework-beans" ,java-spring-framework-beans)
36773830
       ("java-spring-framework-context" ,java-spring-framework-context)
36783831
       ("java-spring-framework-core" ,java-spring-framework-core)
3832+
       ("java-spring-framework-web" ,java-spring-framework-web)
36793833
       ("java-velocity" ,java-velocity)
36803834
       ("java-testng" ,java-testng)))
36813835
    (native-inputs