work on java packages
groovy-Add-exceptionutilsgenerator.patch unknown status 2
1 | - | From 3dbdc68093e90f0ef9b77b70490d8e0b1dcfbf8f Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Sun, 17 Sep 2017 21:08:45 +0200 | |
4 | - | Subject: [PATCH] Add ExceptionUtilsGenerator.java from previous versions | |
5 | - | ||
6 | - | This is replaced by a gradle task, but gradle depends on groovy, so we | |
7 | - | need so way to generate the file without gradle. | |
8 | - | --- | |
9 | - | .../codehaus/groovy/ExceptionUtilsGenerator.java | 75 ++++++++++++++++++++++ | |
10 | - | 1 file changed, 75 insertions(+) | |
11 | - | create mode 100644 config/ant/src/org/codehaus/groovy/ExceptionUtilsGenerator.java | |
12 | - | ||
13 | - | diff --git a/config/ant/src/org/codehaus/groovy/ExceptionUtilsGenerator.java b/config/ant/src/org/codehaus/groovy/ExceptionUtilsGenerator.java | |
14 | - | new file mode 100644 | |
15 | - | index 0000000..41f006d | |
16 | - | --- /dev/null | |
17 | - | +++ b/config/ant/src/org/codehaus/groovy/ExceptionUtilsGenerator.java | |
18 | - | @@ -0,0 +1,75 @@ | |
19 | - | +package org.codehaus.groovy; | |
20 | - | + | |
21 | - | +import org.objectweb.asm.*; | |
22 | - | + | |
23 | - | +import java.io.BufferedOutputStream; | |
24 | - | +import java.io.File; | |
25 | - | +import java.io.FileOutputStream; | |
26 | - | +import java.io.IOException; | |
27 | - | +import java.util.logging.Logger; | |
28 | - | + | |
29 | - | +public class ExceptionUtilsGenerator implements Opcodes { | |
30 | - | + private final static Logger LOGGER = Logger.getLogger(ExceptionUtilsGenerator.class.getName()); | |
31 | - | + | |
32 | - | + public static void main(String... args) { | |
33 | - | + if (args==null || args.length==0) { | |
34 | - | + throw new IllegalArgumentException("You must specify at least one file"); | |
35 | - | + } | |
36 | - | + | |
37 | - | + ClassWriter cw = new ClassWriter(0); | |
38 | - | + MethodVisitor mv; | |
39 | - | + | |
40 | - | + cw.visit(V1_5, ACC_PUBLIC + ACC_SUPER, "org/codehaus/groovy/runtime/ExceptionUtils", null, "java/lang/Object", null); | |
41 | - | + | |
42 | - | + cw.visitSource("ExceptionUtils.java", null); | |
43 | - | + | |
44 | - | + mv = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null); | |
45 | - | + mv.visitCode(); | |
46 | - | + Label l0 = new Label(); | |
47 | - | + mv.visitLabel(l0); | |
48 | - | + mv.visitLineNumber(18, l0); | |
49 | - | + mv.visitVarInsn(ALOAD, 0); | |
50 | - | + mv.visitMethodInsn(INVOKESPECIAL, "java/lang/Object", "<init>", "()V"); | |
51 | - | + mv.visitInsn(RETURN); | |
52 | - | + Label l1 = new Label(); | |
53 | - | + mv.visitLabel(l1); | |
54 | - | + mv.visitLocalVariable("this", "Lorg/codehaus/groovy/runtime/ExceptionUtils;", null, l0, l1, 0); | |
55 | - | + mv.visitMaxs(1, 1); | |
56 | - | + mv.visitEnd(); | |
57 | - | + | |
58 | - | + mv = cw.visitMethod(ACC_PUBLIC + ACC_STATIC, "sneakyThrow", "(Ljava/lang/Throwable;)V", null, null); | |
59 | - | + mv.visitCode(); | |
60 | - | + Label l2 = new Label(); | |
61 | - | + mv.visitLabel(l2); | |
62 | - | + mv.visitLineNumber(20, l2); | |
63 | - | + mv.visitVarInsn(ALOAD, 0); | |
64 | - | + mv.visitInsn(ATHROW); | |
65 | - | + Label l3 = new Label(); | |
66 | - | + mv.visitLabel(l3); | |
67 | - | + mv.visitLocalVariable("e", "Ljava/lang/Throwable;", null, l2, l3, 0); | |
68 | - | + mv.visitMaxs(1, 1); | |
69 | - | + mv.visitEnd(); | |
70 | - | + | |
71 | - | + cw.visitEnd(); | |
72 | - | + | |
73 | - | + LOGGER.info("Generating ExceptionUtils"); | |
74 | - | + byte[] bytes = cw.toByteArray(); | |
75 | - | + for (String classFilePath : args) { | |
76 | - | + File classFile = new File(classFilePath); | |
77 | - | + if (classFile.getParentFile().exists() || classFile.getParentFile().mkdirs()) { | |
78 | - | + try { | |
79 | - | + if (classFile.exists()) { | |
80 | - | + classFile.delete(); | |
81 | - | + } | |
82 | - | + BufferedOutputStream bos = new BufferedOutputStream(new FileOutputStream(classFile)); | |
83 | - | + bos.write(bytes); | |
84 | - | + bos.close(); | |
85 | - | + } catch (IOException e) { | |
86 | - | + LOGGER.warning("Unable to write file "+classFile); | |
87 | - | + } | |
88 | - | + } else { | |
89 | - | + LOGGER.warning("Unable to create directory "+classFile.getParentFile()); | |
90 | - | + } | |
91 | - | + } | |
92 | - | + } | |
93 | - | +} | |
94 | - | -- | |
95 | - | 2.14.1 | |
96 | - |
java-apache-ivy-port-to-latest-bouncycastle.patch unknown status 2
1 | - | From 29055a825af5405e44ffcd59a776f8952bdc7203 Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Fri, 15 Dec 2017 16:03:23 +0100 | |
4 | - | Subject: [PATCH] Port to latest bouncycastle. | |
5 | - | ||
6 | - | --- | |
7 | - | .../bouncycastle/OpenPGPSignatureGenerator.java | 34 ++++++++++------------ | |
8 | - | 1 file changed, 16 insertions(+), 18 deletions(-) | |
9 | - | ||
10 | - | diff --git a/src/java/org/apache/ivy/plugins/signer/bouncycastle/OpenPGPSignatureGenerator.java b/src/java/org/apache/ivy/plugins/signer/bouncycastle/OpenPGPSignatureGenerator.java | |
11 | - | index af7beae..34c204f 100644 | |
12 | - | --- a/src/java/org/apache/ivy/plugins/signer/bouncycastle/OpenPGPSignatureGenerator.java | |
13 | - | +++ b/src/java/org/apache/ivy/plugins/signer/bouncycastle/OpenPGPSignatureGenerator.java | |
14 | - | @@ -41,6 +41,11 @@ import org.bouncycastle.openpgp.PGPSecretKeyRingCollection; | |
15 | - | import org.bouncycastle.openpgp.PGPSignature; | |
16 | - | import org.bouncycastle.openpgp.PGPSignatureGenerator; | |
17 | - | import org.bouncycastle.openpgp.PGPUtil; | |
18 | - | +import org.bouncycastle.openpgp.operator.PBESecretKeyDecryptor; | |
19 | - | +import org.bouncycastle.openpgp.operator.bc.BcPBESecretKeyDecryptorBuilder; | |
20 | - | +import org.bouncycastle.openpgp.operator.bc.BcPGPDigestCalculatorProvider; | |
21 | - | +import org.bouncycastle.openpgp.operator.bc.BcPGPContentSignerBuilder; | |
22 | - | +import org.bouncycastle.openpgp.operator.bc.BcKeyFingerprintCalculator; | |
23 | - | ||
24 | - | public class OpenPGPSignatureGenerator implements SignatureGenerator { | |
25 | - | ||
26 | - | @@ -101,11 +106,15 @@ public class OpenPGPSignatureGenerator implements SignatureGenerator { | |
27 | - | pgpSec = readSecretKey(keyIn); | |
28 | - | } | |
29 | - | ||
30 | - | - PGPPrivateKey pgpPrivKey = pgpSec.extractPrivateKey(password.toCharArray(), | |
31 | - | - BouncyCastleProvider.PROVIDER_NAME); | |
32 | - | - PGPSignatureGenerator sGen = new PGPSignatureGenerator(pgpSec.getPublicKey() | |
33 | - | - .getAlgorithm(), PGPUtil.SHA1, BouncyCastleProvider.PROVIDER_NAME); | |
34 | - | - sGen.initSign(PGPSignature.BINARY_DOCUMENT, pgpPrivKey); | |
35 | - | + PBESecretKeyDecryptor decryptor = | |
36 | - | + new BcPBESecretKeyDecryptorBuilder(new BcPGPDigestCalculatorProvider()) | |
37 | - | + .build(password.toCharArray()); | |
38 | - | + PGPPrivateKey pgpPrivKey = pgpSec.extractPrivateKey(decryptor); | |
39 | - | + BcPGPContentSignerBuilder builder = new BcPGPContentSignerBuilder( | |
40 | - | + pgpSec.getPublicKey().getAlgorithm(), PGPUtil.SHA1); | |
41 | - | + | |
42 | - | + PGPSignatureGenerator sGen = new PGPSignatureGenerator(builder); | |
43 | - | + sGen.init(PGPSignature.BINARY_DOCUMENT, pgpPrivKey); | |
44 | - | ||
45 | - | in = new FileInputStream(src); | |
46 | - | out = new BCPGOutputStream(new ArmoredOutputStream(new FileOutputStream(dest))); | |
47 | - | @@ -116,22 +125,10 @@ public class OpenPGPSignatureGenerator implements SignatureGenerator { | |
48 | - | } | |
49 | - | ||
50 | - | sGen.generate().encode(out); | |
51 | - | - } catch (SignatureException e) { | |
52 | - | - IOException ioexc = new IOException(); | |
53 | - | - ioexc.initCause(e); | |
54 | - | - throw ioexc; | |
55 | - | } catch (PGPException e) { | |
56 | - | IOException ioexc = new IOException(); | |
57 | - | ioexc.initCause(e); | |
58 | - | throw ioexc; | |
59 | - | - } catch (NoSuchAlgorithmException e) { | |
60 | - | - IOException ioexc = new IOException(); | |
61 | - | - ioexc.initCause(e); | |
62 | - | - throw ioexc; | |
63 | - | - } catch (NoSuchProviderException e) { | |
64 | - | - IOException ioexc = new IOException(); | |
65 | - | - ioexc.initCause(e); | |
66 | - | - throw ioexc; | |
67 | - | } finally { | |
68 | - | if (out != null) { | |
69 | - | try { | |
70 | - | @@ -156,7 +153,8 @@ public class OpenPGPSignatureGenerator implements SignatureGenerator { | |
71 | - | ||
72 | - | private PGPSecretKey readSecretKey(InputStream in) throws IOException, PGPException { | |
73 | - | in = PGPUtil.getDecoderStream(in); | |
74 | - | - PGPSecretKeyRingCollection pgpSec = new PGPSecretKeyRingCollection(in); | |
75 | - | + PGPSecretKeyRingCollection pgpSec = new PGPSecretKeyRingCollection(in, | |
76 | - | + new BcKeyFingerprintCalculator()); | |
77 | - | ||
78 | - | PGPSecretKey key = null; | |
79 | - | for (Iterator it = pgpSec.getKeyRings(); key == null && it.hasNext();) { | |
80 | - | -- | |
81 | - | 2.15.1 | |
82 | - |
java-error-prone-add-build.xml.patch unknown status 2
1 | - | From ecb976ffdfc6d43668fdec65b1289dcfdb230c76 Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Sun, 9 Apr 2017 19:18:02 +0200 | |
4 | - | Subject: [PATCH] add build.xml | |
5 | - | ||
6 | - | --- | |
7 | - | build.xml | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
8 | - | 1 file changed, 84 insertions(+) | |
9 | - | create mode 100644 build.xml | |
10 | - | ||
11 | - | diff --git a/build.xml b/build.xml | |
12 | - | new file mode 100644 | |
13 | - | index 0000000..187e820 | |
14 | - | --- /dev/null | |
15 | - | +++ b/build.xml | |
16 | - | @@ -0,0 +1,84 @@ | |
17 | - | +<project basedir="."> | |
18 | - | + <property name="classes.dir" value="${basedir}/build/classes" /> | |
19 | - | + <property name="jar.dir" value="${basedir}/build/jar" /> | |
20 | - | + <property name="build.sysclasspath" value="first" /> | |
21 | - | + <property environment="env" /> | |
22 | - | + <path id="classpath"> | |
23 | - | + <pathelement location="${env.CLASSPATH}" /> | |
24 | - | + </path> | |
25 | - | + | |
26 | - | + <target name="annotation-compile"> | |
27 | - | + <mkdir dir="${classes.dir}/annotation" /> | |
28 | - | + <javac includeantruntime="false" srcdir="annotation/src/main/java/" destdir="${classes.dir}/annotation" classpath="@refidclasspath" /> | |
29 | - | + </target> | |
30 | - | + | |
31 | - | + <target name="check-api-compile" depends="annotation-jar,annotations-jar"> | |
32 | - | + <mkdir dir="${classes.dir}/check_api" /> | |
33 | - | + <javac includeantruntime="false" srcdir="check_api/src/main/java/" destdir="${classes.dir}/check_api" classpath="@refidclasspath"> | |
34 | - | + <classpath path="${env.CLASSPATH}" /> | |
35 | - | + <classpath path="${jar.dir}/errorprone-annotation-1.0.9.jar" /> | |
36 | - | + <classpath path="${jar.dir}/errorprone-annotations-1.0.9.jar" /> | |
37 | - | + </javac> | |
38 | - | + </target> | |
39 | - | + | |
40 | - | + <target name="annotations-compile"> | |
41 | - | + <mkdir dir="${classes.dir}/annotations" /> | |
42 | - | + <javac includeantruntime="false" srcdir="annotations/src/main/java/" destdir="${classes.dir}/annotations" classpath="@refidclasspath" /> | |
43 | - | + </target> | |
44 | - | + | |
45 | - | + <target name="ant-compile" depends="core-jar"> | |
46 | - | + <mkdir dir="${classes.dir}/ant" /> | |
47 | - | + <javac includeantruntime="false" srcdir="ant/src/main/java/" destdir="${classes.dir}/ant" classpath="@refidclasspath"> | |
48 | - | + <classpath path="${env.CLASSPATH}" /> | |
49 | - | + <classpath path="${jar.dir}/errorprone-1.0.9.jar" /> | |
50 | - | + </javac> | |
51 | - | + </target> | |
52 | - | + | |
53 | - | + <target name="compile" depends="annotation-jar,check-api-jar"> | |
54 | - | + <mkdir dir="${classes.dir}/core" /> | |
55 | - | + <javac includeantruntime="false" srcdir="core/src/main/java/" destdir="${classes.dir}/core" classpath="@refidclasspath"> | |
56 | - | + <classpath path="${env.CLASSPATH}" /> | |
57 | - | + <classpath path="${jar.dir}/errorprone-annotation-1.0.9.jar" /> | |
58 | - | + <classpath path="${jar.dir}/errorprone-check-api-1.0.9.jar" /> | |
59 | - | + </javac> | |
60 | - | + </target> | |
61 | - | + | |
62 | - | + <target name="annotation-jar" depends="annotation-compile"> | |
63 | - | + <mkdir dir="${jar.dir}" /> | |
64 | - | + <exec executable="jar"> | |
65 | - | + <arg line="-cf ${jar.dir}/errorprone-annotation-1.0.9.jar -C ${classes.dir}/annotation ." /> | |
66 | - | + </exec> | |
67 | - | + </target> | |
68 | - | + | |
69 | - | + <target name="annotations-jar" depends="annotations-compile"> | |
70 | - | + <mkdir dir="${jar.dir}" /> | |
71 | - | + <exec executable="jar"> | |
72 | - | + <arg line="-cf ${jar.dir}/errorprone-annotations-1.0.9.jar -C ${classes.dir}/annotations ." /> | |
73 | - | + </exec> | |
74 | - | + </target> | |
75 | - | + | |
76 | - | + <target name="ant-jar" depends="ant-compile"> | |
77 | - | + <mkdir dir="${jar.dir}" /> | |
78 | - | + <exec executable="jar"> | |
79 | - | + <arg line="-cf ${jar.dir}/errorprone-ant-1.0.9.jar -C ${classes.dir}/ant ." /> | |
80 | - | + </exec> | |
81 | - | + </target> | |
82 | - | + | |
83 | - | + <target name="core-jar" depends="compile"> | |
84 | - | + <mkdir dir="${jar.dir}" /> | |
85 | - | + <exec executable="jar"> | |
86 | - | + <arg line="-cf ${jar.dir}/errorprone-1.0.9.jar -C ${classes.dir}/core ." /> | |
87 | - | + </exec> | |
88 | - | + </target> | |
89 | - | + | |
90 | - | + <target name="check-api-jar" depends="check-api-compile"> | |
91 | - | + <mkdir dir="${jar.dir}" /> | |
92 | - | + <exec executable="jar"> | |
93 | - | + <arg line="-cf ${jar.dir}/errorprone-check-api-1.0.9.jar -C ${classes.dir}/check_api ." /> | |
94 | - | + </exec> | |
95 | - | + </target> | |
96 | - | + | |
97 | - | + | |
98 | - | + <target name="jar" depends="annotation-jar,annotations-jar,ant-jar,core-jar,check-api-jar"> | |
99 | - | + </target> | |
100 | - | +</project> | |
101 | - | -- | |
102 | - | 2.12.2 | |
103 | - |
java-j2objc-add-build.xml.patch unknown status 2
1 | - | From 00bba583a1e68b7829520e26c939cb1b9f15fd76 Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Sun, 9 Apr 2017 19:18:02 +0200 | |
4 | - | Subject: [PATCH] add build.xml | |
5 | - | ||
6 | - | --- | |
7 | - | build.xml | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
8 | - | 1 file changed, 61 insertions(+) | |
9 | - | create mode 100644 build.xml | |
10 | - | ||
11 | - | diff --git a/build.xml b/build.xml | |
12 | - | new file mode 100644 | |
13 | - | index 0000000..7dc5f60 | |
14 | - | --- /dev/null | |
15 | - | +++ b/build.xml | |
16 | - | @@ -0,0 +1,61 @@ | |
17 | - | +<project basedir="."> | |
18 | - | + <property name="classes.dir" value="${basedir}/build/classes" /> | |
19 | - | + <property name="jar.dir" value="${basedir}/build/jar" /> | |
20 | - | + <property name="build.sysclasspath" value="first" /> | |
21 | - | + <property environment="env" /> | |
22 | - | + <path id="classpath"> | |
23 | - | + <pathelement location="${env.CLASSPATH}" /> | |
24 | - | + </path> | |
25 | - | + | |
26 | - | + <target name="annotation-compile"> | |
27 | - | + <mkdir dir="${classes.dir}/annotation" /> | |
28 | - | + <javac includeantruntime="false" srcdir="annotation/src/main/java/" destdir="${classes.dir}/annotation" classpath="@refidclasspath" /> | |
29 | - | + </target> | |
30 | - | + | |
31 | - | + <target name="annotations-compile"> | |
32 | - | + <mkdir dir="${classes.dir}/annotations" /> | |
33 | - | + <javac includeantruntime="false" srcdir="annotations/src/main/java/" destdir="${classes.dir}/annotations" classpath="@refidclasspath" /> | |
34 | - | + </target> | |
35 | - | + | |
36 | - | + <target name="ant-compile"> | |
37 | - | + <mkdir dir="${classes.dir}/ant" /> | |
38 | - | + <javac includeantruntime="false" srcdir="ant/src/main/java/" destdir="${classes.dir}/ant" classpath="@refidclasspath" /> | |
39 | - | + </target> | |
40 | - | + | |
41 | - | + <target name="compile"> | |
42 | - | + <mkdir dir="${classes.dir}/core" /> | |
43 | - | + <javac includeantruntime="false" srcdir="core/src/main/java/" destdir="${classes.dir}/core" classpath="@refidclasspath" /> | |
44 | - | + </target> | |
45 | - | + | |
46 | - | + <target name="annotation-jar" depends="annotation-compile"> | |
47 | - | + <mkdir dir="${jar.dir}" /> | |
48 | - | + <exec executable="jar"> | |
49 | - | + <arg line="-cf ${jar.dir}/errorprone-annotation-1.0.9.jar -C ${classes.dir}/annotation ." /> | |
50 | - | + </exec> | |
51 | - | + </target> | |
52 | - | + | |
53 | - | + <target name="annotations-jar" depends="annotations-compile"> | |
54 | - | + <mkdir dir="${jar.dir}" /> | |
55 | - | + <exec executable="jar"> | |
56 | - | + <arg line="-cf ${jar.dir}/errorprone-annotations-1.0.9.jar -C ${classes.dir}/annotations ." /> | |
57 | - | + </exec> | |
58 | - | + </target> | |
59 | - | + | |
60 | - | + <target name="ant-jar" depends="ant-compile"> | |
61 | - | + <mkdir dir="${jar.dir}" /> | |
62 | - | + <exec executable="jar"> | |
63 | - | + <arg line="-cf ${jar.dir}/errorprone-ant-1.0.9.jar -C ${classes.dir}/ant ." /> | |
64 | - | + </exec> | |
65 | - | + </target> | |
66 | - | + | |
67 | - | + <target name="core-jar" depends="compile"> | |
68 | - | + <mkdir dir="${jar.dir}" /> | |
69 | - | + <exec executable="jar"> | |
70 | - | + <arg line="-cf ${jar.dir}/errorprone-1.0.9.jar -C ${classes.dir}/core ." /> | |
71 | - | + </exec> | |
72 | - | + </target> | |
73 | - | + | |
74 | - | + | |
75 | - | + <target name="jar" depends="annotation-jar,annotations-jar,ant-jar,core-jar"> | |
76 | - | + </target> | |
77 | - | +</project> | |
78 | - | -- | |
79 | - | 2.12.2 | |
80 | - |
java-jamonapi-jamon-update-dependencies.patch unknown status 1
1 | + | From fe2edb527a0b74341720c7c17ce77133415e84ce Mon Sep 17 00:00:00 2001 | |
2 | + | From: Julien Lepiller <julien@lepiller.eu> | |
3 | + | Date: Thu, 13 Sep 2018 20:11:07 +0200 | |
4 | + | Subject: [PATCH] Update jamon dependencies. | |
5 | + | ||
6 | + | --- | |
7 | + | .../java/com/jamonapi/http/JAMonJettyHandler.java | 15 +++++++-------- | |
8 | + | .../java/com/jamonapi/http/JAMonTomcatValve.java | 1 - | |
9 | + | .../java/com/jamonapi/http/JettyHttpMonItem.java | 2 +- | |
10 | + | .../java/com/jamontomcat/JAMonTomcat55Valve.java | 1 - | |
11 | + | 4 files changed, 8 insertions(+), 11 deletions(-) | |
12 | + | ||
13 | + | diff --git a/jamon/src/main/java/com/jamonapi/http/JAMonJettyHandler.java b/jamon/src/main/java/com/jamonapi/http/JAMonJettyHandler.java | |
14 | + | index c117afa..3f94fc8 100644 | |
15 | + | --- a/jamon/src/main/java/com/jamonapi/http/JAMonJettyHandler.java | |
16 | + | +++ b/jamon/src/main/java/com/jamonapi/http/JAMonJettyHandler.java | |
17 | + | @@ -1,10 +1,10 @@ | |
18 | + | package com.jamonapi.http; | |
19 | + | ||
20 | + | ||
21 | + | -import org.mortbay.jetty.HttpConnection; | |
22 | + | -import org.mortbay.jetty.Request; | |
23 | + | -import org.mortbay.jetty.Response; | |
24 | + | -import org.mortbay.jetty.handler.HandlerWrapper; | |
25 | + | +import org.eclipse.jetty.server.HttpConnection; | |
26 | + | +import org.eclipse.jetty.server.Request; | |
27 | + | +import org.eclipse.jetty.server.Response; | |
28 | + | +import org.eclipse.jetty.server.handler.HandlerWrapper; | |
29 | + | ||
30 | + | import javax.servlet.ServletException; | |
31 | + | import javax.servlet.http.HttpServletRequest; | |
32 | + | @@ -28,14 +28,13 @@ public class JAMonJettyHandler extends HandlerWrapper implements HttpMonManage { | |
33 | + | ||
34 | + | /** Monitor the request and call any other requests in the decorator chain */ | |
35 | + | @Override | |
36 | + | - public void handle(String target, HttpServletRequest request, HttpServletResponse response, int dispatch) throws IOException, ServletException { | |
37 | + | - final Request baseRequest = (request instanceof Request) ? ((Request)request) : HttpConnection.getCurrentConnection().getRequest(); | |
38 | + | - final Response baseResponse = (response instanceof Response) ? ((Response)response) : HttpConnection.getCurrentConnection().getResponse(); | |
39 | + | + public void handle(String target, Request baseRequest, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { | |
40 | + | + final Response baseResponse = (response instanceof Response) ? ((Response)response) : HttpConnection.getCurrentConnection().getHttpChannel().getResponse(); | |
41 | + | ||
42 | + | HttpMon httpMon=null; | |
43 | + | try { | |
44 | + | httpMon=httpMonFactory.start(baseRequest, baseResponse); | |
45 | + | - super.handle(target, request, response, dispatch); | |
46 | + | + super.handle(target, baseRequest, request, response); | |
47 | + | } catch (Throwable e) { | |
48 | + | httpMon.throwException(e); | |
49 | + | } finally { | |
50 | + | diff --git a/jamon/src/main/java/com/jamonapi/http/JAMonTomcatValve.java b/jamon/src/main/java/com/jamonapi/http/JAMonTomcatValve.java | |
51 | + | index 6a3fe96..7d0bd0b 100644 | |
52 | + | --- a/jamon/src/main/java/com/jamonapi/http/JAMonTomcatValve.java | |
53 | + | +++ b/jamon/src/main/java/com/jamonapi/http/JAMonTomcatValve.java | |
54 | + | @@ -116,7 +116,6 @@ public class JAMonTomcatValve extends org.apache.catalina.valves.ValveBase imple | |
55 | + | ||
56 | + | } | |
57 | + | ||
58 | + | - @Override | |
59 | + | public String getInfo() { | |
60 | + | return PREFIX; | |
61 | + | } | |
62 | + | diff --git a/jamon/src/main/java/com/jamonapi/http/JettyHttpMonItem.java b/jamon/src/main/java/com/jamonapi/http/JettyHttpMonItem.java | |
63 | + | index 3507d93..79b8481 100644 | |
64 | + | --- a/jamon/src/main/java/com/jamonapi/http/JettyHttpMonItem.java | |
65 | + | +++ b/jamon/src/main/java/com/jamonapi/http/JettyHttpMonItem.java | |
66 | + | @@ -3,7 +3,7 @@ package com.jamonapi.http; | |
67 | + | ||
68 | + | import com.jamonapi.Monitor; | |
69 | + | import com.jamonapi.MonitorFactory; | |
70 | + | -import org.mortbay.jetty.Request; | |
71 | + | +import org.eclipse.jetty.server.Request; | |
72 | + | ||
73 | + | /** | |
74 | + | * Used to monitor jetty requests via the JAMonJettyHandler. | |
75 | + | diff --git a/jamon/src/main/java/com/jamontomcat/JAMonTomcat55Valve.java b/jamon/src/main/java/com/jamontomcat/JAMonTomcat55Valve.java | |
76 | + | index 7be804c..af1c2f8 100644 | |
77 | + | --- a/jamon/src/main/java/com/jamontomcat/JAMonTomcat55Valve.java | |
78 | + | +++ b/jamon/src/main/java/com/jamontomcat/JAMonTomcat55Valve.java | |
79 | + | @@ -113,7 +113,6 @@ public class JAMonTomcat55Valve extends org.apache.catalina.valves.ValveBase { | |
80 | + | ||
81 | + | } | |
82 | + | ||
83 | + | - @Override | |
84 | + | public String getInfo() { | |
85 | + | return PREFIX; | |
86 | + | } | |
87 | + | -- | |
88 | + | 2.18.0 | |
89 | + |
java-spring-framework-remove-non-free.patch unknown status 1
1 | + | From 45ff8f9aff1ce08546b091505a706b1baf1bcb7b Mon Sep 17 00:00:00 2001 | |
2 | + | From: Julien Lepiller <julien@lepiller.eu> | |
3 | + | Date: Sat, 15 Sep 2018 00:09:39 +0200 | |
4 | + | Subject: [PATCH] Remove dependency on jsr354 (javax.currency). | |
5 | + | ||
6 | + | jsr354 is a non-free package: | |
7 | + | https://github.com/JavaMoney/jsr354-api/blob/master/EVALUATION-LICENCE.txt | |
8 | + | --- | |
9 | + | .../DefaultFormattingConversionService.java | 10 - | |
10 | + | .../number/money/MoneyFormattingTests.java | 272 ------------------ | |
11 | + | 2 files changed, 282 deletions(-) | |
12 | + | delete mode 100644 spring-context/src/test/java/org/springframework/format/number/money/MoneyFormattingTests.java | |
13 | + | ||
14 | + | diff --git a/spring-context/src/main/java/org/springframework/format/support/DefaultFormattingConversionService.java b/spring-context/src/main/java/org/springframework/format/support/DefaultFormattingConversionService.java | |
15 | + | index 2c7c60a..5e38006 100644 | |
16 | + | --- a/spring-context/src/main/java/org/springframework/format/support/DefaultFormattingConversionService.java | |
17 | + | +++ b/spring-context/src/main/java/org/springframework/format/support/DefaultFormattingConversionService.java | |
18 | + | @@ -21,9 +21,6 @@ import org.springframework.format.FormatterRegistry; | |
19 | + | import org.springframework.format.datetime.DateFormatterRegistrar; | |
20 | + | import org.springframework.format.datetime.joda.JodaTimeFormatterRegistrar; | |
21 | + | import org.springframework.format.datetime.standard.DateTimeFormatterRegistrar; | |
22 | + | -import org.springframework.format.number.money.CurrencyUnitFormatter; | |
23 | + | -import org.springframework.format.number.money.Jsr354NumberFormatAnnotationFormatterFactory; | |
24 | + | -import org.springframework.format.number.money.MonetaryAmountFormatter; | |
25 | + | import org.springframework.format.number.NumberFormatAnnotationFormatterFactory; | |
26 | + | import org.springframework.util.ClassUtils; | |
27 | + | import org.springframework.util.StringValueResolver; | |
28 | + | @@ -104,13 +101,6 @@ public class DefaultFormattingConversionService extends FormattingConversionServ | |
29 | + | // Default handling of number values | |
30 | + | formatterRegistry.addFormatterForFieldAnnotation(new NumberFormatAnnotationFormatterFactory()); | |
31 | + | ||
32 | + | - // Default handling of monetary values | |
33 | + | - if (jsr354Present) { | |
34 | + | - formatterRegistry.addFormatter(new CurrencyUnitFormatter()); | |
35 | + | - formatterRegistry.addFormatter(new MonetaryAmountFormatter()); | |
36 | + | - formatterRegistry.addFormatterForFieldAnnotation(new Jsr354NumberFormatAnnotationFormatterFactory()); | |
37 | + | - } | |
38 | + | - | |
39 | + | // Default handling of date-time values | |
40 | + | if (jsr310Present) { | |
41 | + | // just handling JSR-310 specific date and time types | |
42 | + | diff --git a/spring-context/src/test/java/org/springframework/format/number/money/MoneyFormattingTests.java b/spring-context/src/test/java/org/springframework/format/number/money/MoneyFormattingTests.java | |
43 | + | deleted file mode 100644 | |
44 | + | index 28df446..0000000 | |
45 | + | --- a/spring-context/src/test/java/org/springframework/format/number/money/MoneyFormattingTests.java | |
46 | + | +++ /dev/null | |
47 | + | @@ -1,272 +0,0 @@ | |
48 | + | -/* | |
49 | + | - * Copyright 2002-2015 the original author or authors. | |
50 | + | - * | |
51 | + | - * Licensed under the Apache License, Version 2.0 (the "License"); | |
52 | + | - * you may not use this file except in compliance with the License. | |
53 | + | - * You may obtain a copy of the License at | |
54 | + | - * | |
55 | + | - * http://www.apache.org/licenses/LICENSE-2.0 | |
56 | + | - * | |
57 | + | - * Unless required by applicable law or agreed to in writing, software | |
58 | + | - * distributed under the License is distributed on an "AS IS" BASIS, | |
59 | + | - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
60 | + | - * See the License for the specific language governing permissions and | |
61 | + | - * limitations under the License. | |
62 | + | - */ | |
63 | + | - | |
64 | + | -package org.springframework.format.number.money; | |
65 | + | - | |
66 | + | -import java.util.Locale; | |
67 | + | -import javax.money.CurrencyUnit; | |
68 | + | -import javax.money.MonetaryAmount; | |
69 | + | - | |
70 | + | -import org.junit.After; | |
71 | + | -import org.junit.Before; | |
72 | + | -import org.junit.Test; | |
73 | + | - | |
74 | + | -import org.springframework.beans.MutablePropertyValues; | |
75 | + | -import org.springframework.context.i18n.LocaleContextHolder; | |
76 | + | -import org.springframework.format.annotation.NumberFormat; | |
77 | + | -import org.springframework.format.support.DefaultFormattingConversionService; | |
78 | + | -import org.springframework.format.support.FormattingConversionService; | |
79 | + | -import org.springframework.validation.DataBinder; | |
80 | + | - | |
81 | + | -import static org.junit.Assert.*; | |
82 | + | - | |
83 | + | -/** | |
84 | + | - * @author Juergen Hoeller | |
85 | + | - * @since 4.2 | |
86 | + | - */ | |
87 | + | -public class MoneyFormattingTests { | |
88 | + | - | |
89 | + | - private final FormattingConversionService conversionService = new DefaultFormattingConversionService(); | |
90 | + | - | |
91 | + | - | |
92 | + | - @Before | |
93 | + | - public void setUp() { | |
94 | + | - LocaleContextHolder.setLocale(Locale.US); | |
95 | + | - } | |
96 | + | - | |
97 | + | - @After | |
98 | + | - public void tearDown() { | |
99 | + | - LocaleContextHolder.setLocale(null); | |
100 | + | - } | |
101 | + | - | |
102 | + | - | |
103 | + | - @Test | |
104 | + | - public void testAmountAndUnit() { | |
105 | + | - MoneyHolder bean = new MoneyHolder(); | |
106 | + | - DataBinder binder = new DataBinder(bean); | |
107 | + | - binder.setConversionService(conversionService); | |
108 | + | - | |
109 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
110 | + | - propertyValues.add("amount", "USD 10.50"); | |
111 | + | - propertyValues.add("unit", "USD"); | |
112 | + | - binder.bind(propertyValues); | |
113 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
114 | + | - assertEquals("USD10.50", binder.getBindingResult().getFieldValue("amount")); | |
115 | + | - assertEquals("USD", binder.getBindingResult().getFieldValue("unit")); | |
116 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
117 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
118 | + | - | |
119 | + | - LocaleContextHolder.setLocale(Locale.CANADA); | |
120 | + | - binder.bind(propertyValues); | |
121 | + | - LocaleContextHolder.setLocale(Locale.US); | |
122 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
123 | + | - assertEquals("USD10.50", binder.getBindingResult().getFieldValue("amount")); | |
124 | + | - assertEquals("USD", binder.getBindingResult().getFieldValue("unit")); | |
125 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
126 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
127 | + | - } | |
128 | + | - | |
129 | + | - @Test | |
130 | + | - public void testAmountWithNumberFormat1() { | |
131 | + | - FormattedMoneyHolder1 bean = new FormattedMoneyHolder1(); | |
132 | + | - DataBinder binder = new DataBinder(bean); | |
133 | + | - binder.setConversionService(conversionService); | |
134 | + | - | |
135 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
136 | + | - propertyValues.add("amount", "$10.50"); | |
137 | + | - binder.bind(propertyValues); | |
138 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
139 | + | - assertEquals("$10.50", binder.getBindingResult().getFieldValue("amount")); | |
140 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
141 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
142 | + | - | |
143 | + | - LocaleContextHolder.setLocale(Locale.CANADA); | |
144 | + | - binder.bind(propertyValues); | |
145 | + | - LocaleContextHolder.setLocale(Locale.US); | |
146 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
147 | + | - assertEquals("$10.50", binder.getBindingResult().getFieldValue("amount")); | |
148 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
149 | + | - assertEquals("CAD", bean.getAmount().getCurrency().getCurrencyCode()); | |
150 | + | - } | |
151 | + | - | |
152 | + | - @Test | |
153 | + | - public void testAmountWithNumberFormat2() { | |
154 | + | - FormattedMoneyHolder2 bean = new FormattedMoneyHolder2(); | |
155 | + | - DataBinder binder = new DataBinder(bean); | |
156 | + | - binder.setConversionService(conversionService); | |
157 | + | - | |
158 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
159 | + | - propertyValues.add("amount", "10.50"); | |
160 | + | - binder.bind(propertyValues); | |
161 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
162 | + | - assertEquals("10.5", binder.getBindingResult().getFieldValue("amount")); | |
163 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
164 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
165 | + | - } | |
166 | + | - | |
167 | + | - @Test | |
168 | + | - public void testAmountWithNumberFormat3() { | |
169 | + | - FormattedMoneyHolder3 bean = new FormattedMoneyHolder3(); | |
170 | + | - DataBinder binder = new DataBinder(bean); | |
171 | + | - binder.setConversionService(conversionService); | |
172 | + | - | |
173 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
174 | + | - propertyValues.add("amount", "10%"); | |
175 | + | - binder.bind(propertyValues); | |
176 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
177 | + | - assertEquals("10%", binder.getBindingResult().getFieldValue("amount")); | |
178 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 0.1d); | |
179 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
180 | + | - } | |
181 | + | - | |
182 | + | - @Test | |
183 | + | - public void testAmountWithNumberFormat4() { | |
184 | + | - FormattedMoneyHolder4 bean = new FormattedMoneyHolder4(); | |
185 | + | - DataBinder binder = new DataBinder(bean); | |
186 | + | - binder.setConversionService(conversionService); | |
187 | + | - | |
188 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
189 | + | - propertyValues.add("amount", "010.500"); | |
190 | + | - binder.bind(propertyValues); | |
191 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
192 | + | - assertEquals("010.500", binder.getBindingResult().getFieldValue("amount")); | |
193 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
194 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
195 | + | - } | |
196 | + | - | |
197 | + | - @Test | |
198 | + | - public void testAmountWithNumberFormat5() { | |
199 | + | - FormattedMoneyHolder5 bean = new FormattedMoneyHolder5(); | |
200 | + | - DataBinder binder = new DataBinder(bean); | |
201 | + | - binder.setConversionService(conversionService); | |
202 | + | - | |
203 | + | - MutablePropertyValues propertyValues = new MutablePropertyValues(); | |
204 | + | - propertyValues.add("amount", "USD 10.50"); | |
205 | + | - binder.bind(propertyValues); | |
206 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
207 | + | - assertEquals("USD 010.500", binder.getBindingResult().getFieldValue("amount")); | |
208 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
209 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
210 | + | - | |
211 | + | - LocaleContextHolder.setLocale(Locale.CANADA); | |
212 | + | - binder.bind(propertyValues); | |
213 | + | - LocaleContextHolder.setLocale(Locale.US); | |
214 | + | - assertEquals(0, binder.getBindingResult().getErrorCount()); | |
215 | + | - assertEquals("USD 010.500", binder.getBindingResult().getFieldValue("amount")); | |
216 | + | - assertTrue(bean.getAmount().getNumber().doubleValue() == 10.5d); | |
217 | + | - assertEquals("USD", bean.getAmount().getCurrency().getCurrencyCode()); | |
218 | + | - } | |
219 | + | - | |
220 | + | - | |
221 | + | - public static class MoneyHolder { | |
222 | + | - | |
223 | + | - private MonetaryAmount amount; | |
224 | + | - | |
225 | + | - private CurrencyUnit unit; | |
226 | + | - | |
227 | + | - public MonetaryAmount getAmount() { | |
228 | + | - return amount; | |
229 | + | - } | |
230 | + | - | |
231 | + | - public void setAmount(MonetaryAmount amount) { | |
232 | + | - this.amount = amount; | |
233 | + | - } | |
234 | + | - | |
235 | + | - public CurrencyUnit getUnit() { | |
236 | + | - return unit; | |
237 | + | - } | |
238 | + | - | |
239 | + | - public void setUnit(CurrencyUnit unit) { | |
240 | + | - this.unit = unit; | |
241 | + | - } | |
242 | + | - } | |
243 | + | - | |
244 | + | - | |
245 | + | - public static class FormattedMoneyHolder1 { | |
246 | + | - | |
247 | + | - @NumberFormat | |
248 | + | - private MonetaryAmount amount; | |
249 | + | - | |
250 | + | - public MonetaryAmount getAmount() { | |
251 | + | - return amount; | |
252 | + | - } | |
253 | + | - | |
254 | + | - public void setAmount(MonetaryAmount amount) { | |
255 | + | - this.amount = amount; | |
256 | + | - } | |
257 | + | - } | |
258 | + | - | |
259 | + | - | |
260 | + | - public static class FormattedMoneyHolder2 { | |
261 | + | - | |
262 | + | - @NumberFormat(style = NumberFormat.Style.NUMBER) | |
263 | + | - private MonetaryAmount amount; | |
264 | + | - | |
265 | + | - public MonetaryAmount getAmount() { | |
266 | + | - return amount; | |
267 | + | - } | |
268 | + | - | |
269 | + | - public void setAmount(MonetaryAmount amount) { | |
270 | + | - this.amount = amount; | |
271 | + | - } | |
272 | + | - } | |
273 | + | - | |
274 | + | - | |
275 | + | - public static class FormattedMoneyHolder3 { | |
276 | + | - | |
277 | + | - @NumberFormat(style = NumberFormat.Style.PERCENT) | |
278 | + | - private MonetaryAmount amount; | |
279 | + | - | |
280 | + | - public MonetaryAmount getAmount() { | |
281 | + | - return amount; | |
282 | + | - } | |
283 | + | - | |
284 | + | - public void setAmount(MonetaryAmount amount) { | |
285 | + | - this.amount = amount; | |
286 | + | - } | |
287 | + | - } | |
288 | + | - | |
289 | + | - | |
290 | + | - public static class FormattedMoneyHolder4 { | |
291 | + | - | |
292 | + | - @NumberFormat(pattern = "#000.000#") | |
293 | + | - private MonetaryAmount amount; | |
294 | + | - | |
295 | + | - public MonetaryAmount getAmount() { | |
296 | + | - return amount; | |
297 | + | - } | |
298 | + | - | |
299 | + | - public void setAmount(MonetaryAmount amount) { | |
300 | + | - this.amount = amount; | |
301 | + | - } | |
302 | + | - } | |
303 | + | - | |
304 | + | - | |
305 | + | - public static class FormattedMoneyHolder5 { | |
306 | + | - | |
307 | + | - @NumberFormat(pattern = "\u00A4\u00A4 #000.000#") | |
308 | + | - private MonetaryAmount amount; | |
309 | + | - | |
310 | + | - public MonetaryAmount getAmount() { | |
311 | + | - return amount; | |
312 | + | - } | |
313 | + | - | |
314 | + | - public void setAmount(MonetaryAmount amount) { | |
315 | + | - this.amount = amount; | |
316 | + | - } | |
317 | + | - } | |
318 | + | - | |
319 | + | -} | |
320 | + | -- | |
321 | + | 2.18.0 | |
322 | + |
maven-generate-component-xml.patch unknown status 2
1 | - | From da9e282d834f0e2128501a8154128dc95b4c599d Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Sat, 9 Sep 2017 20:34:38 +0200 | |
4 | - | Subject: [PATCH] Add a script to generate component.xml files. | |
5 | - | ||
6 | - | plexus-component-metadata is normally used for this task, but it | |
7 | - | depends on maven-core, which depends on maven-model-builder, which needs | |
8 | - | plexus-component-metadata. This script is meant to break this dependency | |
9 | - | cycle. | |
10 | - | --- | |
11 | - | components.sh | 132 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | |
12 | - | 1 file changed, 132 insertions(+) | |
13 | - | create mode 100755 components.sh | |
14 | - | ||
15 | - | diff --git a/components.sh b/components.sh | |
16 | - | new file mode 100755 | |
17 | - | index 0000000..c6748bd | |
18 | - | --- /dev/null | |
19 | - | +++ b/components.sh | |
20 | - | @@ -0,0 +1,148 @@ | |
21 | - | +## This script generates a rough plexus/components.xml file. It is meant to | |
22 | - | +## replace plexus-component-metadata as it eventually has a recursive dependency | |
23 | - | +## on itself. | |
24 | - | +## | |
25 | - | +## This script must be run in the source directory (usually src/main/java). | |
26 | - | + | |
27 | - | +# Finds the complete name from a class name. | |
28 | - | +function find_role() { | |
29 | - | + role=$1 | |
30 | - | + # Find role | |
31 | - | + case $role in | |
32 | - | + "SettingsWriter" | "SettingsReader") | |
33 | - | + role=org.apache.maven.settings.io.$role | |
34 | - | + ;; | |
35 | - | + "SecDispatcher") | |
36 | - | + role=org.sonatype.plexus.components.sec.dispatcher.$role | |
37 | - | + ;; | |
38 | - | + "SettingsDecrypter") | |
39 | - | + role=org.apache.maven.settings.crypto.$role | |
40 | - | + ;; | |
41 | - | + "SettingsBuilder") | |
42 | - | + role=org.apache.maven.settings.building.$role | |
43 | - | + ;; | |
44 | - | + "SettingsValidator") | |
45 | - | + role=org.apache.maven.settings.validation.$role | |
46 | - | + ;; | |
47 | - | + "LoggerFactory") | |
48 | - | + role=org.eclipse.aether.spi.log.$role | |
49 | - | + ;; | |
50 | - | + "RemoteRepositoryManager" | "VersionResolver" | "VersionRangeResolver" \ | |
51 | - | + | "ArtifactResolver" | "RepositoryEventDispatcher" | "MetadataResolver" \ | |
52 | - | + | "SyncContextFactory" | "MetadataGeneratorFactory" | "MetadatResolver" \ | |
53 | - | + | "ArtifactDescriptorReader") | |
54 | - | + role=org.eclipse.aether.impl.$role | |
55 | - | + ;; | |
56 | - | + "ModelBuilder" | "ModelProcessor") | |
57 | - | + role=org.apache.maven.model.building.$role | |
58 | - | + ;; | |
59 | - | + "ModelValidator") | |
60 | - | + role=org.apache.maven.model.validation.$role | |
61 | - | + ;; | |
62 | - | + "ProfileInjector" | "ProfileSelector") | |
63 | - | + role=org.apache.maven.model.profile.$role | |
64 | - | + ;; | |
65 | - | + "ProfileActivator") | |
66 | - | + role=org.apache.maven.model.profile.activation.$role | |
67 | - | + ;; | |
68 | - | + "SuperPomProvider") | |
69 | - | + role=org.apache.maven.model.superpom.$role | |
70 | - | + ;; | |
71 | - | + "ReportConfigurationExpander" | "PluginConfigurationExpander" \ | |
72 | - | + | "ReportingConverter" | "LifecycleBindingsInjector") | |
73 | - | + role=org.apache.maven.model.plugin.$role | |
74 | - | + ;; | |
75 | - | + "ModelLocator") | |
76 | - | + role=org.apache.maven.model.locator.$role | |
77 | - | + ;; | |
78 | - | + "ModelPathTranslator" | "PathTranslator" | "UrlNormalizer" | "ModelUrlNormalizer") | |
79 | - | + role=org.apache.maven.model.path.$role | |
80 | - | + ;; | |
81 | - | + "DependencyManagementInjector" | "PluginManagementInjector") | |
82 | - | + role=org.apache.maven.model.management.$role | |
83 | - | + ;; | |
84 | - | + "ModelWriter" | "ModelReader") | |
85 | - | + role=org.apache.maven.model.io.$role | |
86 | - | + ;; | |
87 | - | + "DependencyManagementImporter") | |
88 | - | + role=org.apache.maven.model.composition.$role | |
89 | - | + ;; | |
90 | - | + "ModelNormalizer") | |
91 | - | + role=org.apache.maven.model.normalization.$role | |
92 | - | + ;; | |
93 | - | + "ModelInterpolator") | |
94 | - | + role=org.apache.maven.model.interpolation.$role | |
95 | - | + ;; | |
96 | - | + "InheritanceAssembler") | |
97 | - | + role=org.apache.maven.model.inheritance.$role | |
98 | - | + ;; | |
99 | - | + *) | |
100 | - | + role=$role | |
101 | - | + ;; | |
102 | - | + esac | |
103 | - | + echo $role | |
104 | - | +} | |
105 | - | + | |
106 | - | +function generate_xml() { | |
107 | - | +echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" | |
108 | - | +echo "<component-set>" | |
109 | - | +echo "<components>" | |
110 | - | + | |
111 | - | +for file in `find -name '*.java'`; do | |
112 | - | + annot=`grep "@Component" $file` | |
113 | - | + if [ "$?" == "0" ]; then | |
114 | - | + # We have a component! | |
115 | - | + role=$(echo $annot | sed 's|.*role = \(.*\).class.*|\1|') | |
116 | - | + role_hint=$(echo $annot | sed 's|.*hint = "\(.*\)" .*|\1|') | |
117 | - | + if [ "$role_hint" = "$annot" ]; then | |
118 | - | + role_hint=default | |
119 | - | + fi | |
120 | - | + implem=$(echo $file | sed -e 's|^\./||' -e 's|\.java||' -e 's|/|.|g') | |
121 | - | + role=$(find_role $role) | |
122 | - | + | |
123 | - | + echo "<component>" | |
124 | - | + echo " <role>$role</role>" | |
125 | - | + echo " <role-hint>$role_hint</role-hint>" | |
126 | - | + echo " <implementation>$implem</implementation>" | |
127 | - | + echo " <description />" | |
128 | - | + echo " <isolated-realm>false</isolated-realm>" | |
129 | - | + echo " <requirements>" | |
130 | - | + reqn=1 | |
131 | - | + cont=true | |
132 | - | + while [ "$cont" = "true" ]; do | |
133 | - | + requirement=$(grep "@Requirement" $file -A1 | head -n ${reqn} | tail -1) | |
134 | - | + ((reqn++)) | |
135 | - | + property=$(grep "@Requirement" $file -A1 | head -n ${reqn} | tail -1) | |
136 | - | + if (echo $requirement | grep "@Requirement" >/dev/null); then | |
137 | - | + ((reqn++)) | |
138 | - | + ((reqn++)) | |
139 | - | + optional=$(echo $requirement | sed 's|.*optional = \(.*\) .*|\1|') | |
140 | - | + req_role=$(echo $requirement | sed 's|.*role = \(.*\).class .*|\1|') | |
141 | - | + if (echo $req_role | grep "@Requirement" >/dev/null); then | |
142 | - | + req_role=$(echo $property | sed 's|.*private \(.*\) .*|\1|') | |
143 | - | + fi | |
144 | - | + req_role=$(find_role $req_role) | |
145 | - | + req_name=$(echo $property | sed 's|[^ ]* [^ ]* \([^ ;]*\).*|\1|') | |
146 | - | + echo " <requirement>" | |
147 | - | + echo " <role>$req_role</role>" | |
148 | - | + echo " <field-name>$req_name</field-name>" | |
149 | - | + if (echo $optional | grep "@Requirement" >/dev/null); then | |
150 | - | + : | |
151 | - | + else | |
152 | - | + echo " <optional>$optional</optional>" | |
153 | - | + fi | |
154 | - | + echo " </requirement>" | |
155 | - | + else | |
156 | - | + cont=false | |
157 | - | + fi | |
158 | - | + done | |
159 | - | + echo " </requirements>" | |
160 | - | + echo "</component>" | |
161 | - | + fi | |
162 | - | +done | |
163 | - | + | |
164 | - | +echo "</components>" | |
165 | - | +echo "</component-set>" | |
166 | - | +} | |
167 | - | + | |
168 | - | +(cd $1; generate_xml) > $2 | |
169 | - | -- | |
170 | - | 2.14.1 | |
171 | - |
maven-generate-javax-inject-named.patch unknown status 2
1 | - | From 1d20c0e403f1a38d4aca830e0eb4db03ba43efd3 Mon Sep 17 00:00:00 2001 | |
2 | - | From: Julien Lepiller <julien@lepiller.eu> | |
3 | - | Date: Tue, 19 Sep 2017 22:21:29 +0200 | |
4 | - | Subject: [PATCH] Add sisu-maven-plugin replacement | |
5 | - | ||
6 | - | --- | |
7 | - | sisu.sh | 12 ++++++++++++ | |
8 | - | 1 file changed, 12 insertions(+) | |
9 | - | create mode 100755 sisu.sh | |
10 | - | ||
11 | - | diff --git a/sisu.sh b/sisu.sh | |
12 | - | new file mode 100755 | |
13 | - | index 0000000..979f373 | |
14 | - | --- /dev/null | |
15 | - | +++ b/sisu.sh | |
16 | - | @@ -0,0 +1,12 @@ | |
17 | - | +## This script generates a rough javax.inject.Named file. It is meant to | |
18 | - | +## replace sisu-maven-plugin as it eventually has a recursive dependency | |
19 | - | +## on maven. | |
20 | - | +## | |
21 | - | +## This script must be run in the source directory (usually src/main/java). | |
22 | - | + | |
23 | - | +for file in `(cd $1; find -name '*.java')`; do | |
24 | - | + annot=`grep "^@Named" $1/$file` | |
25 | - | + if [ "$annot" != "" ]; then | |
26 | - | + echo $file | sed -e 's|^\./||' -e 's|\.java||' -e 's|/|.|g' | |
27 | - | + fi | |
28 | - | +done > $2 | |
29 | - | -- | |
30 | - | 2.14.1 | |
31 | - |
more/packages/java.scm
1475 | 1475 | (define-public java-aspectj-weaver | |
1476 | 1476 | (package | |
1477 | 1477 | (name "java-aspectj-weaver") | |
1478 | - | (version "1.8.10") | |
1478 | + | (version "1.9.1") | |
1479 | 1479 | (source (origin | |
1480 | 1480 | (method url-fetch) | |
1481 | 1481 | (uri (string-append "http://eclipsemirror.itemis.de/eclipse/tools" | |
1482 | 1482 | "/aspectj/aspectj-" version "-src.jar")) | |
1483 | 1483 | (sha256 | |
1484 | 1484 | (base32 | |
1485 | - | "0r16lgzindqf4xhdmdyk9j6p15nak2fwhqlp42yg3axvn8fx6r23")))) | |
1485 | + | ;"0r16lgzindqf4xhdmdyk9j6p15nak2fwhqlp42yg3axvn8fx6r23")))) | |
1486 | + | "1g8g6ynwqg93x6842a0xhrgjcfnszd1wldsw3v3dp3xpc8makrfp")))) | |
1486 | 1487 | (build-system ant-build-system) | |
1487 | 1488 | (arguments | |
1488 | 1489 | `(#:jar-name "java-aspectj-weaver.jar" | |
… | |||
1495 | 1496 | (lambda _ | |
1496 | 1497 | (mkdir-p "weaver-src") | |
1497 | 1498 | (chdir "weaver-src") | |
1498 | - | (zero? (system* "jar" "xf" "../src/aspectjweaver1.8.10-src.jar")))) | |
1499 | + | (zero? (system* "jar" "xf" "../src/aspectjweaver1.9.1-src.jar")))) | |
1499 | 1500 | (add-after 'unpack-jar 'remove-propriatory | |
1500 | 1501 | (lambda _ | |
1501 | 1502 | ;; this file depends on JRockit, for which I can't find a free implementation | |
1502 | - | (delete-file "org/aspectj/weaver/loadtime/JRockitAgent.java"))) | |
1503 | + | (delete-file "org/aspectj/weaver/loadtime/JRockitAgent.java") | |
1504 | + | #t)) | |
1503 | 1505 | (add-after 'unpack-jar 'rename-lib-back | |
1504 | 1506 | (lambda _ | |
1505 | 1507 | ;; aj.org.objectweb.asm is actually java-asm, renamed | |
1506 | 1508 | (substitute* "org/aspectj/weaver/bcel/asm/StackMapAdder.java" | |
1507 | - | (("aj.org.objectweb.asm") "org.objectweb.asm")))) | |
1509 | + | (("aj.org.objectweb.asm") "org.objectweb.asm")) | |
1510 | + | #t)) | |
1508 | 1511 | (add-before 'build 'copy-ressource | |
1509 | 1512 | (lambda _ | |
1510 | 1513 | (mkdir-p "build/classes") | |
1511 | - | (copy-file "aspectj_1_5_0.dtd" "build/classes/aspectj_1_5_0.dtd")))))) | |
1514 | + | (copy-file "aspectj_1_5_0.dtd" "build/classes/aspectj_1_5_0.dtd") | |
1515 | + | #t))))) | |
1512 | 1516 | (inputs | |
1513 | 1517 | `(("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
1514 | 1518 | ("java-asm" ,java-asm))) | |
… | |||
1532 | 1536 | (lambda _ | |
1533 | 1537 | (mkdir-p "rt-src") | |
1534 | 1538 | (chdir "rt-src") | |
1535 | - | (zero? (system* "jar" "xf" "../src/aspectjrt1.8.10-src.jar"))))))) | |
1539 | + | (zero? (system* "jar" "xf" "../src/aspectjrt1.9.1-src.jar"))))))) | |
1536 | 1540 | (inputs | |
1537 | 1541 | `(("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
1538 | 1542 | ("java-asm" ,java-asm))) | |
1539 | 1543 | (description ""))) | |
1540 | 1544 | ||
1545 | + | ;(define-public java-aspectj-tools | |
1546 | + | ; (package | |
1547 | + | ; (inherit java-aspectj-weaver) | |
1548 | + | ; (name "java-aspectj-tools") | |
1549 | + | ; (arguments | |
1550 | + | ; `(#:jar-name "java-aspectj-tools.jar" | |
1551 | + | ; #:source-dir "." | |
1552 | + | ; #:jdk ,icedtea-8 | |
1553 | + | ; #:tests? #f; no tests | |
1554 | + | ; #:phases | |
1555 | + | ; (modify-phases %standard-phases | |
1556 | + | ; (add-before 'configure 'unpack-jar | |
1557 | + | ; (lambda _ | |
1558 | + | ; (mkdir-p "tools-src") | |
1559 | + | ; (chdir "tools-src") | |
1560 | + | ; (invoke "jar" "xf" "../src/aspectjtools1.9.1-src.jar") | |
1561 | + | ; (for-each delete-file (find-files ".." ".*.jar$")) | |
1562 | + | ; #t)) | |
1563 | + | ; (add-before 'build 'copy-resources | |
1564 | + | ; (lambda _ | |
1565 | + | ; (for-each delete-file (find-files "." ".*.class$")) | |
1566 | + | ; (mkdir-p "build/classes") | |
1567 | + | ; (for-each | |
1568 | + | ; (lambda (file) | |
1569 | + | ; (mkdir-p (string-append "build/classes/" (dirname file))) | |
1570 | + | ; (copy-file file (string-append "build/classes/" file))) | |
1571 | + | ; (append | |
1572 | + | ; (find-files "." ".*.gif$") | |
1573 | + | ; (find-files "." ".*.html$") | |
1574 | + | ; (find-files "." ".*.properties$") | |
1575 | + | ; (find-files "." ".*.rsc$") | |
1576 | + | ; (find-files "." ".*.xml$"))) | |
1577 | + | ; #t))))) | |
1578 | + | ; (inputs | |
1579 | + | ; `(("java-asm" ,java-asm) | |
1580 | + | ; ("java-aspectj-weaver" ,java-aspectj-weaver) | |
1581 | + | ; ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
1582 | + | ; ("java-eclipse-core-resources" ,java-eclipse-core-resources) | |
1583 | + | ; ("java-eclipse-core-runtime" ,java-eclipse-core-runtime) | |
1584 | + | ; ("java-eclipse-text" ,java-eclipse-text))) | |
1585 | + | ; (description ""))) | |
1586 | + | ||
1541 | 1587 | (define-public java-jsr107 | |
1542 | 1588 | (package | |
1543 | 1589 | (name "java-jsr107") | |
… | |||
2034 | 2080 | ;; A link to the license is present in pom.xml | |
2035 | 2081 | (license license:bsd-3))) | |
2036 | 2082 | ||
2083 | + | (define-public java-javax-validation | |
2084 | + | (package | |
2085 | + | (name "java-javax-validation") | |
2086 | + | (version "2.0.1") | |
2087 | + | (source (origin | |
2088 | + | (method url-fetch) | |
2089 | + | (uri (string-append "https://github.com/beanvalidation/" | |
2090 | + | "beanvalidation-api/archive/" version | |
2091 | + | ".Final.tar.gz")) | |
2092 | + | (sha256 | |
2093 | + | (base32 | |
2094 | + | "0mmzwrgwfvi68jfjh8ijy8za3wmp5rmwsplyghwyf9lwb9p5x5qz")))) | |
2095 | + | (build-system ant-build-system) | |
2096 | + | (arguments | |
2097 | + | `(#:jar-name "javax-validation.jar" | |
2098 | + | #:tests? #f; require an implementation like Hibernate Validator | |
2099 | + | #:source-dir "src/main/java" | |
2100 | + | #:phases | |
2101 | + | (modify-phases %standard-phases | |
2102 | + | (add-before 'build 'copy-resources | |
2103 | + | (lambda _ | |
2104 | + | (copy-recursively "src/main/resources" "build/classes") | |
2105 | + | #t))))) | |
2106 | + | ;(replace 'check | |
2107 | + | ; (lambda _ | |
2108 | + | ; (mkdir-p "build/test-classes") | |
2109 | + | ; (apply invoke "javac" "-cp" | |
2110 | + | ; (string-append (getenv "CLASSPATH") ":build/classes") | |
2111 | + | ; "-d" "build/test-classes" (find-files "src/test/java" ".*.java$")) | |
2112 | + | ; (with-directory-excursion "build/test-classes" | |
2113 | + | ; (invoke "java" "-cp" | |
2114 | + | ; (string-append (getenv "CLASSPATH") ":../classes:.") | |
2115 | + | ; "org.testng.TestNG" "-verbose" "5" "-testclass" | |
2116 | + | ; "javax.validation.ValidationTest")) | |
2117 | + | ; #t))))) | |
2118 | + | (native-inputs | |
2119 | + | `(("java-hamcrest-core" ,java-hamcrest-core) | |
2120 | + | ("java-testng" ,java-testng))) | |
2121 | + | (home-page "") | |
2122 | + | (synopsis "") | |
2123 | + | (description "") | |
2124 | + | (license license:asl2.0))) | |
2125 | + | ||
2126 | + | ;; javax.enterprise.concurrency | |
2127 | + | (define-public java-concurrency-api | |
2128 | + | (package | |
2129 | + | (name "java-concurrency-api") | |
2130 | + | (version "1.1") | |
2131 | + | (source (origin | |
2132 | + | (method url-fetch) | |
2133 | + | (uri (string-append "https://github.com/javaee/concurrency-ee-spec/" | |
2134 | + | "archive/javax.enterprise.concurrent-api-" | |
2135 | + | version ".tar.gz")) | |
2136 | + | (sha256 | |
2137 | + | (base32 | |
2138 | + | "038rc3bvpq4y96g0bb7b0ac6ip8m4rr931r1mlfmcnbav1n8b7wp")))) | |
2139 | + | (build-system ant-build-system) | |
2140 | + | (arguments | |
2141 | + | `(#:jar-name "concurrency-api.jar" | |
2142 | + | #:source-dir "api/src/main/java" | |
2143 | + | #:test-dir "api/src/test")) | |
2144 | + | (native-inputs | |
2145 | + | `(("java-hamcrest-core" ,java-hamcrest-core) | |
2146 | + | ("java-junit" ,java-junit))) | |
2147 | + | (home-page "https://github.com/eclipse-ee4j/concurrency-api") | |
2148 | + | (synopsis "") | |
2149 | + | (description "") | |
2150 | + | (license license:cddl1.1))) | |
2151 | + | ||
2037 | 2152 | (define-public java-spring-framework-core | |
2038 | 2153 | (package | |
2039 | 2154 | (name "java-spring-framework-core") | |
… | |||
2045 | 2160 | ".RELEASE.tar.gz")) | |
2046 | 2161 | (sha256 | |
2047 | 2162 | (base32 | |
2048 | - | "036jcwh2g3qlv14lalhkpkjnwc1hjn4zdqf251231vywxyd838zm")))) | |
2163 | + | "036jcwh2g3qlv14lalhkpkjnwc1hjn4zdqf251231vywxyd838zm")) | |
2164 | + | (patches (search-patches "java-spring-framework-remove-non-free.patch")))) | |
2049 | 2165 | (arguments | |
2050 | 2166 | `(#:jar-name "java-spring-framework-core.jar" | |
2051 | 2167 | #:jdk ,icedtea-8 | |
… | |||
2124 | 2240 | (inherit java-spring-framework-core) | |
2125 | 2241 | (name "java-spring-framework-beans") | |
2126 | 2242 | (arguments | |
2127 | - | `(#:jar-name "java-spring-framework-core.jar" | |
2243 | + | `(#:jar-name "java-spring-framework-beans.jar" | |
2128 | 2244 | #:jdk ,icedtea-8 | |
2129 | 2245 | #:source-dir "src/main/java" | |
2130 | 2246 | #:test-dir "src/test" | |
… | |||
2177 | 2293 | ("java-tomcat" ,java-tomcat))) | |
2178 | 2294 | (description ""))) | |
2179 | 2295 | ||
2296 | + | (define-public java-spring-framework-beans-groovy | |
2297 | + | (package | |
2298 | + | (inherit java-spring-framework-core) | |
2299 | + | (name "java-spring-framework-beans-groovy") | |
2300 | + | (arguments | |
2301 | + | `(#:jar-name "java-spring-framework-beans-groovy.jar" | |
2302 | + | #:jdk ,icedtea-8 | |
2303 | + | #:source-dir "src/main/java" | |
2304 | + | #:tests? #f; no tests | |
2305 | + | #:phases | |
2306 | + | (modify-phases %standard-phases | |
2307 | + | (add-before 'configure 'chdir | |
2308 | + | (lambda _ | |
2309 | + | ;; Needed because tests look for data in src/... directly. | |
2310 | + | (chdir "spring-beans-groovy") | |
2311 | + | #t)) | |
2312 | + | (replace 'build | |
2313 | + | (lambda* (#:key inputs #:allow-other-keys) | |
2314 | + | (setenv "CLASSPATH" "") | |
2315 | + | (mkdir-p "build/classes") | |
2316 | + | (mkdir-p "build/jar") | |
2317 | + | (apply invoke "groovyc" "-j" "-d" "build/classes" | |
2318 | + | "-cp" (string-join | |
2319 | + | (append | |
2320 | + | (find-files (assoc-ref inputs "java-commons-logging-minimal") ".*.jar$") | |
2321 | + | (find-files (assoc-ref inputs "java-spring-framework-core") ".*.jar$") | |
2322 | + | (find-files (assoc-ref inputs "java-spring-framework-beans") ".*.jar$")) | |
2323 | + | ":") | |
2324 | + | (append | |
2325 | + | (find-files "src/main/java" ".*.java$") | |
2326 | + | (find-files "src/main/groovy" ".*.groovy$"))) | |
2327 | + | (invoke "jar" "cf" "build/jar/java-spring-framework-beans-groovy.jar" "-C" "build/classes" ".") | |
2328 | + | #t))))) | |
2329 | + | (inputs | |
2330 | + | `(("groovy" ,groovy) | |
2331 | + | ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
2332 | + | ("java-spring-framework-beans" ,java-spring-framework-beans) | |
2333 | + | ("java-spring-framework-core" ,java-spring-framework-core))) | |
2334 | + | (description ""))) | |
2335 | + | ||
2180 | 2336 | (define-public java-spring-framework-aop | |
2181 | 2337 | (package | |
2182 | 2338 | (inherit java-spring-framework-core) | |
… | |||
2186 | 2342 | #:jdk ,icedtea-8 | |
2187 | 2343 | #:source-dir "src/main/java" | |
2188 | 2344 | #:test-dir "src/test" | |
2345 | + | #:test-exclude | |
2346 | + | (list | |
2347 | + | "**/AspectJExpressionPointcutTests.java" | |
2348 | + | "**/Abstract*.java" | |
2349 | + | ;; Required parameter names not available | |
2350 | + | "**/ArgumentBindingTests.java" | |
2351 | + | "**/ReflectiveAspectJAdvisorFactoryTests.java") | |
2352 | + | #:test-include | |
2353 | + | (list "**/*Tests.java") | |
2189 | 2354 | #:phases | |
2190 | 2355 | (modify-phases %standard-phases | |
2191 | 2356 | (add-before 'configure 'chdir | |
… | |||
2207 | 2372 | (substitute* "src/main/java/org/springframework/aop/framework/ObjenesisCglibAopProxy.java" | |
2208 | 2373 | (("org.springframework.objenesis") "org.objenesis")) | |
2209 | 2374 | #t)) | |
2210 | - | ;(add-before 'check 'copy-test-classes | |
2211 | - | ; (lambda _ | |
2212 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/Assume.java" | |
2213 | - | ; "src/test/java/org/springframework/tests/Assume.java") | |
2214 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/TestGroup.java" | |
2215 | - | ; "src/test/java/org/springframework/tests/TestGroup.java") | |
2216 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/TestResourceUtils.java" | |
2217 | - | ; "src/test/java/org/springframework/tests/TestResourceUtils.java") | |
2218 | - | ; (mkdir-p "src/test/java/org/springframework/stereotype") | |
2219 | - | ; (mkdir-p "src/test/java/org/springframework/util") | |
2220 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/stereotype/Component.java" | |
2221 | - | ; "src/test/java/org/springframework/stereotype/Component.java") | |
2222 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/util/SerializationTestUtils.java" | |
2223 | - | ; "src/test/java/org/springframework/util/SerializationTestUtils.java") | |
2224 | - | ; (substitute* "src/test/java/org/springframework/beans/factory/BeanFactoryUtilsTests.java" | |
2225 | - | ; (("org.springframework.cglib") "net.sf.cglib")) | |
2226 | - | ; #t)) | |
2375 | + | (add-before 'check 'copy-test-classes | |
2376 | + | (lambda _ | |
2377 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/TestResourceUtils.java" | |
2378 | + | "src/test/java/org/springframework/tests/TestResourceUtils.java") | |
2379 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/TimeStamped.java" | |
2380 | + | "src/test/java/org/springframework/tests/TimeStamped.java") | |
2381 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/Assume.java" | |
2382 | + | "src/test/java/org/springframework/tests/Assume.java") | |
2383 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/TestGroup.java" | |
2384 | + | "src/test/java/org/springframework/tests/TestGroup.java") | |
2385 | + | (mkdir "src/test/java/org/springframework/util") | |
2386 | + | (copy-file "../spring-core/src/test/java/org/springframework/util/SerializationTestUtils.java" | |
2387 | + | "src/test/java/org/springframework/util/SerializationTestUtils.java") | |
2388 | + | (mkdir "src/test/java/org/springframework/tests/beans") | |
2389 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/beans/CollectingReaderEventListener.java" | |
2390 | + | "src/test/java/org/springframework/tests/beans/CollectingReaderEventListener.java") | |
2391 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/DerivedTestBean.java" | |
2392 | + | "src/test/java/org/springframework/tests/sample/beans/DerivedTestBean.java") | |
2393 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/INestedTestBean.java" | |
2394 | + | "src/test/java/org/springframework/tests/sample/beans/INestedTestBean.java") | |
2395 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/NestedTestBean.java" | |
2396 | + | "src/test/java/org/springframework/tests/sample/beans/NestedTestBean.java") | |
2397 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/IndexedTestBean.java" | |
2398 | + | "src/test/java/org/springframework/tests/sample/beans/IndexedTestBean.java") | |
2399 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/Colour.java" | |
2400 | + | "src/test/java/org/springframework/tests/sample/beans/Colour.java") | |
2401 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/TestBean.java" | |
2402 | + | "src/test/java/org/springframework/tests/sample/beans/TestBean.java") | |
2403 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/ITestBean.java" | |
2404 | + | "src/test/java/org/springframework/tests/sample/beans/ITestBean.java") | |
2405 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/IOther.java" | |
2406 | + | "src/test/java/org/springframework/tests/sample/beans/IOther.java") | |
2407 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/CountingTestBean.java" | |
2408 | + | "src/test/java/org/springframework/tests/sample/beans/CountingTestBean.java") | |
2409 | + | (copy-file "../spring-beans/src/test/java/org/springframework/tests/sample/beans/SideEffectBean.java" | |
2410 | + | "src/test/java/org/springframework/tests/sample/beans/SideEffectBean.java") | |
2411 | + | #t)) | |
2227 | 2412 | (add-before 'check 'copy-test-resources | |
2228 | 2413 | (lambda* (#:key inputs #:allow-other-keys) | |
2229 | 2414 | (copy-recursively "src/test/resources" | |
… | |||
2236 | 2421 | ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
2237 | 2422 | ("java-commons-pool" ,java-commons-pool) | |
2238 | 2423 | ("java-commons-pool2" ,java-commons-pool2) | |
2424 | + | ("java-jamonapi-jamon-bootstrap" ,java-jamonapi-jamon-bootstrap) | |
2239 | 2425 | ("java-javax-inject" ,java-javax-inject) | |
2240 | 2426 | ("java-snakeyaml" ,java-snakeyaml) | |
2241 | 2427 | ("java-spring-framework-beans" ,java-spring-framework-beans) | |
2242 | 2428 | ("java-spring-framework-core" ,java-spring-framework-core) | |
2243 | - | ("java-jamonapi-jamon-bootstrap" ,java-jamonapi-jamon-bootstrap) | |
2429 | + | ("java-objenesis" ,java-objenesis) | |
2244 | 2430 | ;; Note: for javax-el (el-api) | |
2245 | 2431 | ("java-tomcat" ,java-tomcat))) | |
2246 | 2432 | (description ""))) | |
… | |||
2261 | 2447 | ;; Needed because tests look for data in src/... directly. | |
2262 | 2448 | (chdir "spring-context") | |
2263 | 2449 | #t)) | |
2450 | + | (add-before 'build 'remove-jruby | |
2451 | + | (lambda _ | |
2452 | + | (delete-file-recursively | |
2453 | + | "src/main/java/org/springframework/scripting/jruby") | |
2454 | + | #t)) | |
2264 | 2455 | (add-before 'build 'copy-resources | |
2265 | 2456 | (lambda _ | |
2266 | 2457 | (copy-recursively "src/main/resources" "build/classes") | |
2267 | 2458 | #t)) | |
2268 | - | ;(add-before 'configure 'rename-dep | |
2269 | - | ; (lambda _ | |
2270 | - | ; (substitute* "src/main/java/org/springframework/beans/factory/support/CglibSubclassingInstantiationStrategy.java" | |
2271 | - | ; (("org.springframework.cglib") "net.sf.cglib") | |
2272 | - | ; (("net.sf.cglib.core.SpringNamingPolicy") "org.springframework.cglib.core.SpringNamingPolicy")) | |
2273 | - | ; #t)) | |
2274 | - | ;(add-before 'check 'copy-test-classes | |
2275 | - | ; (lambda _ | |
2276 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/Assume.java" | |
2277 | - | ; "src/test/java/org/springframework/tests/Assume.java") | |
2278 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/TestGroup.java" | |
2279 | - | ; "src/test/java/org/springframework/tests/TestGroup.java") | |
2280 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/tests/TestResourceUtils.java" | |
2281 | - | ; "src/test/java/org/springframework/tests/TestResourceUtils.java") | |
2282 | - | ; (mkdir-p "src/test/java/org/springframework/stereotype") | |
2283 | - | ; (mkdir-p "src/test/java/org/springframework/util") | |
2284 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/stereotype/Component.java" | |
2285 | - | ; "src/test/java/org/springframework/stereotype/Component.java") | |
2286 | - | ; (copy-file "../spring-core/src/test/java/org/springframework/util/SerializationTestUtils.java" | |
2287 | - | ; "src/test/java/org/springframework/util/SerializationTestUtils.java") | |
2288 | - | ; (substitute* "src/test/java/org/springframework/beans/factory/BeanFactoryUtilsTests.java" | |
2289 | - | ; (("org.springframework.cglib") "net.sf.cglib")) | |
2290 | - | ; #t)) | |
2291 | 2459 | (add-before 'check 'copy-test-resources | |
2292 | 2460 | (lambda* (#:key inputs #:allow-other-keys) | |
2293 | 2461 | (copy-recursively "src/test/resources" | |
2294 | 2462 | "build/test-classes") | |
2295 | 2463 | #t))))) | |
2296 | 2464 | (inputs | |
2297 | - | `(("java-cglib" ,java-cglib) | |
2465 | + | `(("groovy" ,groovy) | |
2466 | + | ("java-bsh" ,java-bsh) | |
2467 | + | ("java-cglib" ,java-cglib) | |
2298 | 2468 | ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
2469 | + | ("java-concurrency-api" ,java-concurrency-api) | |
2299 | 2470 | ("java-javax-inject" ,java-javax-inject) | |
2471 | + | ("java-javax-validation" ,java-javax-validation) | |
2472 | + | ("java-joda-time" ,java-joda-time) | |
2300 | 2473 | ("java-snakeyaml" ,java-snakeyaml) | |
2301 | 2474 | ("java-spring-framework-aop" ,java-spring-framework-aop) | |
2302 | 2475 | ("java-spring-framework-beans" ,java-spring-framework-beans) | |
2476 | + | ("java-spring-framework-beans-groovy" ,java-spring-framework-beans-groovy) | |
2303 | 2477 | ("java-spring-framework-core" ,java-spring-framework-core) | |
2478 | + | ("java-spring-framework-expression" ,java-spring-framework-expression) | |
2304 | 2479 | ;; Note: for javax-el (el-api) | |
2305 | 2480 | ("java-tomcat" ,java-tomcat))) | |
2306 | 2481 | (description ""))) | |
… | |||
2335 | 2510 | ("java-spring-framework-web" ,java-spring-framework-web))) | |
2336 | 2511 | (description ""))) | |
2337 | 2512 | ||
2513 | + | (define-public java-spring-framework-expression | |
2514 | + | (package | |
2515 | + | (inherit java-spring-framework-core) | |
2516 | + | (name "java-spring-framework-expression") | |
2517 | + | (arguments | |
2518 | + | `(#:jar-name "java-spring-framework-expression.jar" | |
2519 | + | #:jdk ,icedtea-8 | |
2520 | + | #:source-dir "src/main/java" | |
2521 | + | #:test-dir "src/test" | |
2522 | + | #:phases | |
2523 | + | (modify-phases %standard-phases | |
2524 | + | (add-before 'configure 'chdir | |
2525 | + | (lambda _ | |
2526 | + | ;; Needed because tests look for data in src/... directly. | |
2527 | + | (chdir "spring-expression") | |
2528 | + | #t)) | |
2529 | + | (add-before 'build 'copy-resources | |
2530 | + | (lambda _ | |
2531 | + | (copy-recursively "src/main/resources" "build/classes") | |
2532 | + | #t)) | |
2533 | + | (add-before 'check 'copy-test-classes | |
2534 | + | (lambda _ | |
2535 | + | (mkdir-p "src/test/java/org/springframework/tests") | |
2536 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/TestGroup.java" | |
2537 | + | "src/test/java/org/springframework/tests/TestGroup.java") | |
2538 | + | (copy-file "../spring-core/src/test/java/org/springframework/tests/Assume.java" | |
2539 | + | "src/test/java/org/springframework/tests/Assume.java") | |
2540 | + | #t)) | |
2541 | + | (add-before 'check 'copy-test-resources | |
2542 | + | (lambda* (#:key inputs #:allow-other-keys) | |
2543 | + | (copy-recursively "src/test/resources" | |
2544 | + | "build/test-classes") | |
2545 | + | #t))))) | |
2546 | + | (inputs | |
2547 | + | `(("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
2548 | + | ("java-spring-framework-core" ,java-spring-framework-core))) | |
2549 | + | (description ""))) | |
2550 | + | ||
2338 | 2551 | (define-public java-lucene-core | |
2339 | 2552 | (package | |
2340 | 2553 | (name "java-lucene-core") |
more/packages/maven.scm
606 | 606 | ("java-plexus-utils" ,java-plexus-utils) | |
607 | 607 | ("java-plexus-velocity-component" ,java-plexus-velocity-component) | |
608 | 608 | ("java-velocity" ,java-velocity) | |
609 | + | ("java-velocity-tools" ,java-velocity-tools) | |
609 | 610 | ("maven-artifact" ,maven-artifact) | |
610 | 611 | ("maven-doxia-core" ,maven-doxia-core) | |
611 | 612 | ("maven-doxia-decoration-model" ,maven-doxia-decoration-model) | |
… | |||
730 | 731 | `(("java-plexus-component-annotations" ,java-plexus-component-annotations) | |
731 | 732 | ("java-plexus-container-default" ,java-plexus-container-default) | |
732 | 733 | ("java-plexus-utils" ,java-plexus-utils) | |
733 | - | ("java-plexus-velocity-compontent" ,java-plexus-velocity-component) | |
734 | + | ("java-plexus-velocity-component" ,java-plexus-velocity-component) | |
734 | 735 | ("java-velocity" ,java-velocity) | |
735 | 736 | ("maven-artifact" ,maven-artifact) | |
736 | 737 | ("maven-compat" ,maven-compat) | |
737 | 738 | ("maven-core" ,maven-core) | |
738 | 739 | ("maven-doxia-sink-api" ,maven-doxia-sink-api) | |
740 | + | ("maven-doxia-site-renderer" ,maven-doxia-site-renderer) | |
739 | 741 | ("maven-doxia-core" ,maven-doxia-core) | |
740 | 742 | ("maven-model" ,maven-model) | |
741 | 743 | ("maven-reporting-api" ,maven-reporting-api) |