1 |
commit: 25d5ff0c15d1838b0789f673f170da227b2e2c66 |
2 |
Author: Patrice Clement <monsieurp <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Sep 30 17:53:16 2015 +0000 |
4 |
Commit: Patrice Clement <monsieurp <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Sep 30 17:53:33 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=25d5ff0c |
7 |
|
8 |
dev-java/commons-email: Initial commit. Imported from java-overlay. Fixes bug 223359. |
9 |
|
10 |
Signed-off-by: Patrice Clement <monsieurp <AT> gentoo.org> |
11 |
|
12 |
dev-java/commons-email/Manifest | 1 + |
13 |
dev-java/commons-email/commons-email-1.4.ebuild | 51 ++++ |
14 |
.../files/commons-email-1.4-build.xml | 261 +++++++++++++++++++++ |
15 |
dev-java/commons-email/metadata.xml | 8 + |
16 |
4 files changed, 321 insertions(+) |
17 |
|
18 |
diff --git a/dev-java/commons-email/Manifest b/dev-java/commons-email/Manifest |
19 |
new file mode 100644 |
20 |
index 0000000..0a878e5 |
21 |
--- /dev/null |
22 |
+++ b/dev-java/commons-email/Manifest |
23 |
@@ -0,0 +1 @@ |
24 |
+DIST commons-email-1.4-src.tar.gz 288876 SHA256 bf86115adc3e724c3e713102874d4ca686e7e6e34f9856438655be5a4c008cb0 SHA512 2a62256e284b9f4f428cf8544e46e81aa521476c41243df1c4f8a9e1bd4bcea3c768346aaab862b8c2a8b271c6012a38164c6d62867d2849a3ee0c2820fe422c WHIRLPOOL aaca35bd39e09020653af31b8147d1c323b80a7805199cb060327b0558c4ebbd86381a851edc06c63ed8bbc328a770d90e032c2edc302a6aca58b3624b6beab6 |
25 |
|
26 |
diff --git a/dev-java/commons-email/commons-email-1.4.ebuild b/dev-java/commons-email/commons-email-1.4.ebuild |
27 |
new file mode 100644 |
28 |
index 0000000..c4837bb |
29 |
--- /dev/null |
30 |
+++ b/dev-java/commons-email/commons-email-1.4.ebuild |
31 |
@@ -0,0 +1,51 @@ |
32 |
+# Copyright 1999-2015 Gentoo Foundation |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+# $Id$ |
35 |
+ |
36 |
+EAPI=5 |
37 |
+JAVA_PKG_IUSE="source doc test" |
38 |
+ |
39 |
+inherit java-pkg-2 java-ant-2 |
40 |
+ |
41 |
+DESCRIPTION="Commons Email aims to provide an API for sending email." |
42 |
+HOMEPAGE="http://commons.apache.org/email/" |
43 |
+SRC_URI="mirror://apache/commons/email/source/${P}-src.tar.gz" |
44 |
+LICENSE="Apache-2.0" |
45 |
+SLOT="0" |
46 |
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86" |
47 |
+ |
48 |
+# Requires a slew of packages we don't ship yet. |
49 |
+RESTRICT="test" |
50 |
+ |
51 |
+CDEPEND="dev-java/oracle-javamail:0" |
52 |
+ |
53 |
+RDEPEND=">=virtual/jre-1.6 |
54 |
+ ${CDEPEND}" |
55 |
+DEPEND=">=virtual/jdk-1.6 |
56 |
+ test? ( |
57 |
+ dev-java/ant-junit:0 |
58 |
+ ) |
59 |
+ ${CDEPEND}" |
60 |
+IUSE="" |
61 |
+ |
62 |
+S="${WORKDIR}/${P}-src" |
63 |
+ |
64 |
+JAVA_ANT_REWRITE_CLASSPATH="yes" |
65 |
+ |
66 |
+EANT_GENTOO_CLASSPATH="oracle-javamail" |
67 |
+EANT_BUILD_TARGET="package" |
68 |
+ |
69 |
+java_prepare() { |
70 |
+ cp "${FILESDIR}/${P}-build.xml" build.xml || die |
71 |
+} |
72 |
+ |
73 |
+src_test() { |
74 |
+ java-pkg-2_src_test |
75 |
+} |
76 |
+ |
77 |
+src_install() { |
78 |
+ java-pkg_newjar target/${P}.jar ${PN}.jar |
79 |
+ dodoc {NOTICE,README,RELEASE-NOTES}.txt || die |
80 |
+ use doc && java-pkg_dojavadoc target/site/apidocs |
81 |
+ use source && java-pkg_dosrc src/main/java |
82 |
+} |
83 |
|
84 |
diff --git a/dev-java/commons-email/files/commons-email-1.4-build.xml b/dev-java/commons-email/files/commons-email-1.4-build.xml |
85 |
new file mode 100644 |
86 |
index 0000000..9fb5f0e |
87 |
--- /dev/null |
88 |
+++ b/dev-java/commons-email/files/commons-email-1.4-build.xml |
89 |
@@ -0,0 +1,261 @@ |
90 |
+<?xml version="1.0" encoding="UTF-8"?> |
91 |
+ |
92 |
+<!-- ====================================================================== --> |
93 |
+<!-- Ant build file (http://ant.apache.org/) for Ant 1.6.2 or above. --> |
94 |
+<!-- ====================================================================== --> |
95 |
+ |
96 |
+<!-- ====================================================================== --> |
97 |
+<!-- ===================== - DO NOT EDIT THIS FILE! - ===================== --> |
98 |
+<!-- ====================================================================== --> |
99 |
+<!-- --> |
100 |
+<!-- Any modifications will be overwritten. --> |
101 |
+<!-- --> |
102 |
+<!-- Generated by Maven Ant Plugin on 9/29/15 9:53 PM --> |
103 |
+<!-- See: http://maven.apache.org/plugins/maven-ant-plugin/ --> |
104 |
+<!-- --> |
105 |
+<!-- ====================================================================== --> |
106 |
+ |
107 |
+<project name="commons-email-from-maven" default="package" basedir="."> |
108 |
+ |
109 |
+ <!-- ====================================================================== --> |
110 |
+ <!-- Build environment properties --> |
111 |
+ <!-- ====================================================================== --> |
112 |
+ |
113 |
+ <property file="${user.home}/.m2/maven.properties"/> |
114 |
+ <property file="maven-build.properties"/> |
115 |
+ |
116 |
+ <property name="maven.build.finalName" value="commons-email-1.4"/> |
117 |
+ <property name="maven.build.dir" value="target"/> |
118 |
+ <property name="maven.build.outputDir" value="${maven.build.dir}/classes"/> |
119 |
+ <property name="maven.build.srcDir.0" value="src/main/java"/> |
120 |
+ <property name="maven.build.resourceDir.0" value="src/main/resources"/> |
121 |
+ <property name="maven.build.resourceDir.1" value="."/> |
122 |
+ <property name="maven.build.testOutputDir" value="${maven.build.dir}/test-classes"/> |
123 |
+ <property name="maven.build.testDir.0" value="src/test/java"/> |
124 |
+ <property name="maven.build.testResourceDir.0" value="src/test/resources"/> |
125 |
+ <property name="maven.build.testResourceDir.1" value="."/> |
126 |
+ <property name="maven.test.reports" value="${maven.build.dir}/test-reports"/> |
127 |
+ <property name="maven.reporting.outputDirectory" value="${maven.build.dir}/site"/> |
128 |
+ |
129 |
+ <!-- ====================================================================== --> |
130 |
+ <!-- Defining classpaths --> |
131 |
+ <!-- ====================================================================== --> |
132 |
+ |
133 |
+ <path id="build.classpath"> |
134 |
+ </path> |
135 |
+ <path id="build.test.classpath"> |
136 |
+ </path> |
137 |
+ |
138 |
+ <!-- ====================================================================== --> |
139 |
+ <!-- Cleaning up target --> |
140 |
+ <!-- ====================================================================== --> |
141 |
+ |
142 |
+ <target name="clean" description="Clean the output directory"> |
143 |
+ <delete dir="${maven.build.dir}"/> |
144 |
+ </target> |
145 |
+ |
146 |
+ <!-- ====================================================================== --> |
147 |
+ <!-- Compilation target --> |
148 |
+ <!-- ====================================================================== --> |
149 |
+ |
150 |
+ <target name="compile" description="Compile the code"> |
151 |
+ <mkdir dir="${maven.build.outputDir}"/> |
152 |
+ <javac destdir="${maven.build.outputDir}" |
153 |
+ encoding="UTF-8" |
154 |
+ nowarn="false" |
155 |
+ debug="true" |
156 |
+ optimize="false" |
157 |
+ deprecation="true" |
158 |
+ target="1.6" |
159 |
+ verbose="false" |
160 |
+ fork="false" |
161 |
+ source="1.6"> |
162 |
+ <src> |
163 |
+ <pathelement location="${maven.build.srcDir.0}"/> |
164 |
+ </src> |
165 |
+ <classpath refid="build.classpath"/> |
166 |
+ </javac> |
167 |
+ <copy todir="${maven.build.outputDir}"> |
168 |
+ <fileset dir="${maven.build.resourceDir.0}"/> |
169 |
+ </copy> |
170 |
+ <mkdir dir="${maven.build.outputDir}/META-INF"/> |
171 |
+ <copy todir="${maven.build.outputDir}/META-INF"> |
172 |
+ <fileset dir="${maven.build.resourceDir.1}"> |
173 |
+ <include name="NOTICE.txt"/> |
174 |
+ <include name="LICENSE.txt"/> |
175 |
+ </fileset> |
176 |
+ </copy> |
177 |
+ </target> |
178 |
+ |
179 |
+ <!-- ====================================================================== --> |
180 |
+ <!-- Test-compilation target --> |
181 |
+ <!-- ====================================================================== --> |
182 |
+ |
183 |
+ <target name="compile-tests" |
184 |
+ depends="compile" |
185 |
+ description="Compile the test code" |
186 |
+ unless="maven.test.skip"> |
187 |
+ <mkdir dir="${maven.build.testOutputDir}"/> |
188 |
+ <javac destdir="${maven.build.testOutputDir}" |
189 |
+ encoding="UTF-8" |
190 |
+ nowarn="false" |
191 |
+ debug="true" |
192 |
+ optimize="false" |
193 |
+ deprecation="true" |
194 |
+ target="1.6" |
195 |
+ verbose="false" |
196 |
+ fork="false" |
197 |
+ source="1.6"> |
198 |
+ <src> |
199 |
+ <pathelement location="${maven.build.testDir.0}"/> |
200 |
+ </src> |
201 |
+ <classpath> |
202 |
+ <path refid="build.test.classpath"/> |
203 |
+ <pathelement location="${maven.build.outputDir}"/> |
204 |
+ </classpath> |
205 |
+ </javac> |
206 |
+ <copy todir="${maven.build.testOutputDir}"> |
207 |
+ <fileset dir="${maven.build.testResourceDir.0}"/> |
208 |
+ </copy> |
209 |
+ <mkdir dir="${maven.build.testOutputDir}/META-INF"/> |
210 |
+ <copy todir="${maven.build.testOutputDir}/META-INF"> |
211 |
+ <fileset dir="${maven.build.testResourceDir.1}"> |
212 |
+ <include name="NOTICE.txt"/> |
213 |
+ <include name="LICENSE.txt"/> |
214 |
+ </fileset> |
215 |
+ </copy> |
216 |
+ </target> |
217 |
+ |
218 |
+ <!-- ====================================================================== --> |
219 |
+ <!-- Run all tests --> |
220 |
+ <!-- ====================================================================== --> |
221 |
+ |
222 |
+ <target name="test" |
223 |
+ depends="compile-tests, junit-missing" |
224 |
+ unless="junit.skipped" |
225 |
+ description="Run the test cases"> |
226 |
+ <mkdir dir="${maven.test.reports}"/> |
227 |
+ <junit printSummary="yes" haltonerror="true" haltonfailure="true" fork="true" dir="."> |
228 |
+ <sysproperty key="basedir" value="."/> |
229 |
+ <formatter type="xml"/> |
230 |
+ <formatter type="plain" usefile="false"/> |
231 |
+ <classpath> |
232 |
+ <path refid="build.test.classpath"/> |
233 |
+ <pathelement location="${maven.build.outputDir}"/> |
234 |
+ <pathelement location="${maven.build.testOutputDir}"/> |
235 |
+ </classpath> |
236 |
+ <batchtest todir="${maven.test.reports}" unless="test"> |
237 |
+ <fileset dir="${maven.build.testDir.0}"> |
238 |
+ <include name="**/Test*.java"/> |
239 |
+ <include name="**/*Test.java"/> |
240 |
+ <include name="**/*TestCase.java"/> |
241 |
+ <exclude name="org/apache/commons/mail/mocks/*"/> |
242 |
+ <exclude name="org/apache/commons/mail/settings/*"/> |
243 |
+ <exclude name="**/Abstract*Test.java"/> |
244 |
+ </fileset> |
245 |
+ </batchtest> |
246 |
+ <batchtest todir="${maven.test.reports}" if="test"> |
247 |
+ <fileset dir="${maven.build.testDir.0}"> |
248 |
+ <include name="**/${test}.java"/> |
249 |
+ <exclude name="org/apache/commons/mail/mocks/*"/> |
250 |
+ <exclude name="org/apache/commons/mail/settings/*"/> |
251 |
+ <exclude name="**/Abstract*Test.java"/> |
252 |
+ </fileset> |
253 |
+ </batchtest> |
254 |
+ </junit> |
255 |
+ </target> |
256 |
+ |
257 |
+ <target name="test-junit-present"> |
258 |
+ <available classname="junit.framework.Test" property="junit.present" classpathref="build.test.classpath"/> |
259 |
+ </target> |
260 |
+ |
261 |
+ <target name="test-junit-status" |
262 |
+ depends="test-junit-present"> |
263 |
+ <condition property="junit.missing"> |
264 |
+ <and> |
265 |
+ <isfalse value="${junit.present}"/> |
266 |
+ <isfalse value="${maven.test.skip}"/> |
267 |
+ </and> |
268 |
+ </condition> |
269 |
+ <condition property="junit.skipped"> |
270 |
+ <or> |
271 |
+ <isfalse value="${junit.present}"/> |
272 |
+ <istrue value="${maven.test.skip}"/> |
273 |
+ </or> |
274 |
+ </condition> |
275 |
+ </target> |
276 |
+ |
277 |
+ <target name="junit-missing" |
278 |
+ depends="test-junit-status" |
279 |
+ if="junit.missing"> |
280 |
+ <echo>=================================== WARNING ===================================</echo> |
281 |
+ <echo> JUnit is not present in the test classpath or your $ANT_HOME/lib directory. Tests not executed.</echo> |
282 |
+ <echo>===============================================================================</echo> |
283 |
+ </target> |
284 |
+ |
285 |
+ <!-- ====================================================================== --> |
286 |
+ <!-- Javadoc target --> |
287 |
+ <!-- ====================================================================== --> |
288 |
+ |
289 |
+ <target name="javadoc" description="Generates the Javadoc of the application"> |
290 |
+ <javadoc sourcepath="${maven.build.srcDir.0}" |
291 |
+ packagenames="*" |
292 |
+ destdir="${maven.reporting.outputDirectory}/apidocs" |
293 |
+ access="protected" |
294 |
+ old="false" |
295 |
+ verbose="false" |
296 |
+ encoding="UTF-8" |
297 |
+ version="true" |
298 |
+ use="true" |
299 |
+ author="true" |
300 |
+ splitindex="false" |
301 |
+ nodeprecated="false" |
302 |
+ nodeprecatedlist="false" |
303 |
+ notree="false" |
304 |
+ noindex="false" |
305 |
+ nohelp="false" |
306 |
+ nonavbar="false" |
307 |
+ serialwarn="false" |
308 |
+ charset="ISO-8859-1" |
309 |
+ docencoding="UTF-8" |
310 |
+ source="1.6" |
311 |
+ linksource="true" |
312 |
+ breakiterator="false"> |
313 |
+ <link href="http://docs.oracle.com/javase/7/docs/api/"/> |
314 |
+ <link href="http://docs.oracle.com/javaee/6/api/"/> |
315 |
+ </javadoc> |
316 |
+ </target> |
317 |
+ |
318 |
+ <!-- ====================================================================== --> |
319 |
+ <!-- Package target --> |
320 |
+ <!-- ====================================================================== --> |
321 |
+ |
322 |
+ <target name="package" depends="compile,test" description="Package the application"> |
323 |
+ <jar jarfile="${maven.build.dir}/${maven.build.finalName}.jar" |
324 |
+ compress="true" |
325 |
+ index="false" |
326 |
+ basedir="${maven.build.outputDir}" |
327 |
+ excludes="**/package.html"> |
328 |
+ <manifest> |
329 |
+ <attribute name="Main-Class" value="Main"/> |
330 |
+ </manifest> |
331 |
+ </jar> |
332 |
+ </target> |
333 |
+ |
334 |
+ <!-- ====================================================================== --> |
335 |
+ <!-- A dummy target for the package named after the type it creates --> |
336 |
+ <!-- ====================================================================== --> |
337 |
+ |
338 |
+ <target name="jar" depends="package" description="Builds the jar for the application"/> |
339 |
+ |
340 |
+ <!-- ====================================================================== --> |
341 |
+ <!-- Download dependencies target --> |
342 |
+ <!-- ====================================================================== --> |
343 |
+ |
344 |
+ <target name="test-offline"> |
345 |
+ <condition property="maven.mode.offline"> |
346 |
+ <equals arg1="${maven.settings.offline}" arg2="true"/> |
347 |
+ </condition> |
348 |
+ </target> |
349 |
+ |
350 |
+</project> |
351 |
|
352 |
diff --git a/dev-java/commons-email/metadata.xml b/dev-java/commons-email/metadata.xml |
353 |
new file mode 100644 |
354 |
index 0000000..a620379 |
355 |
--- /dev/null |
356 |
+++ b/dev-java/commons-email/metadata.xml |
357 |
@@ -0,0 +1,8 @@ |
358 |
+<?xml version="1.0" encoding="UTF-8"?> |
359 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
360 |
+<pkgmetadata> |
361 |
+ <herd>java</herd> |
362 |
+<maintainer> |
363 |
+ <email>monsieurp@g.o</email> |
364 |
+</maintainer> |
365 |
+</pkgmetadata> |