Gentoo Archives: gentoo-commits

From: "Miroslav Šulc" <fordfrog@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-servers/tomcat/, www-servers/tomcat/files/
Date: Sun, 04 Feb 2018 09:32:28
Message-Id: 1517736731.a1e5f304f2d1565cf670ee352eb1a7397b88b51f.fordfrog@gentoo
1 commit: a1e5f304f2d1565cf670ee352eb1a7397b88b51f
2 Author: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
3 AuthorDate: Sun Feb 4 09:31:28 2018 +0000
4 Commit: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
5 CommitDate: Sun Feb 4 09:32:11 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a1e5f304
7
8 www-servers/tomcat: version bump for slots 7, 8 and 8.5
9
10 Package-Manager: Portage-2.3.24, Repoman-2.3.6
11
12 www-servers/tomcat/Manifest | 3 +
13 .../tomcat/files/tomcat-7.0.84-build.xml.patch | 161 +++++++++++++
14 .../tomcat/files/tomcat-8.0.49-build.xml.patch | 267 +++++++++++++++++++++
15 .../tomcat/files/tomcat-8.5.27-build.xml.patch | 258 ++++++++++++++++++++
16 www-servers/tomcat/tomcat-7.0.84.ebuild | 146 +++++++++++
17 www-servers/tomcat/tomcat-8.0.49.ebuild | 157 ++++++++++++
18 www-servers/tomcat/tomcat-8.5.27.ebuild | 157 ++++++++++++
19 7 files changed, 1149 insertions(+)
20
21 diff --git a/www-servers/tomcat/Manifest b/www-servers/tomcat/Manifest
22 index 98013508714..18f8fa8c5e0 100644
23 --- a/www-servers/tomcat/Manifest
24 +++ b/www-servers/tomcat/Manifest
25 @@ -1,6 +1,9 @@
26 DIST apache-tomcat-7.0.82-src.tar.gz 4697342 BLAKE2B 1106ed04dc83e64e395de29f01a7752a0578b0c88046eb59614a7cfc0d8a98e3aebb698c8eb56763eea41620d9b42482971c5093304184b1028c6bd8f9770ada SHA512 fc92388d81316de0246df4074c417ffa341eab55308c0694e9ea71c5497c863b42019cd1f38628ff640114c501a06c4e9c428cb2b6f1bc1c16fb337a286718db
27 +DIST apache-tomcat-7.0.84-src.tar.gz 4713409 BLAKE2B 3dc7766db1492413bbd3f878a2da7392dd4cfd1ca4c3e8a236e380cdfbc0c4ff075665d39871026e61f0bc88e0a84f372fbcef6914af9dc99e6dda05bafc6e48 SHA512 ca6b3f17f56a0b1befafd2efbfa07cbe094fb4ab022a3b5d704d249e551b44c6ef0d9691bd1b7c48ccda957efb43045209d11ca1a4aa0a7875e516e3a233cd74
28 DIST apache-tomcat-8.0.47-src.tar.gz 4996505 BLAKE2B 8024ec5248fed57bf1841a320fc23fa8a7a99b2352ea9635f3d4dc903bd363f3a15adc47f48250a4d732ab9c1724443bcb602b459b6ede2e7908051a5c3fdea5 SHA512 135de73b8ca7d4003fcecc19a17a8a86ab85fc1054e89638d26e57263249438d8e8aebfca0a2791eaec2bc835baa57e6a05b60e11595aa373fdc03e278b31702
29 DIST apache-tomcat-8.0.48-src.tar.gz 5009969 BLAKE2B 4b1db654d74b02f5fd589590197561496ecfb9b219e445fd18f2e967c78fb95f7fc71a21a6ed9ab5f8c6cee448b74a1729eb3627bcf1a59e2d2748c9c80cc76c SHA512 c56aaa7335c4ef221b2e5de7a7d4946ae1221127f977da5f46a97b062d909abc918b0e6ceb887d98ea5f5b38a26bbe9a3de481972492be593636f6f7e6ef7841
30 +DIST apache-tomcat-8.0.49-src.tar.gz 5017328 BLAKE2B a3494c73fc6b9ffecfe7b09380f9fb3a632e167861f876ac827848e6ae5fd41dc9d3f8a0da9d484edd87b88532de05809c8019941d3a2639e925066ff0a8cc87 SHA512 36ae75d37874430ea6b567d8415a9249f104b57afdd8689621f659f6a2c0b229f207e63cdcdfacb1eabd13af567295ff1335cb052abbefe46efdccc20f2d5a73
31 DIST apache-tomcat-8.5.23-src.tar.gz 5086043 BLAKE2B 9bcad0d465aff6da1ba4a846042491bc8d5963283ed1d2530a26ab48289d14e8b85834d24ca476c95a75c1a5f51ee3ecd71c190b9609983cce56b56bc046b6d3 SHA512 2848331553f2c1bc51a4113960c6fe7e2beddf9146341dbfde1a27e2232802cfc364c8e8b988ae862371ca1a3be34665a56a28be9eadf80f8b317e0e2525cbef
32 DIST apache-tomcat-8.5.24-src.tar.gz 5101516 BLAKE2B c19c46cca562f0c4c4733608ec007dd423f9a8ed0595bfb835554a7d08be06b791933e4beacbb0fe472589feae82f7d1a46934c0fb68930343cb2f4589bf6530 SHA512 f4ef9a66f2cafb3207c5a38c0f88efc1189e72f02fa88ef2a1b3626a03a57d0ba505b099f6185d747d5ab858aa3f8f3446ae60789312a900ec443eac45233efc
33 +DIST apache-tomcat-8.5.27-src.tar.gz 5123614 BLAKE2B 0051a7b5a9d3529a012338e0b12ed5fca218fc6740a0c576d3195a9c7848a78d93d0a6151541e314d82723de1b533b28024eeb231e33b21c38a2c4f702007415 SHA512 d3cac3d618283f0c26f861df67223fcb889da750f5e42563ec2ebc17d72169a7639d05d4d42fe403f4e49052962da09bc4b312b012c31309d8a096036baec8ab
34 DIST apache-tomcat-9.0.4-src.tar.gz 5073991 BLAKE2B 7efffbba395d78d5ab051dd2bdb7a1491cb04159421bec17deebcb901bbca5cfec67a651f8e1fcd9a394ba3e0650fc61e7da039f0f979ae60a87f477bc4bc3b8 SHA512 bb8777f6fff861a53381b15a4196053abd9cc01e080f0511032f69eb6f57f5c6ed0eafd8a94155f19a4654bce4fad39e0fcaa2e5473cb269bceeb46a2ea43557
35
36 diff --git a/www-servers/tomcat/files/tomcat-7.0.84-build.xml.patch b/www-servers/tomcat/files/tomcat-7.0.84-build.xml.patch
37 new file mode 100644
38 index 00000000000..aa40bd1564a
39 --- /dev/null
40 +++ b/www-servers/tomcat/files/tomcat-7.0.84-build.xml.patch
41 @@ -0,0 +1,161 @@
42 +diff --git a/build.xml b/build.xml
43 +index 3f1229c..13894ed 100644
44 +--- a/build.xml
45 ++++ b/build.xml
46 +@@ -671,12 +671,14 @@
47 + </fileset>
48 + </copy>
49 + <!-- Copy JSP Schemas and DTDs to be packed into servlet-api.jar -->
50 ++<!--
51 + <copy todir="${tomcat.classes}/javax/servlet/resources" encoding="ISO-8859-1">
52 + <fileset dir="${tomcat.classes}/javax/servlet/jsp/resources">
53 + <include name="*" />
54 + <exclude name="jspxml*" />
55 + </fileset>
56 + </copy>
57 ++-->
58 +
59 + </target>
60 +
61 +@@ -733,26 +735,32 @@
62 + manifest="${tomcat.manifests}/annotations-api.jar.manifest" />
63 +
64 + <!-- Servlet 3.0 Implementation JAR File -->
65 ++<!--
66 + <jarIt jarfile="${servlet-api.jar}"
67 + filesDir="${tomcat.classes}"
68 + filesId="files.servlet-api"
69 + manifest="${tomcat.manifests}/servlet-api.jar.manifest"
70 + notice="${tomcat.manifests}/servlet-api.jar.notice"
71 + license="${tomcat.manifests}/servlet-api.jar.license" />
72 ++-->
73 +
74 + <!-- JSP 2.2 Implementation JAR File -->
75 ++<!--
76 + <jarIt jarfile="${jsp-api.jar}"
77 + filesDir="${tomcat.classes}"
78 + filesId="files.jsp-api"
79 + manifest="${tomcat.manifests}/jsp-api.jar.manifest"
80 + notice="${tomcat.manifests}/jsp-api.jar.notice"
81 + license="${tomcat.manifests}/jsp-api.jar.license" />
82 ++-->
83 +
84 + <!-- JSP 2.2 EL Implementation JAR File -->
85 ++<!--
86 + <jarIt jarfile="${el-api.jar}"
87 + filesDir="${tomcat.classes}"
88 + filesId="files.el-api"
89 + manifest="${tomcat.manifests}/el-api.jar.manifest" />
90 ++-->
91 +
92 + <!-- Bootstrap JAR File -->
93 + <jarIt jarfile="${bootstrap.jar}"
94 +@@ -999,9 +1007,9 @@
95 +
96 + <target name="deploy" depends="package,build-docs,compile-webapp-examples"
97 + description="Default. Builds a working Tomcat instance">
98 +-
99 ++<!--
100 + <copy tofile="${tomcat.build}/bin/commons-daemon.jar" file="${commons-daemon.jar}" />
101 +-
102 ++-->
103 + <!-- Copy scripts -->
104 + <copy todir="${tomcat.build}/bin">
105 + <fileset dir="bin">
106 +@@ -1060,14 +1068,15 @@
107 + <exclude name="${jdt.jar.filename}"/>
108 + </fileset>
109 + </delete>
110 ++<!--
111 + <copy file="${jdt.jar}" todir="${tomcat.build}/lib"/>
112 +-
113 ++-->
114 + <!-- Add sources for examples -->
115 + <antcall target="examples-sources" />
116 +-
117 ++<!--
118 + <copy file="${tomcat-dbcp.jar}" todir="${tomcat.build}/lib"
119 + failonerror="false"/>
120 +-
121 ++-->
122 + <!-- build the jdbc-pool jar and source jar-->
123 + <echo message="Building Tomcat JDBC pool libraries"/>
124 + <ant antfile="${tomcat.jdbc.dir}/build.xml" dir="${tomcat.jdbc.dir}"
125 +@@ -1697,7 +1706,7 @@
126 +
127 + <target name="extras-webservices-prepare"
128 + depends="extras-prepare"
129 +- description="Prepare to build web services extras package">
130 ++ description="Prepare to build web services extras package" unless="noget">
131 +
132 + <antcall target="downloadfile">
133 + <param name="sourcefile" value="${jaxrpc-lib.loc}"/>
134 +@@ -1886,11 +1895,12 @@
135 + </copy>
136 +
137 + <!-- Source bundles for native components -->
138 ++<!--
139 + <copy tofile="${tomcat.dist}/bin/tomcat-native.tar.gz"
140 + file="${tomcat-native.tar.gz}" />
141 + <copy tofile="${tomcat.dist}/bin/commons-daemon-native.tar.gz"
142 + file="${commons-daemon.native.src.tgz}" />
143 +-
144 ++-->
145 + <!-- platform README files -->
146 + <echo append="false" file="${tomcat.dist}/bin/x64/README">
147 + Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
148 +@@ -1902,6 +1912,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
149 + description="Create the Tomcat javadoc" >
150 + <fail unless="java.7.home"
151 + message="The java.7.home property must be set for javadoc build"/>
152 ++<!--
153 + <javadoc packagenames="javax.servlet.*"
154 + excludepackagenames="javax.servlet.jsp.*"
155 + sourcepath="${tomcat.dist}/src/java"
156 +@@ -1966,6 +1977,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
157 + <path location="${ant.core.lib}"/>
158 + </classpath>
159 + </javadoc>
160 ++-->
161 + <javadoc packagenames="javax.websocket.*"
162 + sourcepath="${tomcat.dist}/src/java"
163 + destdir="${tomcat.dist}/webapps/docs/websocketapi"
164 +@@ -2006,9 +2018,11 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
165 + <path refid="tomcat.webservices.classpath"/>
166 + <path location="${ant.core.lib}"/>
167 + </classpath>
168 ++<!--
169 + <link href="../servletapi"/>
170 + <link href="../jspapi"/>
171 + <link href="../elapi"/>
172 ++-->
173 + <link href="../websocketapi"/>
174 + <link href="http://docs.oracle.com/javase/7/docs/api/"/>
175 + <link href="http://commons.apache.org/proper/commons-io/javadocs/api-release/"/>
176 +@@ -2632,7 +2646,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
177 + </target>
178 +
179 + <target name="download-compile"
180 +- description="Download (and build) components necessary to compile" >
181 ++ description="Download (and build) components necessary to compile" unless="noget">
182 +
183 + <!-- Download Commons Daemon -->
184 + <antcall target="downloadgz-2">
185 +@@ -2675,7 +2689,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
186 + </target>
187 +
188 + <target name="download-test-compile"
189 +- description="Download additional components for the tests" >
190 ++ description="Download additional components for the tests" unless="noget">
191 +
192 + <antcall target="downloadfile">
193 + <param name="sourcefile" value="${junit.loc}"/>
194 +@@ -2721,7 +2735,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
195 + </target>
196 +
197 + <target name="download-dist"
198 +- description="Download additional components for a distribution" >
199 ++ description="Download additional components for a distribution" unless="noget">
200 +
201 + <antcall target="downloadfile-2">
202 + <param name="sourcefile.1" value="${tomcat-native.loc.1}"/>
203
204 diff --git a/www-servers/tomcat/files/tomcat-8.0.49-build.xml.patch b/www-servers/tomcat/files/tomcat-8.0.49-build.xml.patch
205 new file mode 100644
206 index 00000000000..b7e0a283fe2
207 --- /dev/null
208 +++ b/www-servers/tomcat/files/tomcat-8.0.49-build.xml.patch
209 @@ -0,0 +1,267 @@
210 +diff --git a/build.xml b/build.xml
211 +index 3152712..9e09384 100644
212 +--- a/build.xml
213 ++++ b/build.xml
214 +@@ -718,24 +718,29 @@
215 + manifest="${tomcat.manifests}/annotations-api.jar.manifest" />
216 +
217 + <!-- Servlet 3.1 Implementation JAR File -->
218 ++<!--
219 + <jarIt jarfile="${servlet-api.jar}"
220 + filesDir="${tomcat.classes}"
221 + filesId="files.servlet-api"
222 + manifest="${tomcat.manifests}/servlet-api.jar.manifest"
223 + notice="${tomcat.manifests}/servlet-api.jar.notice"
224 + license="${tomcat.manifests}/servlet-api.jar.license" />
225 +-
226 ++-->
227 + <!-- JSP 2.3 Implementation JAR File -->
228 ++<!--
229 + <jarIt jarfile="${jsp-api.jar}"
230 + filesDir="${tomcat.classes}"
231 + filesId="files.jsp-api"
232 + manifest="${tomcat.manifests}/jsp-api.jar.manifest" />
233 ++-->
234 +
235 + <!-- EL 3.0 Implementation JAR File -->
236 ++<!--
237 + <jarIt jarfile="${el-api.jar}"
238 + filesDir="${tomcat.classes}"
239 + filesId="files.el-api"
240 + manifest="${tomcat.manifests}/el-api.jar.manifest" />
241 ++-->
242 +
243 + <!-- WebSocket 1.1 API JAR File -->
244 + <jarIt jarfile="${websocket-api.jar}"
245 +@@ -1005,9 +1010,9 @@
246 +
247 + <target name="deploy" depends="package,build-docs,build-tomcat-jdbc,compile-webapp-examples"
248 + description="Default. Builds a working Tomcat instance">
249 +-
250 ++<!--
251 + <copy tofile="${tomcat.build}/bin/commons-daemon.jar" file="${commons-daemon.jar}" />
252 +-
253 ++-->
254 + <!-- Copy scripts -->
255 + <copy todir="${tomcat.build}/bin">
256 + <fileset dir="bin">
257 +@@ -1067,7 +1072,7 @@
258 + <exclude name="${jdt.jar.filename}"/>
259 + </fileset>
260 + </delete>
261 +- <copy file="${jdt.jar}" todir="${tomcat.build}/lib"/>
262 ++<!-- <copy file="${jdt.jar}" todir="${tomcat.build}/lib"/> -->
263 +
264 + <!-- Add sources for examples -->
265 + <antcall target="examples-sources" />
266 +@@ -1101,7 +1106,7 @@
267 + </javac>
268 + </target>
269 +
270 +- <target name="build-tomcat-jdbc" depends="package">
271 ++ <target name="build-tomcat-jdbc" depends="package" unless="noget">
272 + <!-- build the jdbc-pool jar and source jar-->
273 + <echo message="Building Tomcat JDBC pool libraries"/>
274 + <ant antfile="${tomcat.jdbc.dir}/build.xml" dir="${tomcat.jdbc.dir}"
275 +@@ -1116,7 +1121,7 @@
276 + <copy file="${tomcat-jdbc.jar}" todir="${tomcat.build}/lib"/>
277 + </target>
278 +
279 +- <target name="build-tomcat-jdbc-src">
280 ++ <target name="build-tomcat-jdbc-src" unless="noget">
281 + <!-- build the jdbc-pool source jar-->
282 + <echo message="Building Tomcat JDBC pool src JAR"/>
283 + <ant antfile="${tomcat.jdbc.dir}/build.xml" dir="${tomcat.jdbc.dir}"
284 +@@ -1220,9 +1225,11 @@
285 +
286 + <copy file="${basedir}/LICENSE" todir="${tomcat.embed}" />
287 + <copy file="${basedir}/NOTICE" todir="${tomcat.embed}" />
288 ++<!--
289 + <copy file="${tomcat-dbcp.jar}" todir="${tomcat.embed}"
290 + failonerror="false"/>
291 + <copy file="${jdt.jar}" todir="${tomcat.embed}" />
292 ++-->
293 + <copy file="${annotations-api.jar}" todir="${tomcat.embed}" />
294 +
295 + <!-- Note the meta-inf below will work as long as there is only one JAR
296 +@@ -1615,7 +1622,7 @@
297 +
298 + <target name="extras-commons-logging-prepare"
299 + depends="extras-prepare"
300 +- description="Prepare to build web services extras package">
301 ++ description="Prepare to build web services extras package" unless="noget">
302 +
303 + <antcall target="downloadfile-2">
304 + <param name="sourcefile.1" value="${commons-logging-src.loc.1}"/>
305 +@@ -1754,7 +1761,7 @@
306 +
307 + <target name="extras-webservices-prepare"
308 + depends="extras-prepare"
309 +- description="Prepare to build web services extras package">
310 ++ description="Prepare to build web services extras package" unless="noget">
311 +
312 + <antcall target="downloadfile">
313 + <param name="sourcefile" value="${jaxrpc-lib.loc}"/>
314 +@@ -1941,11 +1948,12 @@
315 + </copy>
316 +
317 + <!-- Source bundles for native components -->
318 ++<!--
319 + <copy tofile="${tomcat.dist}/bin/tomcat-native.tar.gz"
320 + file="${tomcat-native.tar.gz}" />
321 + <copy tofile="${tomcat.dist}/bin/commons-daemon-native.tar.gz"
322 + file="${commons-daemon.native.src.tgz}" />
323 +-
324 ++-->
325 + <!-- platform README files -->
326 + <echo append="false" file="${tomcat.dist}/bin/x64/README">
327 + Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
328 +@@ -1955,6 +1963,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
329 +
330 + <target name="javadoc" depends="dist-source,extras-webservices-prepare"
331 + description="Create the Tomcat javadoc" >
332 ++<!--
333 + <javadoc packagenames="javax.servlet.*"
334 + excludepackagenames="javax.servlet.jsp.*"
335 + sourcepath="${tomcat.dist}/src/java"
336 +@@ -2016,6 +2025,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
337 + <path location="${ant.core.lib}"/>
338 + </classpath>
339 + </javadoc>
340 ++-->
341 + <javadoc packagenames="javax.websocket.*"
342 + sourcepath="${tomcat.dist}/src/java"
343 + destdir="${tomcat.dist}/webapps/docs/websocketapi"
344 +@@ -2054,9 +2064,11 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
345 + <path refid="tomcat.webservices.classpath"/>
346 + <path location="${ant.core.lib}"/>
347 + </classpath>
348 ++<!--
349 + <link href="../servletapi"/>
350 + <link href="../jspapi"/>
351 + <link href="../elapi"/>
352 ++-->
353 + <link href="../websocketapi"/>
354 + <link href="http://docs.oracle.com/javase/7/docs/api/"/>
355 + <link href="http://commons.apache.org/proper/commons-io/javadocs/api-release/"/>
356 +@@ -2791,7 +2803,7 @@ skip.installer property in build.properties" />
357 + </target>
358 +
359 + <target name="download-compile"
360 +- description="Download (and build) components necessary to compile" >
361 ++ description="Download (and build) components necessary to compile" unless="noget">
362 +
363 + <!-- Download Commons Daemon -->
364 + <antcall target="downloadgz-2">
365 +@@ -2811,7 +2823,7 @@ skip.installer property in build.properties" />
366 + </target>
367 +
368 + <target name="download-test-compile"
369 +- description="Download additional components for the tests" >
370 ++ description="Download additional components for the tests" unless="noget">
371 +
372 + <antcall target="downloadfile">
373 + <param name="sourcefile" value="${junit.loc}"/>
374 +@@ -2868,7 +2880,7 @@ skip.installer property in build.properties" />
375 + </target>
376 +
377 + <target name="download-dist"
378 +- description="Download additional components for a distribution" >
379 ++ description="Download additional components for a distribution" unless="noget">
380 +
381 + <antcall target="downloadfile-2">
382 + <param name="sourcefile.1" value="${tomcat-native.loc.1}"/>
383 +@@ -2908,18 +2920,18 @@ skip.installer property in build.properties" />
384 +
385 + <!-- =============== Utility Targets to support downloads ================ -->
386 +
387 +- <target name="setproxy" if="${proxy.use}">
388 ++ <target name="setproxy" if="${proxy.use}" unless="noget">
389 + <setproxy proxyhost="${proxy.host}" proxyport="${proxy.port}"
390 + proxyuser="${proxy.user}" proxypassword="${proxy.password}" />
391 + <echo message="Using ${proxy.host}:${proxy.port} to download ${sourcefile}"/>
392 + </target>
393 +
394 +- <target name="testexist">
395 ++ <target name="testexist" unless="noget">
396 + <echo message="Testing for ${destfile}"/>
397 + <available file="${destfile}" property="exist"/>
398 + </target>
399 +
400 +- <target name="downloadgz" unless="exist" depends="testexist,setproxy">
401 ++ <target name="downloadgz" unless="noget" depends="testexist,setproxy">
402 + <!-- Download and extract the package -->
403 + <local name="temp.file"/>
404 + <mkdir dir="${base.path}"/>
405 +@@ -2931,7 +2943,7 @@ skip.installer property in build.properties" />
406 + <delete file="${temp.file}.tar.gz"/>
407 + </target>
408 +
409 +- <target name="downloadgz-2" unless="exist" depends="testexist">
410 ++ <target name="downloadgz-2" unless="noget" depends="testexist">
411 + <!-- Download and extract the package from the two alternative locations -->
412 + <local name="temp.file"/>
413 + <mkdir dir="${base.path}"/>
414 +@@ -2950,7 +2962,7 @@ skip.installer property in build.properties" />
415 + <delete file="${temp.file}.tar.gz"/>
416 + </target>
417 +
418 +- <target name="downloadzip" unless="exist" depends="testexist,setproxy">
419 ++ <target name="downloadzip" unless="noget" depends="testexist,setproxy">
420 + <!-- Download and extract the package -->
421 + <local name="temp.file"/>
422 + <mkdir dir="${base.path}"/>
423 +@@ -2961,7 +2973,7 @@ skip.installer property in build.properties" />
424 + <delete file="${temp.file}"/>
425 + </target>
426 +
427 +- <target name="downloadzip-2" unless="exist" depends="testexist">
428 ++ <target name="downloadzip-2" unless="noget" depends="testexist">
429 + <!-- Download and extract the package from the two alternative locations -->
430 + <local name="temp.file"/>
431 + <mkdir dir="${base.path}"/>
432 +@@ -2979,7 +2991,7 @@ skip.installer property in build.properties" />
433 + <delete file="${temp.file}"/>
434 + </target>
435 +
436 +- <target name="downloadfile" unless="exist" depends="testexist,setproxy">
437 ++ <target name="downloadfile" unless="noget" depends="testexist,setproxy">
438 + <!-- Download the file -->
439 + <local name="temp.file"/>
440 + <mkdir dir="${base.path}"/>
441 +@@ -2989,7 +3001,7 @@ skip.installer property in build.properties" />
442 + <move file="${temp.file}" tofile="${destfile}"/>
443 + </target>
444 +
445 +- <target name="downloadfile-2" unless="exist" depends="testexist">
446 ++ <target name="downloadfile-2" unless="noget" depends="testexist">
447 + <!-- Download the file from the two alternative locations -->
448 + <local name="temp.file"/>
449 + <mkdir dir="${base.path}"/>
450 +@@ -3012,7 +3024,7 @@ skip.installer property in build.properties" />
451 + <move file="${temp.file}" tofile="${destfile}"/>
452 + </target>
453 +
454 +- <target name="trydownload.check" depends="setproxy">
455 ++ <target name="trydownload.check" depends="setproxy" unless="noget">
456 + <condition property="trydownload.run">
457 + <and>
458 + <not>
459 +@@ -3023,7 +3035,7 @@ skip.installer property in build.properties" />
460 + </condition>
461 + </target>
462 +
463 +- <target name="trydownload" if="trydownload.run" depends="trydownload.check">
464 ++ <target name="trydownload" if="trydownload.run" depends="trydownload.check" unless="noget">
465 + <!-- Downloads a file if not yet downloaded and the source URL is available -->
466 + <get src="${sourcefile}" httpusecaches="${trydownload.httpusecaches}" dest="${destfile}" />
467 + </target>
468 +@@ -3034,7 +3046,7 @@ skip.installer property in build.properties" />
469 +
470 + <target name="ide-eclipse"
471 + depends="download-compile, extras-webservices-prepare, download-test-compile"
472 +- description="Prepares the source tree to be built in Eclipse">
473 ++ description="Prepares the source tree to be built in Eclipse" unless="noget">
474 +
475 + <!-- Copy the sample project files into the root directory -->
476 + <copy file="${tomcat.home}/res/ide-support/eclipse/eclipse.project" tofile="${tomcat.home}/.project"/>
477
478 diff --git a/www-servers/tomcat/files/tomcat-8.5.27-build.xml.patch b/www-servers/tomcat/files/tomcat-8.5.27-build.xml.patch
479 new file mode 100644
480 index 00000000000..e08dd17c6cc
481 --- /dev/null
482 +++ b/www-servers/tomcat/files/tomcat-8.5.27-build.xml.patch
483 @@ -0,0 +1,258 @@
484 +diff --git a/build.xml b/build.xml
485 +index 2b3c7cf..b8e57e0 100644
486 +--- a/build.xml
487 ++++ b/build.xml
488 +@@ -717,24 +717,29 @@
489 + manifest="${tomcat.manifests}/annotations-api.jar.manifest" />
490 +
491 + <!-- Servlet 3.1 Implementation JAR File -->
492 ++<!--
493 + <jarIt jarfile="${servlet-api.jar}"
494 + filesDir="${tomcat.classes}"
495 + filesId="files.servlet-api"
496 + manifest="${tomcat.manifests}/servlet-api.jar.manifest"
497 + notice="${tomcat.manifests}/servlet-api.jar.notice"
498 + license="${tomcat.manifests}/servlet-api.jar.license" />
499 +-
500 ++-->
501 + <!-- JSP 2.3 Implementation JAR File -->
502 ++<!--
503 + <jarIt jarfile="${jsp-api.jar}"
504 + filesDir="${tomcat.classes}"
505 + filesId="files.jsp-api"
506 + manifest="${tomcat.manifests}/jsp-api.jar.manifest" />
507 ++-->
508 +
509 + <!-- EL 3.0 Implementation JAR File -->
510 ++<!--
511 + <jarIt jarfile="${el-api.jar}"
512 + filesDir="${tomcat.classes}"
513 + filesId="files.el-api"
514 + manifest="${tomcat.manifests}/el-api.jar.manifest" />
515 ++-->
516 +
517 + <!-- WebSocket 1.1 API JAR File -->
518 + <jarIt jarfile="${websocket-api.jar}"
519 +@@ -1010,9 +1015,9 @@
520 +
521 + <target name="deploy" depends="package,build-docs,build-tomcat-jdbc,compile-webapp-examples"
522 + description="Default. Builds a working Tomcat instance">
523 +-
524 ++<!--
525 + <copy tofile="${tomcat.build}/bin/commons-daemon.jar" file="${commons-daemon.jar}" />
526 +-
527 ++-->
528 + <!-- Copy scripts -->
529 + <copy todir="${tomcat.build}/bin">
530 + <fileset dir="bin">
531 +@@ -1072,7 +1077,7 @@
532 + <exclude name="${jdt.jar.filename}"/>
533 + </fileset>
534 + </delete>
535 +- <copy file="${jdt.jar}" todir="${tomcat.build}/lib"/>
536 ++<!-- <copy file="${jdt.jar}" todir="${tomcat.build}/lib"/> -->
537 +
538 + <!-- Add sources for examples -->
539 + <antcall target="examples-sources" />
540 +@@ -1106,7 +1111,7 @@
541 + </javac>
542 + </target>
543 +
544 +- <target name="build-tomcat-jdbc" depends="package">
545 ++ <target name="build-tomcat-jdbc" depends="package" unless="noget">
546 + <!-- build the jdbc-pool jar and source jar-->
547 + <echo message="Building Tomcat JDBC pool libraries"/>
548 + <ant antfile="${tomcat.jdbc.dir}/build.xml" dir="${tomcat.jdbc.dir}"
549 +@@ -1121,7 +1126,7 @@
550 + <copy file="${tomcat-jdbc.jar}" todir="${tomcat.build}/lib"/>
551 + </target>
552 +
553 +- <target name="build-tomcat-jdbc-src">
554 ++ <target name="build-tomcat-jdbc-src" unless="noget">
555 + <!-- build the jdbc-pool source jar-->
556 + <echo message="Building Tomcat JDBC pool src JAR"/>
557 + <ant antfile="${tomcat.jdbc.dir}/build.xml" dir="${tomcat.jdbc.dir}"
558 +@@ -1225,9 +1230,11 @@
559 +
560 + <copy file="${basedir}/LICENSE" todir="${tomcat.embed}" />
561 + <copy file="${basedir}/NOTICE" todir="${tomcat.embed}" />
562 ++<!--
563 + <copy file="${tomcat-dbcp.jar}" todir="${tomcat.embed}"
564 + failonerror="false"/>
565 + <copy file="${jdt.jar}" todir="${tomcat.embed}" />
566 ++-->
567 + <copy file="${annotations-api.jar}" todir="${tomcat.embed}" />
568 +
569 + <!-- Note the meta-inf below will work as long as there is only one JAR
570 +@@ -1610,7 +1617,7 @@
571 +
572 + <target name="extras-webservices-prepare"
573 + depends="extras-prepare"
574 +- description="Prepare to build web services extras package">
575 ++ description="Prepare to build web services extras package" unless="noget">
576 +
577 + <antcall target="downloadfile">
578 + <param name="sourcefile" value="${jaxrpc-lib.loc}"/>
579 +@@ -1750,11 +1757,12 @@
580 + </copy>
581 +
582 + <!-- Source bundles for native components -->
583 ++<!--
584 + <copy tofile="${tomcat.dist}/bin/tomcat-native.tar.gz"
585 + file="${tomcat-native.tar.gz}" />
586 + <copy tofile="${tomcat.dist}/bin/commons-daemon-native.tar.gz"
587 + file="${commons-daemon.native.src.tgz}" />
588 +-
589 ++-->
590 + <!-- platform README files -->
591 + <echo append="false" file="${tomcat.dist}/bin/x64/README">
592 + Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
593 +@@ -1764,6 +1772,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
594 +
595 + <target name="javadoc" depends="dist-source,extras-webservices-prepare"
596 + description="Create the Tomcat javadoc" >
597 ++<!--
598 + <javadoc packagenames="javax.servlet.*"
599 + excludepackagenames="javax.servlet.jsp.*"
600 + sourcepath="${tomcat.dist}/src/java"
601 +@@ -1828,6 +1837,7 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
602 + <path location="${ant.core.lib}"/>
603 + </classpath>
604 + </javadoc>
605 ++-->
606 + <javadoc packagenames="javax.websocket.*"
607 + sourcepath="${tomcat.dist}/src/java"
608 + destdir="${tomcat.dist}/webapps/docs/websocketapi"
609 +@@ -1868,9 +1878,11 @@ Apache Tomcat ${version} native binaries for Win64 AMD64/EMT64 platform.
610 + <path refid="tomcat.webservices.classpath"/>
611 + <path location="${ant.core.lib}"/>
612 + </classpath>
613 ++<!--
614 + <link href="../servletapi"/>
615 + <link href="../jspapi"/>
616 + <link href="../elapi"/>
617 ++-->
618 + <link href="../websocketapi"/>
619 + <link href="http://docs.oracle.com/javase/7/docs/api/"/>
620 + <link href="http://commons.apache.org/proper/commons-io/javadocs/api-release/"/>
621 +@@ -2617,7 +2629,7 @@ skip.installer property in build.properties" />
622 + </target>
623 +
624 + <target name="download-compile"
625 +- description="Download (and build) components necessary to compile" >
626 ++ description="Download (and build) components necessary to compile" unless="noget">
627 +
628 + <!-- Download Commons Daemon -->
629 + <antcall target="downloadgz-2">
630 +@@ -2637,7 +2649,7 @@ skip.installer property in build.properties" />
631 + </target>
632 +
633 + <target name="download-test-compile"
634 +- description="Download additional components for the tests" >
635 ++ description="Download additional components for the tests" unless="noget">
636 +
637 + <antcall target="downloadfile">
638 + <param name="sourcefile" value="${junit.loc}"/>
639 +@@ -2694,7 +2706,7 @@ skip.installer property in build.properties" />
640 + </target>
641 +
642 + <target name="download-dist"
643 +- description="Download additional components for a distribution" >
644 ++ description="Download additional components for a distribution" unless="noget">
645 +
646 + <antcall target="downloadfile-2">
647 + <param name="sourcefile.1" value="${tomcat-native.loc.1}"/>
648 +@@ -2734,18 +2746,18 @@ skip.installer property in build.properties" />
649 +
650 + <!-- =============== Utility Targets to support downloads ================ -->
651 +
652 +- <target name="setproxy" if="${proxy.use}">
653 ++ <target name="setproxy" if="${proxy.use}" unless="noget">
654 + <setproxy proxyhost="${proxy.host}" proxyport="${proxy.port}"
655 + proxyuser="${proxy.user}" proxypassword="${proxy.password}" />
656 + <echo message="Using ${proxy.host}:${proxy.port} to download ${sourcefile}"/>
657 + </target>
658 +
659 +- <target name="testexist">
660 ++ <target name="testexist" unless="noget">
661 + <echo message="Testing for ${destfile}"/>
662 + <available file="${destfile}" property="exist"/>
663 + </target>
664 +
665 +- <target name="downloadgz" unless="exist" depends="testexist,setproxy">
666 ++ <target name="downloadgz" unless="noget" depends="testexist,setproxy">
667 + <!-- Download and extract the package -->
668 + <local name="temp.file"/>
669 + <mkdir dir="${base.path}"/>
670 +@@ -2757,7 +2769,7 @@ skip.installer property in build.properties" />
671 + <delete file="${temp.file}.tar.gz"/>
672 + </target>
673 +
674 +- <target name="downloadgz-2" unless="exist" depends="testexist">
675 ++ <target name="downloadgz-2" unless="noget" depends="testexist">
676 + <!-- Download and extract the package from the two alternative locations -->
677 + <local name="temp.file"/>
678 + <mkdir dir="${base.path}"/>
679 +@@ -2776,7 +2788,7 @@ skip.installer property in build.properties" />
680 + <delete file="${temp.file}.tar.gz"/>
681 + </target>
682 +
683 +- <target name="downloadzip" unless="exist" depends="testexist,setproxy">
684 ++ <target name="downloadzip" unless="noget" depends="testexist,setproxy">
685 + <!-- Download and extract the package -->
686 + <local name="temp.file"/>
687 + <mkdir dir="${base.path}"/>
688 +@@ -2787,7 +2799,7 @@ skip.installer property in build.properties" />
689 + <delete file="${temp.file}"/>
690 + </target>
691 +
692 +- <target name="downloadzip-2" unless="exist" depends="testexist">
693 ++ <target name="downloadzip-2" unless="noget" depends="testexist">
694 + <!-- Download and extract the package from the two alternative locations -->
695 + <local name="temp.file"/>
696 + <mkdir dir="${base.path}"/>
697 +@@ -2805,7 +2817,7 @@ skip.installer property in build.properties" />
698 + <delete file="${temp.file}"/>
699 + </target>
700 +
701 +- <target name="downloadfile" unless="exist" depends="testexist,setproxy">
702 ++ <target name="downloadfile" unless="noget" depends="testexist,setproxy">
703 + <!-- Download the file -->
704 + <local name="temp.file"/>
705 + <mkdir dir="${base.path}"/>
706 +@@ -2815,7 +2827,7 @@ skip.installer property in build.properties" />
707 + <move file="${temp.file}" tofile="${destfile}"/>
708 + </target>
709 +
710 +- <target name="downloadfile-2" unless="exist" depends="testexist">
711 ++ <target name="downloadfile-2" unless="noget" depends="testexist">
712 + <!-- Download the file from the two alternative locations -->
713 + <local name="temp.file"/>
714 + <mkdir dir="${base.path}"/>
715 +@@ -2838,7 +2850,7 @@ skip.installer property in build.properties" />
716 + <move file="${temp.file}" tofile="${destfile}"/>
717 + </target>
718 +
719 +- <target name="trydownload.check" depends="setproxy">
720 ++ <target name="trydownload.check" depends="setproxy" unless="noget">
721 + <condition property="trydownload.run">
722 + <and>
723 + <not>
724 +@@ -2849,7 +2861,7 @@ skip.installer property in build.properties" />
725 + </condition>
726 + </target>
727 +
728 +- <target name="trydownload" if="trydownload.run" depends="trydownload.check">
729 ++ <target name="trydownload" if="trydownload.run" depends="trydownload.check" unless="noget">
730 + <!-- Downloads a file if not yet downloaded and the source URL is available -->
731 + <get src="${sourcefile}" httpusecaches="${trydownload.httpusecaches}" dest="${destfile}" />
732 + </target>
733 +@@ -2860,7 +2872,7 @@ skip.installer property in build.properties" />
734 +
735 + <target name="ide-eclipse"
736 + depends="download-compile, extras-webservices-prepare, download-test-compile"
737 +- description="Prepares the source tree to be built in Eclipse">
738 ++ description="Prepares the source tree to be built in Eclipse" unless="noget">
739 +
740 + <!-- Copy the sample project files into the root directory -->
741 + <copy file="${tomcat.home}/res/ide-support/eclipse/eclipse.project" tofile="${tomcat.home}/.project"/>
742
743 diff --git a/www-servers/tomcat/tomcat-7.0.84.ebuild b/www-servers/tomcat/tomcat-7.0.84.ebuild
744 new file mode 100644
745 index 00000000000..4ce5c4efd22
746 --- /dev/null
747 +++ b/www-servers/tomcat/tomcat-7.0.84.ebuild
748 @@ -0,0 +1,146 @@
749 +# Copyright 1999-2018 Gentoo Foundation
750 +# Distributed under the terms of the GNU General Public License v2
751 +
752 +EAPI=6
753 +
754 +JAVA_PKG_IUSE="doc source test"
755 +
756 +inherit eutils java-pkg-2 java-ant-2 prefix user
757 +
758 +MY_P="apache-${P}-src"
759 +
760 +DESCRIPTION="Tomcat Servlet-3.0/JSP-2.2 Container"
761 +HOMEPAGE="https://tomcat.apache.org/"
762 +SRC_URI="mirror://apache/${PN}/tomcat-7/v${PV}/src/${MY_P}.tar.gz"
763 +
764 +LICENSE="Apache-2.0"
765 +SLOT="7"
766 +KEYWORDS="~amd64 ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x86-solaris"
767 +IUSE="extra-webapps websockets"
768 +
769 +RESTRICT="test" # can we run them on a production system?
770 +
771 +ECJ_SLOT="4.5"
772 +SAPI_SLOT="3.0"
773 +
774 +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT}
775 + dev-java/tomcat-servlet-api:${SAPI_SLOT}"
776 +RDEPEND="${COMMON_DEP}
777 + virtual/jre
778 + !<dev-java/tomcat-native-1.1.24"
779 +DEPEND="${COMMON_DEP}
780 + virtual/jdk:1.8
781 + test? ( dev-java/ant-junit:0 )"
782 +
783 +S=${WORKDIR}/${MY_P}
784 +
785 +pkg_setup() {
786 + java-pkg-2_pkg_setup
787 + enewgroup tomcat 265
788 + enewuser tomcat 265 -1 /dev/null tomcat
789 +}
790 +
791 +src_prepare() {
792 + default
793 +
794 + # Remove bundled servlet-api
795 + rm -rv java/javax/{el,servlet} || die
796 +
797 + java-pkg_clean
798 +
799 + epatch "${FILESDIR}/${P}-build.xml.patch"
800 +
801 + # For use of catalina.sh in netbeans
802 + sed -i -e "/^# ----- Execute The Requested Command/ a\
803 + CLASSPATH=\`java-config --classpath ${PN}-${SLOT}\`" \
804 + bin/catalina.sh || die
805 +
806 + java-pkg-2_src_prepare
807 +}
808 +
809 +JAVA_ANT_REWRITE_CLASSPATH="true"
810 +
811 +EANT_BUILD_TARGET="deploy"
812 +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},tomcat-servlet-api-${SAPI_SLOT}"
813 +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes"
814 +EANT_NEEDS_TOOLS="true"
815 +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false"
816 +
817 +# revisions of the scripts
818 +IM_REV="-r1"
819 +INIT_REV="-r1"
820 +
821 +src_compile() {
822 + use websockets && EANT_EXTRA_ARGS+=" -Djava.7.home=${JAVA_HOME}"
823 + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar)"
824 + java-pkg-2_src_compile
825 +}
826 +
827 +src_test() {
828 + java-pkg-2_src_test
829 +}
830 +
831 +src_install() {
832 + local dest="/usr/share/${PN}-${SLOT}"
833 +
834 + java-pkg_jarinto "${dest}"/bin
835 + java-pkg_dojar output/build/bin/*.jar
836 + exeinto "${dest}"/bin
837 + doexe output/build/bin/*.sh
838 +
839 + java-pkg_jarinto "${dest}"/lib
840 + java-pkg_dojar output/build/lib/*.jar
841 +
842 + dodoc RELEASE-NOTES RUNNING.txt
843 + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api
844 + use source && java-pkg_dosrc java/*
845 +
846 + ### Webapps ###
847 +
848 + insinto "${dest}"/webapps
849 + doins -r output/build/webapps/{host-manager,manager,ROOT}
850 + use extra-webapps && doins -r output/build/webapps/{docs,examples}
851 +
852 + ### Config ###
853 +
854 + # create "logs" directory in $CATALINA_BASE
855 + # and set correct perms, see #458890
856 + dodir "${dest}"/logs
857 + fperms 0750 "${dest}"/logs
858 +
859 + # replace the default pw with a random one, see #92281
860 + local randpw=$(echo ${RANDOM}|md5sum|cut -c 1-15)
861 + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die
862 +
863 + # prepend gentoo.classpath to common.loader, see #453212
864 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die
865 +
866 + insinto "${dest}"
867 + doins -r output/build/conf
868 +
869 + ### rc ###
870 +
871 + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die
872 + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash}
873 + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die
874 +
875 + insinto "${dest}"/gentoo
876 + doins "${T}"/tomcat.conf
877 + exeinto "${dest}"/gentoo
878 + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init
879 + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash
880 +}
881 +
882 +pkg_postinst() {
883 + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version"
884 + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat."
885 + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat"
886 +
887 + elog "To manage Tomcat instances, run:"
888 + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help"
889 +
890 + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar"
891 + ewarn "from upstream binary if you need it. Gentoo Bug # 144276"
892 +
893 +# einfo "Please read https://www.gentoo.org/proj/en/java/tomcat6-guide.xml for more information."
894 +}
895
896 diff --git a/www-servers/tomcat/tomcat-8.0.49.ebuild b/www-servers/tomcat/tomcat-8.0.49.ebuild
897 new file mode 100644
898 index 00000000000..badb0b2ee12
899 --- /dev/null
900 +++ b/www-servers/tomcat/tomcat-8.0.49.ebuild
901 @@ -0,0 +1,157 @@
902 +# Copyright 1999-2018 Gentoo Foundation
903 +# Distributed under the terms of the GNU General Public License v2
904 +
905 +EAPI=6
906 +
907 +JAVA_PKG_IUSE="doc source test"
908 +
909 +inherit eutils java-pkg-2 java-ant-2 prefix user
910 +
911 +MY_P="apache-${P}-src"
912 +
913 +DESCRIPTION="Tomcat Servlet-3.1/JSP-2.3/EL-3.0/WebSocket-1.1 Container"
914 +HOMEPAGE="https://tomcat.apache.org/"
915 +SRC_URI="mirror://apache/${PN}/tomcat-8/v${PV}/src/${MY_P}.tar.gz"
916 +
917 +LICENSE="Apache-2.0"
918 +SLOT="8"
919 +KEYWORDS="~amd64 ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x86-solaris"
920 +IUSE="extra-webapps"
921 +
922 +RESTRICT="test" # can we run them on a production system?
923 +
924 +ECJ_SLOT="4.5"
925 +SAPI_SLOT="3.1"
926 +
927 +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT}
928 + dev-java/tomcat-servlet-api:${SAPI_SLOT}"
929 +RDEPEND="${COMMON_DEP}
930 + !<dev-java/tomcat-native-1.1.24
931 + >=virtual/jre-1.7"
932 +DEPEND="${COMMON_DEP}
933 + app-admin/pwgen
934 + >=virtual/jdk-1.7
935 + test? (
936 + >=dev-java/ant-junit-1.9:0
937 + dev-java/easymock:3.2
938 + )"
939 +
940 +S=${WORKDIR}/${MY_P}
941 +
942 +pkg_setup() {
943 + java-pkg-2_pkg_setup
944 + enewgroup tomcat 265
945 + enewuser tomcat 265 -1 /dev/null tomcat
946 +}
947 +
948 +src_prepare() {
949 + default
950 +
951 + find -name '*.jar' -type f -delete -print || die
952 +
953 + # Remove bundled servlet-api
954 + rm -rv java/javax/{el,servlet} || die
955 +
956 + epatch "${FILESDIR}/${P}-build.xml.patch"
957 +
958 + # For use of catalina.sh in netbeans
959 + sed -i -e "/^# ----- Execute The Requested Command/ a\
960 + CLASSPATH=\`java-config --classpath ${PN}-${SLOT}\`" \
961 + bin/catalina.sh || die
962 +
963 + java-pkg-2_src_prepare
964 +}
965 +
966 +JAVA_ANT_REWRITE_CLASSPATH="true"
967 +
968 +EANT_BUILD_TARGET="deploy"
969 +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},tomcat-servlet-api-${SAPI_SLOT}"
970 +EANT_TEST_GENTOO_CLASSPATH="easymock-3.2"
971 +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes"
972 +EANT_NEEDS_TOOLS="true"
973 +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false"
974 +
975 +# revisions of the scripts
976 +IM_REV="-r2"
977 +INIT_REV="-r1"
978 +
979 +src_compile() {
980 + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar)"
981 + java-pkg-2_src_compile
982 +}
983 +
984 +src_test() {
985 + java-pkg-2_src_test
986 +}
987 +
988 +src_install() {
989 + local dest="/usr/share/${PN}-${SLOT}"
990 +
991 + java-pkg_jarinto "${dest}"/bin
992 + java-pkg_dojar output/build/bin/*.jar
993 + exeinto "${dest}"/bin
994 + doexe output/build/bin/*.sh
995 +
996 + java-pkg_jarinto "${dest}"/lib
997 + java-pkg_dojar output/build/lib/*.jar
998 +
999 + dodoc RELEASE-NOTES RUNNING.txt
1000 + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api
1001 + use source && java-pkg_dosrc java/*
1002 +
1003 + ### Webapps ###
1004 +
1005 + # add missing docBase
1006 + local apps="host-manager manager"
1007 + for app in ${apps}; do
1008 + sed -i -e "s|=\"true\" >|=\"true\" docBase=\"\$\{catalina.home\}/webapps/${app}\" >|" \
1009 + output/build/webapps/${app}/META-INF/context.xml || die
1010 + done
1011 +
1012 + insinto "${dest}"/webapps
1013 + doins -r output/build/webapps/{host-manager,manager,ROOT}
1014 + use extra-webapps && doins -r output/build/webapps/{docs,examples}
1015 +
1016 + ### Config ###
1017 +
1018 + # create "logs" directory in $CATALINA_BASE
1019 + # and set correct perms, see #458890
1020 + dodir "${dest}"/logs
1021 + fperms 0750 "${dest}"/logs
1022 +
1023 + # replace the default pw with a random one, see #92281
1024 + local randpw="$(pwgen -s -B 15 1)"
1025 + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die
1026 +
1027 + # prepend gentoo.classpath to common.loader, see #453212
1028 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die
1029 +
1030 + insinto "${dest}"
1031 + doins -r output/build/conf
1032 +
1033 + ### rc ###
1034 +
1035 + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die
1036 + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash}
1037 + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die
1038 +
1039 + insinto "${dest}"/gentoo
1040 + doins "${T}"/tomcat.conf
1041 + exeinto "${dest}"/gentoo
1042 + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init
1043 + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash
1044 +}
1045 +
1046 +pkg_postinst() {
1047 + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version"
1048 + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat."
1049 + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat"
1050 +
1051 + elog "To manage Tomcat instances, run:"
1052 + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help"
1053 +
1054 + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar"
1055 + ewarn "from upstream binary if you need it. Gentoo Bug # 144276"
1056 +
1057 +# einfo "Please read https://www.gentoo.org/proj/en/java/tomcat6-guide.xml for more information."
1058 +}
1059
1060 diff --git a/www-servers/tomcat/tomcat-8.5.27.ebuild b/www-servers/tomcat/tomcat-8.5.27.ebuild
1061 new file mode 100644
1062 index 00000000000..17a74d0fb02
1063 --- /dev/null
1064 +++ b/www-servers/tomcat/tomcat-8.5.27.ebuild
1065 @@ -0,0 +1,157 @@
1066 +# Copyright 1999-2018 Gentoo Foundation
1067 +# Distributed under the terms of the GNU General Public License v2
1068 +
1069 +EAPI=6
1070 +
1071 +JAVA_PKG_IUSE="doc source test"
1072 +
1073 +inherit eutils java-pkg-2 java-ant-2 prefix user
1074 +
1075 +MY_P="apache-${P}-src"
1076 +
1077 +DESCRIPTION="Tomcat Servlet-3.1/JSP-2.3/EL-3.0/WebSocket-1.1/JASPIC-1.1 Container"
1078 +HOMEPAGE="https://tomcat.apache.org/"
1079 +SRC_URI="mirror://apache/${PN}/tomcat-8/v${PV}/src/${MY_P}.tar.gz"
1080 +
1081 +LICENSE="Apache-2.0"
1082 +SLOT="8.5"
1083 +KEYWORDS="~amd64 ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~x86-solaris"
1084 +IUSE="extra-webapps"
1085 +
1086 +RESTRICT="test" # can we run them on a production system?
1087 +
1088 +ECJ_SLOT="4.5"
1089 +SAPI_SLOT="3.1"
1090 +
1091 +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT}
1092 + >=dev-java/tomcat-servlet-api-${SLOT}:${SAPI_SLOT}"
1093 +RDEPEND="${COMMON_DEP}
1094 + !<dev-java/tomcat-native-1.1.24
1095 + >=virtual/jre-1.7"
1096 +DEPEND="${COMMON_DEP}
1097 + app-admin/pwgen
1098 + >=virtual/jdk-1.7
1099 + test? (
1100 + >=dev-java/ant-junit-1.9:0
1101 + dev-java/easymock:3.2
1102 + )"
1103 +
1104 +S=${WORKDIR}/${MY_P}
1105 +
1106 +pkg_setup() {
1107 + java-pkg-2_pkg_setup
1108 + enewgroup tomcat 265
1109 + enewuser tomcat 265 -1 /dev/null tomcat
1110 +}
1111 +
1112 +src_prepare() {
1113 + default
1114 +
1115 + find -name '*.jar' -type f -delete -print || die
1116 +
1117 + # Remove bundled servlet-api
1118 + rm -rv java/javax/{el,servlet} || die
1119 +
1120 + epatch "${FILESDIR}/${P}-build.xml.patch"
1121 +
1122 + # For use of catalina.sh in netbeans
1123 + sed -i -e "/^# ----- Execute The Requested Command/ a\
1124 + CLASSPATH=\`java-config --classpath ${PN}-${SLOT}\`" \
1125 + bin/catalina.sh || die
1126 +
1127 + java-pkg-2_src_prepare
1128 +}
1129 +
1130 +JAVA_ANT_REWRITE_CLASSPATH="true"
1131 +
1132 +EANT_BUILD_TARGET="deploy"
1133 +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},tomcat-servlet-api-${SAPI_SLOT}"
1134 +EANT_TEST_GENTOO_CLASSPATH="easymock-3.2"
1135 +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes"
1136 +EANT_NEEDS_TOOLS="true"
1137 +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false -Dexecute.validate=false"
1138 +
1139 +# revisions of the scripts
1140 +IM_REV="-r2"
1141 +INIT_REV="-r1"
1142 +
1143 +src_compile() {
1144 + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar)"
1145 + java-pkg-2_src_compile
1146 +}
1147 +
1148 +src_test() {
1149 + java-pkg-2_src_test
1150 +}
1151 +
1152 +src_install() {
1153 + local dest="/usr/share/${PN}-${SLOT}"
1154 +
1155 + java-pkg_jarinto "${dest}"/bin
1156 + java-pkg_dojar output/build/bin/*.jar
1157 + exeinto "${dest}"/bin
1158 + doexe output/build/bin/*.sh
1159 +
1160 + java-pkg_jarinto "${dest}"/lib
1161 + java-pkg_dojar output/build/lib/*.jar
1162 +
1163 + dodoc RELEASE-NOTES RUNNING.txt
1164 + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api
1165 + use source && java-pkg_dosrc java/*
1166 +
1167 + ### Webapps ###
1168 +
1169 + # add missing docBase
1170 + local apps="host-manager manager"
1171 + for app in ${apps}; do
1172 + sed -i -e "s|=\"true\" >|=\"true\" docBase=\"\$\{catalina.home\}/webapps/${app}\" >|" \
1173 + output/build/webapps/${app}/META-INF/context.xml || die
1174 + done
1175 +
1176 + insinto "${dest}"/webapps
1177 + doins -r output/build/webapps/{host-manager,manager,ROOT}
1178 + use extra-webapps && doins -r output/build/webapps/{docs,examples}
1179 +
1180 + ### Config ###
1181 +
1182 + # create "logs" directory in $CATALINA_BASE
1183 + # and set correct perms, see #458890
1184 + dodir "${dest}"/logs
1185 + fperms 0750 "${dest}"/logs
1186 +
1187 + # replace the default pw with a random one, see #92281
1188 + local randpw="$(pwgen -s -B 15 1)"
1189 + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die
1190 +
1191 + # prepend gentoo.classpath to common.loader, see #453212
1192 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die
1193 +
1194 + insinto "${dest}"
1195 + doins -r output/build/conf
1196 +
1197 + ### rc ###
1198 +
1199 + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die
1200 + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash}
1201 + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die
1202 +
1203 + insinto "${dest}"/gentoo
1204 + doins "${T}"/tomcat.conf
1205 + exeinto "${dest}"/gentoo
1206 + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init
1207 + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash
1208 +}
1209 +
1210 +pkg_postinst() {
1211 + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version"
1212 + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat."
1213 + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat"
1214 +
1215 + elog "To manage Tomcat instances, run:"
1216 + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help"
1217 +
1218 + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar"
1219 + ewarn "from upstream binary if you need it. Gentoo Bug # 144276"
1220 +
1221 +# einfo "Please read https://www.gentoo.org/proj/en/java/tomcat6-guide.xml for more information."
1222 +}