Add test dependencies
java-avalon-logkit-default-datasource.patch unknown status 1
1 | + | This patch is taken from gentoo (https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-java/avalon-logkit/files/avalon-logkit-2.1-java7.patch). | |
2 | + | ||
3 | + | It adds missing implementations of abstract methods. | |
4 | + | ||
5 | + | diff -Nur avalon-logkit-2.1/src/java/org/apache/log/output/db/DefaultDataSource.java avalon-logkit-2.1_patched//src/java/org/apache/log/output/db/DefaultDataSource.java | |
6 | + | --- avalon-logkit-2.1/src/java/org/apache/log/output/db/DefaultDataSource.java 2005-08-30 05:03:49.000000000 +0300 | |
7 | + | +++ avalon-logkit-2.1_patched//src/java/org/apache/log/output/db/DefaultDataSource.java 2011-09-27 08:27:49.313005212 +0300 | |
8 | + | @@ -20,7 +20,9 @@ | |
9 | + | import java.sql.Connection; | |
10 | + | import java.sql.DriverManager; | |
11 | + | import java.sql.SQLException; | |
12 | + | +import java.sql.SQLFeatureNotSupportedException; | |
13 | + | import javax.sql.DataSource; | |
14 | + | +import java.util.logging.Logger; | |
15 | + | ||
16 | + | /** | |
17 | + | * A basic datasource that doesn't do any pooling but just wraps | |
18 | + | @@ -111,4 +113,16 @@ | |
19 | + | { | |
20 | + | m_logWriter = logWriter; | |
21 | + | } | |
22 | + | + | |
23 | + | + public boolean isWrapperFor(Class cls) { | |
24 | + | + return false; | |
25 | + | + } | |
26 | + | + | |
27 | + | + public Object unwrap(Class cls) throws SQLException { | |
28 | + | + throw new SQLException("Not a wrapper for " + cls); | |
29 | + | + } | |
30 | + | + | |
31 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
32 | + | + throw new SQLFeatureNotSupportedException("Not a supported feature"); | |
33 | + | + } | |
34 | + | } | |
35 | + |
java-commons-dbcp-fix-abstract.patch unknown status 1
1 | + | From d233bf30337e3a48074839dd256bca000277c57d Mon Sep 17 00:00:00 2001 | |
2 | + | From: Julien Lepiller <julien@lepiller.eu> | |
3 | + | Date: Tue, 15 Aug 2017 22:55:38 +0200 | |
4 | + | Subject: [PATCH] Fix abstract methods | |
5 | + | ||
6 | + | --- | |
7 | + | .../org/apache/commons/dbcp/BasicDataSource.java | 7 +++ | |
8 | + | .../apache/commons/dbcp/DelegatingConnection.java | 59 ++++++++++++++++++ | |
9 | + | .../commons/dbcp/DelegatingDatabaseMetaData.java | 12 ++++ | |
10 | + | .../apache/commons/dbcp/DelegatingResultSet.java | 27 ++++++++ | |
11 | + | .../apache/commons/dbcp/DelegatingStatement.java | 21 +++++++ | |
12 | + | .../commons/dbcp/PoolableCallableStatement.java | 26 ++++++++ | |
13 | + | .../org/apache/commons/dbcp/PoolingConnection.java | 72 ++++++++++++++++++++++ | |
14 | + | .../org/apache/commons/dbcp/PoolingDataSource.java | 7 +++ | |
15 | + | .../org/apache/commons/dbcp/PoolingDriver.java | 7 +++ | |
16 | + | .../dbcp/cpdsadapter/DriverAdapterCPDS.java | 7 +++ | |
17 | + | .../dbcp/datasources/PerUserPoolDataSource.java | 7 +++ | |
18 | + | .../dbcp/datasources/SharedPoolDataSource.java | 7 +++ | |
19 | + | 12 files changed, 259 insertions(+) | |
20 | + | ||
21 | + | diff --git a/src/java/org/apache/commons/dbcp/BasicDataSource.java b/src/java/org/apache/commons/dbcp/BasicDataSource.java | |
22 | + | index 2688fd8..8fcf2d4 100644 | |
23 | + | --- a/src/java/org/apache/commons/dbcp/BasicDataSource.java | |
24 | + | +++ b/src/java/org/apache/commons/dbcp/BasicDataSource.java | |
25 | + | @@ -24,10 +24,12 @@ import java.util.List; | |
26 | + | import java.util.ArrayList; | |
27 | + | import java.util.Iterator; | |
28 | + | import java.util.Collections; | |
29 | + | +import java.util.logging.Logger; | |
30 | + | import java.sql.Connection; | |
31 | + | import java.sql.Driver; | |
32 | + | import java.sql.DriverManager; | |
33 | + | import java.sql.SQLException; | |
34 | + | +import java.sql.SQLFeatureNotSupportedException; | |
35 | + | import javax.sql.DataSource; | |
36 | + | ||
37 | + | import org.apache.commons.pool.KeyedObjectPoolFactory; | |
38 | + | @@ -1579,4 +1581,9 @@ public class BasicDataSource implements DataSource { | |
39 | + | logWriter.println(message); | |
40 | + | } | |
41 | + | } | |
42 | + | + | |
43 | + | + @Override | |
44 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
45 | + | + throw new SQLFeatureNotSupportedException(); | |
46 | + | + } | |
47 | + | } | |
48 | + | diff --git a/src/java/org/apache/commons/dbcp/DelegatingConnection.java b/src/java/org/apache/commons/dbcp/DelegatingConnection.java | |
49 | + | index 93cff0e..75f5c62 100644 | |
50 | + | --- a/src/java/org/apache/commons/dbcp/DelegatingConnection.java | |
51 | + | +++ b/src/java/org/apache/commons/dbcp/DelegatingConnection.java | |
52 | + | @@ -39,6 +39,7 @@ import java.sql.SQLXML; | |
53 | + | import java.sql.Struct; | |
54 | + | import java.util.Collections; | |
55 | + | import java.util.Properties; | |
56 | + | +import java.util.concurrent.Executor; | |
57 | + | /* JDBC_4_ANT_KEY_END */ | |
58 | + | ||
59 | + | /** | |
60 | + | @@ -679,4 +680,62 @@ public class DelegatingConnection extends AbandonedTrace | |
61 | + | } | |
62 | + | } | |
63 | + | /* JDBC_4_ANT_KEY_END */ | |
64 | + | + | |
65 | + | + @Override | |
66 | + | + public void setSchema(String schema) throws SQLException { | |
67 | + | + checkOpen(); | |
68 | + | + try { | |
69 | + | + _conn.setSchema(schema); | |
70 | + | + } | |
71 | + | + catch (SQLException e) { | |
72 | + | + handleException(e); | |
73 | + | + } | |
74 | + | + } | |
75 | + | + | |
76 | + | + @Override | |
77 | + | + public String getSchema() throws SQLException { | |
78 | + | + checkOpen(); | |
79 | + | + try { | |
80 | + | + return _conn.getSchema(); | |
81 | + | + } | |
82 | + | + catch (SQLException e) { | |
83 | + | + handleException(e); | |
84 | + | + return null; | |
85 | + | + } | |
86 | + | + } | |
87 | + | + | |
88 | + | + @Override | |
89 | + | + public void abort(Executor executor) throws SQLException { | |
90 | + | + checkOpen(); | |
91 | + | + try { | |
92 | + | + _conn.abort(executor); | |
93 | + | + } | |
94 | + | + catch (SQLException e) { | |
95 | + | + handleException(e); | |
96 | + | + } | |
97 | + | + } | |
98 | + | + | |
99 | + | + @Override | |
100 | + | + public void setNetworkTimeout(Executor executor, int milliseconds) | |
101 | + | + throws SQLException { | |
102 | + | + checkOpen(); | |
103 | + | + try { | |
104 | + | + _conn.setNetworkTimeout(executor, milliseconds); | |
105 | + | + } | |
106 | + | + catch (SQLException e) { | |
107 | + | + handleException(e); | |
108 | + | + } | |
109 | + | + } | |
110 | + | + | |
111 | + | + @Override | |
112 | + | + public int getNetworkTimeout() throws SQLException { | |
113 | + | + checkOpen(); | |
114 | + | + try { | |
115 | + | + return _conn.getNetworkTimeout(); | |
116 | + | + } | |
117 | + | + catch (SQLException e) { | |
118 | + | + handleException(e); | |
119 | + | + return 0; | |
120 | + | + } | |
121 | + | + } | |
122 | + | } | |
123 | + | diff --git a/src/java/org/apache/commons/dbcp/DelegatingDatabaseMetaData.java b/src/java/org/apache/commons/dbcp/DelegatingDatabaseMetaData.java | |
124 | + | index df88046..22ba48c 100644 | |
125 | + | --- a/src/java/org/apache/commons/dbcp/DelegatingDatabaseMetaData.java | |
126 | + | +++ b/src/java/org/apache/commons/dbcp/DelegatingDatabaseMetaData.java | |
127 | + | @@ -1208,4 +1208,16 @@ public class DelegatingDatabaseMetaData extends AbandonedTrace | |
128 | + | ||
129 | + | /* JDBC_4_ANT_KEY_END */ | |
130 | + | ||
131 | + | + @Override | |
132 | + | + public boolean generatedKeyAlwaysReturned() throws SQLException { | |
133 | + | + _conn.checkOpen(); | |
134 | + | + try { | |
135 | + | + return _meta.generatedKeyAlwaysReturned(); | |
136 | + | + } | |
137 | + | + catch (SQLException e) { | |
138 | + | + handleException(e); | |
139 | + | + return false; | |
140 | + | + } | |
141 | + | + } | |
142 | + | + | |
143 | + | } | |
144 | + | diff --git a/src/java/org/apache/commons/dbcp/DelegatingResultSet.java b/src/java/org/apache/commons/dbcp/DelegatingResultSet.java | |
145 | + | index f77328f..a0bd6bc 100644 | |
146 | + | --- a/src/java/org/apache/commons/dbcp/DelegatingResultSet.java | |
147 | + | +++ b/src/java/org/apache/commons/dbcp/DelegatingResultSet.java | |
148 | + | @@ -34,6 +34,7 @@ import java.sql.Ref; | |
149 | + | import java.sql.Blob; | |
150 | + | import java.sql.Clob; | |
151 | + | import java.sql.Array; | |
152 | + | +import java.sql.CallableStatement; | |
153 | + | import java.util.Calendar; | |
154 | + | /* JDBC_4_ANT_KEY_BEGIN */ | |
155 | + | import java.sql.NClob; | |
156 | + | @@ -1078,5 +1079,31 @@ public class DelegatingResultSet extends AbandonedTrace implements ResultSet { | |
157 | + | handleException(e); | |
158 | + | } | |
159 | + | } | |
160 | + | + | |
161 | + | + @Override | |
162 | + | + public <T> T getObject(int parameterIndex, Class<T> type) | |
163 | + | + throws SQLException { | |
164 | + | + checkOpen(); | |
165 | + | + try { | |
166 | + | + return ((CallableStatement)getDelegate()).getObject(parameterIndex, type); | |
167 | + | +} | |
168 | + | + catch (SQLException e) { | |
169 | + | + handleException(e); | |
170 | + | + return null; | |
171 | + | + } | |
172 | + | + } | |
173 | + | + | |
174 | + | + @Override | |
175 | + | + public <T> T getObject(String parameterName, Class<T> type) | |
176 | + | + throws SQLException { | |
177 | + | + checkOpen(); | |
178 | + | + try { | |
179 | + | + return ((CallableStatement)getDelegate()).getObject(parameterName, type); | |
180 | + | + } | |
181 | + | + catch (SQLException e) { | |
182 | + | + handleException(e); | |
183 | + | + return null; | |
184 | + | + } | |
185 | + | + } | |
186 | + | /* JDBC_4_ANT_KEY_END */ | |
187 | + | } | |
188 | + | diff --git a/src/java/org/apache/commons/dbcp/DelegatingStatement.java b/src/java/org/apache/commons/dbcp/DelegatingStatement.java | |
189 | + | index d944c6a..eb765ed 100644 | |
190 | + | --- a/src/java/org/apache/commons/dbcp/DelegatingStatement.java | |
191 | + | +++ b/src/java/org/apache/commons/dbcp/DelegatingStatement.java | |
192 | + | @@ -349,6 +349,27 @@ public class DelegatingStatement extends AbandonedTrace implements Statement { | |
193 | + | return _closed; | |
194 | + | } | |
195 | + | ||
196 | + | + @Override | |
197 | + | + public void closeOnCompletion() throws SQLException { | |
198 | + | + checkOpen(); | |
199 | + | + try { | |
200 | + | + _stmt.closeOnCompletion(); | |
201 | + | + } catch(SQLException e) { | |
202 | + | + handleException(e); | |
203 | + | + } | |
204 | + | + } | |
205 | + | + | |
206 | + | + @Override | |
207 | + | + public boolean isCloseOnCompletion() throws SQLException { | |
208 | + | + checkOpen(); | |
209 | + | + try { | |
210 | + | + _stmt.closeOnCompletion(); | |
211 | + | + } catch(SQLException e) { | |
212 | + | + handleException(e); | |
213 | + | + return false; | |
214 | + | + } | |
215 | + | + } | |
216 | + | + | |
217 | + | /* JDBC_4_ANT_KEY_BEGIN */ | |
218 | + | ||
219 | + | public boolean isWrapperFor(Class<?> iface) throws SQLException { | |
220 | + | diff --git a/src/java/org/apache/commons/dbcp/PoolableCallableStatement.java b/src/java/org/apache/commons/dbcp/PoolableCallableStatement.java | |
221 | + | index 108a7f5..1afadf1 100644 | |
222 | + | --- a/src/java/org/apache/commons/dbcp/PoolableCallableStatement.java | |
223 | + | +++ b/src/java/org/apache/commons/dbcp/PoolableCallableStatement.java | |
224 | + | @@ -123,4 +123,30 @@ public class PoolableCallableStatement extends DelegatingCallableStatement imple | |
225 | + | super.passivate(); | |
226 | + | } | |
227 | + | ||
228 | + | + @Override | |
229 | + | + public <T> T getObject(int parameterIndex, Class<T> type) | |
230 | + | + throws SQLException { | |
231 | + | + checkOpen(); | |
232 | + | + try { | |
233 | + | + return ((CallableStatement)getDelegate()).getObject(parameterIndex, type); | |
234 | + | +} | |
235 | + | + catch (SQLException e) { | |
236 | + | + handleException(e); | |
237 | + | + return null; | |
238 | + | + } | |
239 | + | + } | |
240 | + | + | |
241 | + | + @Override | |
242 | + | + public <T> T getObject(String parameterName, Class<T> type) | |
243 | + | + throws SQLException { | |
244 | + | + checkOpen(); | |
245 | + | + try { | |
246 | + | + return ((CallableStatement)getDelegate()).getObject(parameterName, type); | |
247 | + | + } | |
248 | + | + catch (SQLException e) { | |
249 | + | + handleException(e); | |
250 | + | + return null; | |
251 | + | + } | |
252 | + | + } | |
253 | + | + | |
254 | + | } | |
255 | + | diff --git a/src/java/org/apache/commons/dbcp/PoolingConnection.java b/src/java/org/apache/commons/dbcp/PoolingConnection.java | |
256 | + | index 04f4519..0d49d4a 100644 | |
257 | + | --- a/src/java/org/apache/commons/dbcp/PoolingConnection.java | |
258 | + | +++ b/src/java/org/apache/commons/dbcp/PoolingConnection.java | |
259 | + | @@ -26,6 +26,7 @@ import java.util.NoSuchElementException; | |
260 | + | ||
261 | + | import org.apache.commons.pool.KeyedObjectPool; | |
262 | + | import org.apache.commons.pool.KeyedPoolableObjectFactory; | |
263 | + | +import java.util.concurrent.Executor; | |
264 | + | ||
265 | + | /** | |
266 | + | * A {@link DelegatingConnection} that pools {@link PreparedStatement}s. | |
267 | + | @@ -455,4 +456,75 @@ public class PoolingConnection extends DelegatingConnection implements Connectio | |
268 | + | return buf.toString(); | |
269 | + | } | |
270 | + | } | |
271 | + | + | |
272 | + | + @Override | |
273 | + | + public String getClientInfo(String name) throws SQLException { | |
274 | + | + checkOpen(); | |
275 | + | + try { | |
276 | + | + return _conn.getClientInfo(name); | |
277 | + | + } | |
278 | + | + catch (SQLException e) { | |
279 | + | + handleException(e); | |
280 | + | + return null; | |
281 | + | + } | |
282 | + | + } | |
283 | + | + | |
284 | + | + @Override | |
285 | + | + public void setSchema(String schema) throws SQLException { | |
286 | + | + checkOpen(); | |
287 | + | + try { | |
288 | + | + _conn.setSchema(schema); | |
289 | + | + } | |
290 | + | + catch (SQLException e) { | |
291 | + | + handleException(e); | |
292 | + | + } | |
293 | + | + } | |
294 | + | + | |
295 | + | + @Override | |
296 | + | + public String getSchema() throws SQLException { | |
297 | + | + checkOpen(); | |
298 | + | + try { | |
299 | + | + return _conn.getSchema(); | |
300 | + | + } | |
301 | + | + catch (SQLException e) { | |
302 | + | + handleException(e); | |
303 | + | + return null; | |
304 | + | + } | |
305 | + | + } | |
306 | + | + | |
307 | + | + @Override | |
308 | + | + public void abort(Executor executor) throws SQLException { | |
309 | + | + checkOpen(); | |
310 | + | + try { | |
311 | + | + _conn.abort(executor); | |
312 | + | + } | |
313 | + | + catch (SQLException e) { | |
314 | + | + handleException(e); | |
315 | + | + } | |
316 | + | + } | |
317 | + | + | |
318 | + | + @Override | |
319 | + | + public void setNetworkTimeout(Executor executor, int milliseconds) | |
320 | + | + throws SQLException { | |
321 | + | + checkOpen(); | |
322 | + | + try { | |
323 | + | + _conn.setNetworkTimeout(executor, milliseconds); | |
324 | + | + } | |
325 | + | + catch (SQLException e) { | |
326 | + | + handleException(e); | |
327 | + | + } | |
328 | + | + } | |
329 | + | + | |
330 | + | + | |
331 | + | + @Override | |
332 | + | + public int getNetworkTimeout() throws SQLException { | |
333 | + | + checkOpen(); | |
334 | + | + try { | |
335 | + | + return _conn.getNetworkTimeout(); | |
336 | + | + } | |
337 | + | + catch (SQLException e) { | |
338 | + | + handleException(e); | |
339 | + | + return 0; | |
340 | + | + } | |
341 | + | + } | |
342 | + | } | |
343 | + | diff --git a/src/java/org/apache/commons/dbcp/PoolingDataSource.java b/src/java/org/apache/commons/dbcp/PoolingDataSource.java | |
344 | + | index 122a7e6..80381be 100644 | |
345 | + | --- a/src/java/org/apache/commons/dbcp/PoolingDataSource.java | |
346 | + | +++ b/src/java/org/apache/commons/dbcp/PoolingDataSource.java | |
347 | + | @@ -23,8 +23,10 @@ import java.sql.Connection; | |
348 | + | import java.sql.DatabaseMetaData; | |
349 | + | import java.sql.PreparedStatement; | |
350 | + | import java.sql.SQLException; | |
351 | + | +import java.sql.SQLFeatureNotSupportedException; | |
352 | + | import java.sql.SQLWarning; | |
353 | + | import java.sql.Statement; | |
354 | + | +import java.util.logging.Logger; | |
355 | + | import java.util.Map; | |
356 | + | import java.util.NoSuchElementException; | |
357 | + | ||
358 | + | @@ -167,6 +169,11 @@ public class PoolingDataSource implements DataSource { | |
359 | + | ||
360 | + | protected ObjectPool _pool = null; | |
361 | + | ||
362 | + | + @Override | |
363 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
364 | + | + throw new SQLFeatureNotSupportedException(); | |
365 | + | + } | |
366 | + | + | |
367 | + | /** | |
368 | + | * PoolGuardConnectionWrapper is a Connection wrapper that makes sure a | |
369 | + | * closed connection cannot be used anymore. | |
370 | + | diff --git a/src/java/org/apache/commons/dbcp/PoolingDriver.java b/src/java/org/apache/commons/dbcp/PoolingDriver.java | |
371 | + | index 4c82b02..b146d83 100644 | |
372 | + | --- a/src/java/org/apache/commons/dbcp/PoolingDriver.java | |
373 | + | +++ b/src/java/org/apache/commons/dbcp/PoolingDriver.java | |
374 | + | @@ -27,8 +27,10 @@ import java.sql.DriverManager; | |
375 | + | import java.sql.DriverPropertyInfo; | |
376 | + | import java.sql.PreparedStatement; | |
377 | + | import java.sql.SQLException; | |
378 | + | +import java.sql.SQLFeatureNotSupportedException; | |
379 | + | import java.sql.SQLWarning; | |
380 | + | import java.sql.Statement; | |
381 | + | +import java.util.logging.Logger; | |
382 | + | import java.util.HashMap; | |
383 | + | import java.util.Map; | |
384 | + | import java.util.NoSuchElementException; | |
385 | + | @@ -496,4 +498,9 @@ public class PoolingDriver implements Driver { | |
386 | + | } | |
387 | + | } | |
388 | + | } | |
389 | + | + | |
390 | + | + @Override | |
391 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
392 | + | + throw new SQLFeatureNotSupportedException(); | |
393 | + | + } | |
394 | + | } | |
395 | + | diff --git a/src/java/org/apache/commons/dbcp/cpdsadapter/DriverAdapterCPDS.java b/src/java/org/apache/commons/dbcp/cpdsadapter/DriverAdapterCPDS.java | |
396 | + | index 21087ed..0ff331e 100644 | |
397 | + | --- a/src/java/org/apache/commons/dbcp/cpdsadapter/DriverAdapterCPDS.java | |
398 | + | +++ b/src/java/org/apache/commons/dbcp/cpdsadapter/DriverAdapterCPDS.java | |
399 | + | @@ -19,10 +19,12 @@ package org.apache.commons.dbcp.cpdsadapter; | |
400 | + | ||
401 | + | import java.util.Hashtable; | |
402 | + | import java.util.Properties; | |
403 | + | +import java.util.logging.Logger; | |
404 | + | import java.io.PrintWriter; | |
405 | + | import java.io.Serializable; | |
406 | + | import java.sql.DriverManager; | |
407 | + | import java.sql.SQLException; | |
408 | + | +import java.sql.SQLFeatureNotSupportedException; | |
409 | + | import javax.sql.PooledConnection; | |
410 | + | import javax.sql.ConnectionPoolDataSource; | |
411 | + | import javax.naming.Name; | |
412 | + | @@ -719,4 +721,9 @@ public class DriverAdapterCPDS | |
413 | + | { | |
414 | + | _maxPreparedStatements = maxPreparedStatements; | |
415 | + | } | |
416 | + | + | |
417 | + | + @Override | |
418 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
419 | + | + throw new SQLFeatureNotSupportedException(); | |
420 | + | + } | |
421 | + | } | |
422 | + | diff --git a/src/java/org/apache/commons/dbcp/datasources/PerUserPoolDataSource.java b/src/java/org/apache/commons/dbcp/datasources/PerUserPoolDataSource.java | |
423 | + | index 9638953..9af4298 100644 | |
424 | + | --- a/src/java/org/apache/commons/dbcp/datasources/PerUserPoolDataSource.java | |
425 | + | +++ b/src/java/org/apache/commons/dbcp/datasources/PerUserPoolDataSource.java | |
426 | + | @@ -21,10 +21,12 @@ import java.io.IOException; | |
427 | + | import java.io.ObjectInputStream; | |
428 | + | import java.sql.Connection; | |
429 | + | import java.sql.SQLException; | |
430 | + | +import java.sql.SQLFeatureNotSupportedException; | |
431 | + | import java.util.HashMap; | |
432 | + | import java.util.Iterator; | |
433 | + | import java.util.Map; | |
434 | + | import java.util.NoSuchElementException; | |
435 | + | +import java.util.logging.Logger; | |
436 | + | ||
437 | + | import javax.naming.NamingException; | |
438 | + | import javax.naming.Reference; | |
439 | + | @@ -561,4 +563,9 @@ public class PerUserPoolDataSource | |
440 | + | CPDSConnectionFactory mgr = (CPDSConnectionFactory) managers.get(key); | |
441 | + | return mgr == null ? null : (GenericObjectPool) mgr.getPool(); | |
442 | + | } | |
443 | + | + | |
444 | + | + @Override | |
445 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
446 | + | + throw new SQLFeatureNotSupportedException(); | |
447 | + | + } | |
448 | + | } | |
449 | + | diff --git a/src/java/org/apache/commons/dbcp/datasources/SharedPoolDataSource.java b/src/java/org/apache/commons/dbcp/datasources/SharedPoolDataSource.java | |
450 | + | index e4bd04e..48c6d93 100644 | |
451 | + | --- a/src/java/org/apache/commons/dbcp/datasources/SharedPoolDataSource.java | |
452 | + | +++ b/src/java/org/apache/commons/dbcp/datasources/SharedPoolDataSource.java | |
453 | + | @@ -21,6 +21,8 @@ import java.io.IOException; | |
454 | + | import java.io.ObjectInputStream; | |
455 | + | import java.sql.Connection; | |
456 | + | import java.sql.SQLException; | |
457 | + | +import java.sql.SQLFeatureNotSupportedException; | |
458 | + | +import java.util.logging.Logger; | |
459 | + | ||
460 | + | import javax.naming.NamingException; | |
461 | + | import javax.naming.Reference; | |
462 | + | @@ -269,5 +271,10 @@ public class SharedPoolDataSource | |
463 | + | throw new IOException("NamingException: " + e); | |
464 | + | } | |
465 | + | } | |
466 | + | + | |
467 | + | + @Override | |
468 | + | + public Logger getParentLogger() throws SQLFeatureNotSupportedException { | |
469 | + | + throw new SQLFeatureNotSupportedException(); | |
470 | + | + } | |
471 | + | } | |
472 | + | ||
473 | + | -- | |
474 | + | 2.13.4 | |
475 | + |
java-powermock-fix-java-files.patch unknown status 1
1 | + | From 1ac84b58b4383fa118d98c35956d722d11cf449e Mon Sep 17 00:00:00 2001 | |
2 | + | From: Julien Lepiller <julien@lepiller.eu> | |
3 | + | Date: Tue, 22 Aug 2017 20:40:27 +0200 | |
4 | + | Subject: [PATCH] Fix java files. | |
5 | + | ||
6 | + | --- | |
7 | + | .../internal/impl/DelegatingPowerMockRunner.java | 13 +++++++--- | |
8 | + | .../java/org/powermock/reflect/WhiteBoxTest.java | 30 +++++++++++----------- | |
9 | + | .../reflect/internal/proxy/ClassFactory.java | 6 ++--- | |
10 | + | 3 files changed, 27 insertions(+), 22 deletions(-) | |
11 | + | ||
12 | + | diff --git a/powermock-modules/powermock-module-junit4/src/main/java/org/powermock/modules/junit4/internal/impl/DelegatingPowerMockRunner.java b/powermock-modules/powermock-module-junit4/src/main/java/org/powermock/modules/junit4/internal/impl/DelegatingPowerMockRunner.java | |
13 | + | index 301f854..caecbbd 100644 | |
14 | + | --- a/powermock-modules/powermock-module-junit4/src/main/java/org/powermock/modules/junit4/internal/impl/DelegatingPowerMockRunner.java | |
15 | + | +++ b/powermock-modules/powermock-module-junit4/src/main/java/org/powermock/modules/junit4/internal/impl/DelegatingPowerMockRunner.java | |
16 | + | @@ -98,12 +98,17 @@ implements PowerMockJUnitRunnerDelegate, Filterable { | |
17 | + | @Override | |
18 | + | public Runner call() throws Exception { | |
19 | + | try { | |
20 | + | - return Whitebox.invokeConstructor( | |
21 | + | - testClass.isAnnotationPresent(PowerMockRunnerDelegate.class) | |
22 | + | - ? testClass.getAnnotation(PowerMockRunnerDelegate.class).value() | |
23 | + | - : PowerMockRunnerDelegate.DefaultJUnitRunner.class, | |
24 | + | + if(testClass.isAnnotationPresent(PowerMockRunnerDelegate.class)) { | |
25 | + | + return Whitebox.invokeConstructor( | |
26 | + | + testClass.getAnnotation(PowerMockRunnerDelegate.class).value(), | |
27 | + | new Class[] {Class.class}, | |
28 | + | new Object[] {testClass}); | |
29 | + | + } else { | |
30 | + | + return Whitebox.invokeConstructor( | |
31 | + | + PowerMockRunnerDelegate.DefaultJUnitRunner.class, | |
32 | + | + new Class[] {Class.class}, | |
33 | + | + new Object[] {testClass}); | |
34 | + | + } | |
35 | + | } catch (ConstructorNotFoundException rootProblem) { | |
36 | + | if (testClass.isAnnotationPresent(PowerMockRunnerDelegate.class) | |
37 | + | && JUnitVersion.isGreaterThanOrEqualTo("4.5")) { | |
38 | + | diff --git a/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java b/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
39 | + | index bf1e2e3..0d60487 100644 | |
40 | + | --- a/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
41 | + | +++ b/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
42 | + | @@ -248,7 +248,7 @@ public class WhiteBoxTest { | |
43 | + | ||
44 | + | @Test | |
45 | + | public void testMethodWithPrimitiveAndWrappedInt_primtive_wrapped() throws Exception { | |
46 | + | - assertEquals(17, Whitebox.invokeMethod(new ClassWithPrivateMethods(), "methodWithPrimitiveAndWrappedInt", | |
47 | + | + assertEquals((Integer)17, Whitebox.invokeMethod(new ClassWithPrivateMethods(), "methodWithPrimitiveAndWrappedInt", | |
48 | + | new Class[]{int.class, Integer.class}, 9, Integer.valueOf(8))); | |
49 | + | } | |
50 | + | ||
51 | + | @@ -257,7 +257,7 @@ public class WhiteBoxTest { | |
52 | + | int expected = 123; | |
53 | + | Whitebox.setInternalState(ClassWithInternalState.class, "staticState", expected); | |
54 | + | assertEquals(expected, ClassWithInternalState.getStaticState()); | |
55 | + | - assertEquals(expected, Whitebox.getInternalState(ClassWithInternalState.class, "staticState")); | |
56 | + | + assertEquals(expected, (int)Whitebox.getInternalState(ClassWithInternalState.class, "staticState")); | |
57 | + | } | |
58 | + | ||
59 | + | @Test | |
60 | + | @@ -334,25 +334,25 @@ public class WhiteBoxTest { | |
61 | + | @Test | |
62 | + | public void testInvokeVarArgsMethod_multipleValues() throws Exception { | |
63 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
64 | + | - assertEquals(6, Whitebox.invokeMethod(tested, "varArgsMethod", 1, 2, 3)); | |
65 | + | + assertEquals(6, (int)Whitebox.invokeMethod(tested, "varArgsMethod", 1, 2, 3)); | |
66 | + | } | |
67 | + | ||
68 | + | @Test | |
69 | + | public void testInvokeVarArgsMethod_noArguments() throws Exception { | |
70 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
71 | + | - assertEquals(0, Whitebox.invokeMethod(tested, "varArgsMethod")); | |
72 | + | + assertEquals(0, (int)Whitebox.invokeMethod(tested, "varArgsMethod")); | |
73 | + | } | |
74 | + | ||
75 | + | @Test | |
76 | + | public void testInvokeVarArgsMethod_oneArgument() throws Exception { | |
77 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
78 | + | - assertEquals(4, Whitebox.invokeMethod(tested, "varArgsMethod", 2)); | |
79 | + | + assertEquals(4, (int)Whitebox.invokeMethod(tested, "varArgsMethod", 2)); | |
80 | + | } | |
81 | + | ||
82 | + | @Test | |
83 | + | public void testInvokeVarArgsMethod_invokeVarArgsWithOneArgument() throws Exception { | |
84 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
85 | + | - assertEquals(1, Whitebox.invokeMethod(tested, "varArgsMethod", new Class<?>[]{int[].class}, 1)); | |
86 | + | + assertEquals(1, (int)Whitebox.invokeMethod(tested, "varArgsMethod", new Class<?>[]{int[].class}, 1)); | |
87 | + | } | |
88 | + | ||
89 | + | @Test | |
90 | + | @@ -376,7 +376,7 @@ public class WhiteBoxTest { | |
91 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
92 | + | }; | |
93 | + | Whitebox.setInternalState(tested, fieldName, value); | |
94 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
95 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
96 | + | } | |
97 | + | ||
98 | + | @Test | |
99 | + | @@ -387,8 +387,8 @@ public class WhiteBoxTest { | |
100 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
101 | + | }; | |
102 | + | Whitebox.setInternalState(tested, fieldName, value); | |
103 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
104 | + | - assertEquals(-1, Whitebox.getInternalState(tested, fieldName, ClassWithInternalState.class)); | |
105 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
106 | + | + assertEquals(-1, (int)Whitebox.getInternalState(tested, fieldName, ClassWithInternalState.class)); | |
107 | + | } | |
108 | + | ||
109 | + | @Test(expected = IllegalArgumentException.class) | |
110 | + | @@ -398,7 +398,7 @@ public class WhiteBoxTest { | |
111 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
112 | + | }; | |
113 | + | Whitebox.setInternalState(tested, fieldName, new Object()); | |
114 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
115 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
116 | + | } | |
117 | + | ||
118 | + | @Test(expected = IllegalArgumentException.class) | |
119 | + | @@ -408,7 +408,7 @@ public class WhiteBoxTest { | |
120 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
121 | + | }; | |
122 | + | Whitebox.setInternalState(tested, fieldName, (Object) null); | |
123 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
124 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
125 | + | } | |
126 | + | ||
127 | + | @Test | |
128 | + | @@ -417,8 +417,8 @@ public class WhiteBoxTest { | |
129 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState(); | |
130 | + | Whitebox.setInternalState(tested, int.class, value); | |
131 | + | assertEquals(value, (int) Whitebox.getInternalState(tested, int.class)); | |
132 | + | - assertEquals(value, Whitebox.getInternalState(tested, "anotherInternalState")); | |
133 | + | - assertEquals(value, Whitebox.getInternalState(tested, "anotherInternalState", | |
134 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "anotherInternalState")); | |
135 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "anotherInternalState", | |
136 | + | ClassWithChildThatHasInternalState.class)); | |
137 | + | } | |
138 | + | ||
139 | + | @@ -429,7 +429,7 @@ public class WhiteBoxTest { | |
140 | + | Whitebox.setInternalState(tested, int.class, value, ClassWithInternalState.class); | |
141 | + | assertEquals(42, (int) Whitebox.getInternalState(tested, int.class)); | |
142 | + | assertEquals(value, (int) Whitebox.getInternalState(tested, int.class, ClassWithInternalState.class)); | |
143 | + | - assertEquals(value, Whitebox.getInternalState(tested, "staticState", ClassWithInternalState.class)); | |
144 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "staticState", ClassWithInternalState.class)); | |
145 | + | } | |
146 | + | ||
147 | + | @Test | |
148 | + | @@ -619,7 +619,7 @@ public class WhiteBoxTest { | |
149 | + | @Test | |
150 | + | public void testInvokeMethodWithBothNormalAndVarArgsParameter() throws Exception { | |
151 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
152 | + | - assertEquals(4, Whitebox.invokeMethod(tested, "varArgsMethod2", 1, 2, 3)); | |
153 | + | + assertEquals(4, (int)Whitebox.invokeMethod(tested, "varArgsMethod2", 1, 2, 3)); | |
154 | + | } | |
155 | + | ||
156 | + | @Test | |
157 | + | diff --git a/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java b/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
158 | + | index a5e5fda..14b8bbe 100644 | |
159 | + | --- a/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
160 | + | +++ b/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
161 | + | @@ -1,8 +1,8 @@ | |
162 | + | package org.powermock.reflect.internal.proxy; | |
163 | + | ||
164 | + | -import net.sf.cglib.asm.ClassWriter; | |
165 | + | -import net.sf.cglib.asm.MethodVisitor; | |
166 | + | -import net.sf.cglib.asm.Opcodes; | |
167 | + | +import org.objectweb.asm.ClassWriter; | |
168 | + | +import org.objectweb.asm.MethodVisitor; | |
169 | + | +import org.objectweb.asm.Opcodes; | |
170 | + | ||
171 | + | class ClassFactory implements Opcodes { | |
172 | + | ||
173 | + | -- | |
174 | + | 2.14.1 | |
175 | + |
java-powermock-fix-tests.patch unknown status 1
1 | + | From 09f037e0fbb55e9a1f3762c64cad4bf72d14d971 Mon Sep 17 00:00:00 2001 | |
2 | + | From: Julien Lepiller <julien@lepiller.eu> | |
3 | + | Date: Tue, 22 Aug 2017 20:40:27 +0200 | |
4 | + | Subject: [PATCH] Fix tests. | |
5 | + | ||
6 | + | --- | |
7 | + | .../java/org/powermock/reflect/WhiteBoxTest.java | 30 +++++++++++----------- | |
8 | + | .../reflect/internal/proxy/ClassFactory.java | 6 ++--- | |
9 | + | 2 files changed, 18 insertions(+), 18 deletions(-) | |
10 | + | ||
11 | + | diff --git a/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java b/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
12 | + | index bf1e2e3..0d60487 100644 | |
13 | + | --- a/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
14 | + | +++ b/powermock-reflect/src/test/java/org/powermock/reflect/WhiteBoxTest.java | |
15 | + | @@ -248,7 +248,7 @@ public class WhiteBoxTest { | |
16 | + | ||
17 | + | @Test | |
18 | + | public void testMethodWithPrimitiveAndWrappedInt_primtive_wrapped() throws Exception { | |
19 | + | - assertEquals(17, Whitebox.invokeMethod(new ClassWithPrivateMethods(), "methodWithPrimitiveAndWrappedInt", | |
20 | + | + assertEquals((Integer)17, Whitebox.invokeMethod(new ClassWithPrivateMethods(), "methodWithPrimitiveAndWrappedInt", | |
21 | + | new Class[]{int.class, Integer.class}, 9, Integer.valueOf(8))); | |
22 | + | } | |
23 | + | ||
24 | + | @@ -257,7 +257,7 @@ public class WhiteBoxTest { | |
25 | + | int expected = 123; | |
26 | + | Whitebox.setInternalState(ClassWithInternalState.class, "staticState", expected); | |
27 | + | assertEquals(expected, ClassWithInternalState.getStaticState()); | |
28 | + | - assertEquals(expected, Whitebox.getInternalState(ClassWithInternalState.class, "staticState")); | |
29 | + | + assertEquals(expected, (int)Whitebox.getInternalState(ClassWithInternalState.class, "staticState")); | |
30 | + | } | |
31 | + | ||
32 | + | @Test | |
33 | + | @@ -334,25 +334,25 @@ public class WhiteBoxTest { | |
34 | + | @Test | |
35 | + | public void testInvokeVarArgsMethod_multipleValues() throws Exception { | |
36 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
37 | + | - assertEquals(6, Whitebox.invokeMethod(tested, "varArgsMethod", 1, 2, 3)); | |
38 | + | + assertEquals(6, (int)Whitebox.invokeMethod(tested, "varArgsMethod", 1, 2, 3)); | |
39 | + | } | |
40 | + | ||
41 | + | @Test | |
42 | + | public void testInvokeVarArgsMethod_noArguments() throws Exception { | |
43 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
44 | + | - assertEquals(0, Whitebox.invokeMethod(tested, "varArgsMethod")); | |
45 | + | + assertEquals(0, (int)Whitebox.invokeMethod(tested, "varArgsMethod")); | |
46 | + | } | |
47 | + | ||
48 | + | @Test | |
49 | + | public void testInvokeVarArgsMethod_oneArgument() throws Exception { | |
50 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
51 | + | - assertEquals(4, Whitebox.invokeMethod(tested, "varArgsMethod", 2)); | |
52 | + | + assertEquals(4, (int)Whitebox.invokeMethod(tested, "varArgsMethod", 2)); | |
53 | + | } | |
54 | + | ||
55 | + | @Test | |
56 | + | public void testInvokeVarArgsMethod_invokeVarArgsWithOneArgument() throws Exception { | |
57 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
58 | + | - assertEquals(1, Whitebox.invokeMethod(tested, "varArgsMethod", new Class<?>[]{int[].class}, 1)); | |
59 | + | + assertEquals(1, (int)Whitebox.invokeMethod(tested, "varArgsMethod", new Class<?>[]{int[].class}, 1)); | |
60 | + | } | |
61 | + | ||
62 | + | @Test | |
63 | + | @@ -376,7 +376,7 @@ public class WhiteBoxTest { | |
64 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
65 | + | }; | |
66 | + | Whitebox.setInternalState(tested, fieldName, value); | |
67 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
68 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
69 | + | } | |
70 | + | ||
71 | + | @Test | |
72 | + | @@ -387,8 +387,8 @@ public class WhiteBoxTest { | |
73 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
74 | + | }; | |
75 | + | Whitebox.setInternalState(tested, fieldName, value); | |
76 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
77 | + | - assertEquals(-1, Whitebox.getInternalState(tested, fieldName, ClassWithInternalState.class)); | |
78 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
79 | + | + assertEquals(-1, (int)Whitebox.getInternalState(tested, fieldName, ClassWithInternalState.class)); | |
80 | + | } | |
81 | + | ||
82 | + | @Test(expected = IllegalArgumentException.class) | |
83 | + | @@ -398,7 +398,7 @@ public class WhiteBoxTest { | |
84 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
85 | + | }; | |
86 | + | Whitebox.setInternalState(tested, fieldName, new Object()); | |
87 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
88 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
89 | + | } | |
90 | + | ||
91 | + | @Test(expected = IllegalArgumentException.class) | |
92 | + | @@ -408,7 +408,7 @@ public class WhiteBoxTest { | |
93 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState() { | |
94 | + | }; | |
95 | + | Whitebox.setInternalState(tested, fieldName, (Object) null); | |
96 | + | - assertEquals(value, Whitebox.getInternalState(tested, fieldName)); | |
97 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, fieldName)); | |
98 | + | } | |
99 | + | ||
100 | + | @Test | |
101 | + | @@ -417,8 +417,8 @@ public class WhiteBoxTest { | |
102 | + | ClassWithChildThatHasInternalState tested = new ClassWithChildThatHasInternalState(); | |
103 | + | Whitebox.setInternalState(tested, int.class, value); | |
104 | + | assertEquals(value, (int) Whitebox.getInternalState(tested, int.class)); | |
105 | + | - assertEquals(value, Whitebox.getInternalState(tested, "anotherInternalState")); | |
106 | + | - assertEquals(value, Whitebox.getInternalState(tested, "anotherInternalState", | |
107 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "anotherInternalState")); | |
108 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "anotherInternalState", | |
109 | + | ClassWithChildThatHasInternalState.class)); | |
110 | + | } | |
111 | + | ||
112 | + | @@ -429,7 +429,7 @@ public class WhiteBoxTest { | |
113 | + | Whitebox.setInternalState(tested, int.class, value, ClassWithInternalState.class); | |
114 | + | assertEquals(42, (int) Whitebox.getInternalState(tested, int.class)); | |
115 | + | assertEquals(value, (int) Whitebox.getInternalState(tested, int.class, ClassWithInternalState.class)); | |
116 | + | - assertEquals(value, Whitebox.getInternalState(tested, "staticState", ClassWithInternalState.class)); | |
117 | + | + assertEquals(value, (int)Whitebox.getInternalState(tested, "staticState", ClassWithInternalState.class)); | |
118 | + | } | |
119 | + | ||
120 | + | @Test | |
121 | + | @@ -619,7 +619,7 @@ public class WhiteBoxTest { | |
122 | + | @Test | |
123 | + | public void testInvokeMethodWithBothNormalAndVarArgsParameter() throws Exception { | |
124 | + | ClassWithPrivateMethods tested = new ClassWithPrivateMethods(); | |
125 | + | - assertEquals(4, Whitebox.invokeMethod(tested, "varArgsMethod2", 1, 2, 3)); | |
126 | + | + assertEquals(4, (int)Whitebox.invokeMethod(tested, "varArgsMethod2", 1, 2, 3)); | |
127 | + | } | |
128 | + | ||
129 | + | @Test | |
130 | + | diff --git a/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java b/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
131 | + | index a5e5fda..14b8bbe 100644 | |
132 | + | --- a/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
133 | + | +++ b/powermock-reflect/src/test/java/org/powermock/reflect/internal/proxy/ClassFactory.java | |
134 | + | @@ -1,8 +1,8 @@ | |
135 | + | package org.powermock.reflect.internal.proxy; | |
136 | + | ||
137 | + | -import net.sf.cglib.asm.ClassWriter; | |
138 | + | -import net.sf.cglib.asm.MethodVisitor; | |
139 | + | -import net.sf.cglib.asm.Opcodes; | |
140 | + | +import org.objectweb.asm.ClassWriter; | |
141 | + | +import org.objectweb.asm.MethodVisitor; | |
142 | + | +import org.objectweb.asm.Opcodes; | |
143 | + | ||
144 | + | class ClassFactory implements Opcodes { | |
145 | + | ||
146 | + | -- | |
147 | + | 2.13.4 | |
148 | + |
more/packages/java.scm
36 | 36 | (define-public java-tomcat | |
37 | 37 | (package | |
38 | 38 | (name "java-tomcat") | |
39 | - | (version "8.5.16") | |
39 | + | (version "8.5.20") | |
40 | 40 | (source (origin | |
41 | 41 | (method url-fetch) | |
42 | - | (uri (string-append "http://download.nextag.com/apache/tomcat/tomcat-8/v" | |
42 | + | (uri (string-append "mirror://apache/tomcat/tomcat-8/v" | |
43 | 43 | version "/src/apache-tomcat-" version "-src.tar.gz")) | |
44 | 44 | (sha256 | |
45 | 45 | (base32 | |
46 | - | "08vc859z9f0787nhikbdsj6i441d4qk5xv17c1564hxxg6bmilqd")))) | |
46 | + | "0436glw5knwnlj5636vsb966zfdfcw3jpnwbpwjn743p3gk0mi3b")))) | |
47 | 47 | (build-system ant-build-system) | |
48 | 48 | (inputs | |
49 | 49 | `(("java-eclipse-jdt-core" ,java-eclipse-jdt-core))) | |
… | |||
51 | 51 | `(("java-junit" ,java-junit))) | |
52 | 52 | (arguments | |
53 | 53 | `(#:build-target "package" | |
54 | - | ;#:test-target "test" | |
55 | 54 | #:tests? #f; requires downloading some files. | |
56 | 55 | #:phases | |
57 | 56 | (modify-phases %standard-phases | |
… | |||
78 | 77 | (define-public java-openjfx | |
79 | 78 | (package | |
80 | 79 | (name "java-openjfx") | |
80 | + | ;; This is the last version that can be built for java8 | |
81 | 81 | (version "8u141-b14") | |
82 | 82 | (source (origin | |
83 | 83 | (method url-fetch) | |
… | |||
122 | 122 | (modify-phases %standard-phases | |
123 | 123 | (add-before 'check 'remove-empty-file | |
124 | 124 | (lambda _ | |
125 | - | ;; This file is completely commented, but junit expects it to contain | |
126 | - | ;; a class, so tests fail. | |
125 | + | ;; These files are completely commented, but junit expects them to | |
126 | + | ;; contain a class, so tests fail. | |
127 | 127 | (delete-file "modules/base/src/test/java/com/sun/javafx/property/adapter/PropertyDescriptorTest.java") | |
128 | 128 | (delete-file "modules/base/src/test/java/com/sun/javafx/property/adapter/ReadOnlyPropertyDescriptorTest.java") | |
129 | 129 | (delete-file "modules/base/src/test/java/javafx/beans/property/PropertiesTest.java") | |
… | |||
268 | 268 | ("java-commons-jcs" ,java-commons-jcs) | |
269 | 269 | ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
270 | 270 | ("java-commons-compress" ,java-commons-compress-latest))) | |
271 | - | ;(arguments | |
272 | - | ; `(#:tests? #f | |
273 | - | ; #:jdk ,icedtea-8 | |
274 | - | ; #:build-target "dist" | |
275 | - | ; #:phases | |
276 | - | ; (modify-phases %standard-phases | |
277 | - | ; (add-before 'build 'fix-revision | |
278 | - | ; (lambda* _ | |
279 | - | ; (with-output-to-file "REVISION.XML" | |
280 | - | ; (lambda _ | |
281 | - | ; (display | |
282 | - | ; (string-append "<info><entry><commit revision=\"" ,version "\">" | |
283 | - | ; "<date>1970-01-01 00:00:00 +0000</date>" | |
284 | - | ; "</commit></entry></info>")))))) | |
285 | - | ; (add-before 'build 'fix-build.xml | |
286 | - | ; (lambda _ | |
287 | - | ; (substitute* "build.xml" | |
288 | - | ; ;; otherwise gives a warnig at runtime | |
289 | - | ; (("UNKNOWN") ,version) | |
290 | - | ; ;; the folder is not created | |
291 | - | ; (("<touch.*epsg.output.*") "<mkdir dir=\"${epsg.output}/..\" /><touch file=\"${epsg.output}\"/>\n") | |
292 | - | ; ;; we don't have this compiler, so we use icedtea directly | |
293 | - | ; ((".*com.google.errorprone.ErrorProneAntCompilerAdapter.*") "") | |
294 | - | ; (("compiler=\"[^\"]*\" ") "") | |
295 | - | ; ;; Add this to classpath to find deps | |
296 | - | ; (("<javac sourcepath=\"\" srcdir=\"\\$\\{src.dir\\}\"") | |
297 | - | ; (string-append "<path id=\"classpath\"><pathelement location=\"${env.CLASSPATH}\" /></path>\n" | |
298 | - | ; "<javac sourcepath=\"\" srcdir=\"${src.dir}\" classpath=\"${classpath}\"")))))))) | |
299 | 271 | (arguments | |
300 | 272 | `(#:tests? #f | |
301 | 273 | #:jdk ,icedtea-8 | |
… | |||
420 | 392 | (build-system ant-build-system) | |
421 | 393 | (arguments | |
422 | 394 | `(#:build-target "package" | |
423 | - | #:tests? #f; junit run with "package" target | |
395 | + | #:tests? #f; tests are run as part of the build process | |
424 | 396 | #:phases | |
425 | 397 | (modify-phases %standard-phases | |
426 | 398 | (replace 'install | |
… | |||
445 | 417 | (build-system ant-build-system) | |
446 | 418 | (arguments | |
447 | 419 | `(#:build-target "package" | |
448 | - | #:tests? #f; junit run with "package" target | |
420 | + | #:tests? #f; tests are run as part of the build process | |
449 | 421 | #:phases | |
450 | 422 | (modify-phases %standard-phases | |
451 | 423 | (add-after 'unpack 'remove-bin | |
… | |||
472 | 444 | (build-system ant-build-system) | |
473 | 445 | (arguments | |
474 | 446 | `(#:build-target "package" | |
475 | - | #:tests? #f; junit run with "package" target | |
447 | + | #:tests? #f; tests are run as part of the build process | |
476 | 448 | #:phases | |
477 | 449 | (modify-phases %standard-phases | |
478 | 450 | (replace 'install | |
… | |||
483 | 455 | outputting XML data from Java code.") | |
484 | 456 | (license license:bsd-4))) | |
485 | 457 | ||
486 | - | (define-public java-commons-logging | |
487 | - | (package | |
488 | - | (inherit java-commons-logging-minimal) | |
489 | - | (arguments | |
490 | - | `(#:tests? #f ; avoid dependency on logging frameworks | |
491 | - | #:jar-name "commons-logging.jar" | |
492 | - | #:phases | |
493 | - | (modify-phases %standard-phases | |
494 | - | (add-after 'unpack 'delete-adapters-and-tests | |
495 | - | (lambda _ | |
496 | - | ;; Delete all adapters except for NoOpLog, SimpleLog, and | |
497 | - | ;; LogFactoryImpl. NoOpLog is required to build; LogFactoryImpl | |
498 | - | ;; is used by applications; SimpleLog is the only actually usable | |
499 | - | ;; implementation that does not depend on another logging | |
500 | - | ;; framework. | |
501 | - | (for-each | |
502 | - | (lambda (file) | |
503 | - | (delete-file (string-append | |
504 | - | "src/main/java/org/apache/commons/logging/impl/" file))) | |
505 | - | (list "Jdk13LumberjackLogger.java" | |
506 | - | "WeakHashtable.java" | |
507 | - | "Log4JLogger.java" | |
508 | - | "ServletContextCleaner.java" | |
509 | - | "Jdk14Logger.java" | |
510 | - | "AvalonLogger.java" | |
511 | - | "LogKitLogger.java")) | |
512 | - | (delete-file-recursively "src/test") | |
513 | - | #t))))) | |
514 | - | (inputs | |
515 | - | `(("log4j" ,java-log4j-api) | |
516 | - | ,@(package-inputs java-commons-logging-minimal))))) | |
517 | - | ||
518 | 458 | (define-public java-lz4 | |
519 | 459 | (package | |
520 | 460 | (name "java-lz4") | |
… | |||
537 | 477 | (description "") | |
538 | 478 | (license license:asl2.0))) | |
539 | 479 | ||
480 | + | (define-public java-bouncycastle-bcprov | |
481 | + | (package | |
482 | + | (name "java-bouncycastle-bcprov") | |
483 | + | (version "1.58") | |
484 | + | (source (origin | |
485 | + | (method url-fetch) | |
486 | + | (uri "https://bouncycastle.org/download/bcprov-jdk15on-158.tar.gz") | |
487 | + | (sha256 | |
488 | + | (base32 | |
489 | + | "1hgkg96llbvgs8i0krwz2n0j7wlg6jfnq8w8kg0cc899j0wfmf3n")))) | |
490 | + | (build-system ant-build-system) | |
491 | + | (arguments | |
492 | + | `(#:jar-name "bouncycastle-bcprov.jar" | |
493 | + | #:tests? #f; no tests | |
494 | + | #:source-dir "src" | |
495 | + | #:phases | |
496 | + | (modify-phases %standard-phases | |
497 | + | (add-before 'configure 'unzip-src | |
498 | + | (lambda _ | |
499 | + | (mkdir-p "src") | |
500 | + | (with-directory-excursion "src" | |
501 | + | (zero? (system* "unzip" "../src.zip")))))))) | |
502 | + | (native-inputs | |
503 | + | `(("unzip" ,unzip) | |
504 | + | ("junit" ,java-junit))) | |
505 | + | (home-page "https://www.bouncycastle.org") | |
506 | + | (synopsis "") | |
507 | + | (description "") | |
508 | + | (license license:expat))) | |
509 | + | ||
510 | + | (define-public java-bouncycastle-bcpkix | |
511 | + | (package | |
512 | + | (name "java-bouncycastle-bcpkix") | |
513 | + | (version "1.58") | |
514 | + | (source (origin | |
515 | + | (method url-fetch) | |
516 | + | (uri "https://bouncycastle.org/download/bcpkix-jdk15on-158.tar.gz") | |
517 | + | (sha256 | |
518 | + | (base32 | |
519 | + | "0is7qay02803s9f7lhnfcjlz61ni3hq5d7apg0iil7nbqkbfbcq2")))) | |
520 | + | (build-system ant-build-system) | |
521 | + | (arguments | |
522 | + | `(#:jar-name "bouncycastle-bcpkix.jar" | |
523 | + | #:tests? #f; no tests | |
524 | + | #:source-dir "src" | |
525 | + | #:phases | |
526 | + | (modify-phases %standard-phases | |
527 | + | (add-before 'configure 'unzip-src | |
528 | + | (lambda _ | |
529 | + | (mkdir-p "src") | |
530 | + | (with-directory-excursion "src" | |
531 | + | (zero? (system* "unzip" "../src.zip")))))))) | |
532 | + | (native-inputs | |
533 | + | `(("unzip" ,unzip) | |
534 | + | ("junit" ,java-junit))) | |
535 | + | (inputs | |
536 | + | `(("bcprov" ,java-bouncycastle-bcprov))) | |
537 | + | (home-page "https://www.bouncycastle.org") | |
538 | + | (synopsis "") | |
539 | + | (description "") | |
540 | + | (license license:expat))) | |
541 | + | ||
542 | + | (define-public java-bouncycastle-bctls | |
543 | + | (package | |
544 | + | (name "java-bouncycastle-bctls") | |
545 | + | (version "1.58") | |
546 | + | (source (origin | |
547 | + | (method url-fetch) | |
548 | + | (uri "https://bouncycastle.org/download/bctls-jdk15on-158.tar.gz") | |
549 | + | (sha256 | |
550 | + | (base32 | |
551 | + | "0riyd4iy9q9gk8spf0pqp64hrfihrdfm445aqr9n2zfb7n4jz2v3")))) | |
552 | + | (build-system ant-build-system) | |
553 | + | (arguments | |
554 | + | `(#:jar-name "bouncycastle.jar" | |
555 | + | #:tests? #f; no tests | |
556 | + | #:source-dir "src")) | |
557 | + | (inputs | |
558 | + | `(("bcprov" ,java-bouncycastle-bcprov) | |
559 | + | ("bcpkix" ,java-bouncycastle-bcpkix))) | |
560 | + | (native-inputs | |
561 | + | `(("junit" ,java-junit))) | |
562 | + | (home-page "https://www.bouncycastle.org") | |
563 | + | (synopsis "") | |
564 | + | (description "") | |
565 | + | (license license:expat))) | |
566 | + | ||
567 | + | (define-public java-powermock-core | |
568 | + | (package | |
569 | + | (name "java-powermock-core") | |
570 | + | (version "1.7.1") | |
571 | + | (source (origin | |
572 | + | (method url-fetch) | |
573 | + | (uri (string-append "https://github.com/powermock/powermock/" | |
574 | + | "archive/powermock-" version ".tar.gz")) | |
575 | + | (sha256 | |
576 | + | (base32 | |
577 | + | "09rdklqm1c2zp45c8x9596g8r9m5ab8aalxh447kljcrzajz49ri")) | |
578 | + | (patches | |
579 | + | (search-patches "java-powermock-fix-java-files.patch")))) | |
580 | + | (build-system ant-build-system) | |
581 | + | (arguments | |
582 | + | `(#:jar-name "java-powermock-core.jar" | |
583 | + | #:source-dir "powermock-core/src/main/java" | |
584 | + | #:test-dir "powermock-core/src/test" | |
585 | + | #:tests? #f; requires powermock-api | |
586 | + | #:jdk ,icedtea-8)) | |
587 | + | (inputs | |
588 | + | `(("reflect" ,java-powermock-reflect) | |
589 | + | ("javassist" ,java-jboss-javassist))) | |
590 | + | (native-inputs | |
591 | + | `(("junit" ,java-junit) | |
592 | + | ("assertj" ,java-assertj) | |
593 | + | ("mockito" ,java-mockito-1))) | |
594 | + | (home-page "https://github.com/powermock/powermock") | |
595 | + | (synopsis "") | |
596 | + | (description "") | |
597 | + | (license license:asl2.0))) | |
598 | + | ||
599 | + | (define-public java-powermock-reflect | |
600 | + | (package | |
601 | + | (inherit java-powermock-core) | |
602 | + | (name "java-powermock-reflect") | |
603 | + | (build-system ant-build-system) | |
604 | + | (arguments | |
605 | + | `(#:jar-name "java-powermock-reflect.jar" | |
606 | + | #:jdk ,icedtea-8 | |
607 | + | #:source-dir "powermock-reflect/src/main/java" | |
608 | + | #:test-dir "powermock-reflect/src/test")) | |
609 | + | (inputs | |
610 | + | `(("java-objenesis" ,java-objenesis))) | |
611 | + | (native-inputs | |
612 | + | `(("junit" ,java-junit) | |
613 | + | ("cglib" ,java-cglib) | |
614 | + | ("asm" ,java-asm) | |
615 | + | ("hamcrest" ,java-hamcrest-core) | |
616 | + | ("assertj" ,java-assertj))))) | |
617 | + | ||
618 | + | (define-public java-powermock-api-support | |
619 | + | (package | |
620 | + | (inherit java-powermock-core) | |
621 | + | (name "java-powermock-api-support") | |
622 | + | (build-system ant-build-system) | |
623 | + | (arguments | |
624 | + | `(#:jar-name "java-powermock-api-support.jar" | |
625 | + | #:jdk ,icedtea-8 | |
626 | + | #:source-dir "powermock-api/powermock-api-support/src/main/java" | |
627 | + | #:tests? #f)); no tests | |
628 | + | (inputs | |
629 | + | `(("core" ,java-powermock-core) | |
630 | + | ("reflect" ,java-powermock-reflect))))) | |
631 | + | ||
632 | + | (define-public java-powermock-api-easymock | |
633 | + | (package | |
634 | + | (inherit java-powermock-core) | |
635 | + | (name "java-powermock-api-easymock") | |
636 | + | (build-system ant-build-system) | |
637 | + | (arguments | |
638 | + | `(#:jar-name "java-powermock-api-easymock.jar" | |
639 | + | #:jdk ,icedtea-8 | |
640 | + | #:source-dir "powermock-api/powermock-api-easymock/src/main/java" | |
641 | + | #:tests? #f; no tests | |
642 | + | #:phases | |
643 | + | (modify-phases %standard-phases | |
644 | + | (add-before 'build 'fix-file | |
645 | + | (lambda _ | |
646 | + | ;; FIXME: This should not be necessary | |
647 | + | (substitute* "powermock-api/powermock-api-easymock/src/main/java/org/powermock/api/easymock/PowerMock.java" | |
648 | + | (("classLoader instanceof MockClassLoader") "false") | |
649 | + | (("\\(\\(MockClassLoader\\) classLoader\\).cache\\(mock.getClass\\(\\)\\);") ";"))))))) | |
650 | + | (inputs | |
651 | + | `(("core" ,java-powermock-core) | |
652 | + | ("easymock" ,java-easymock) | |
653 | + | ("reflect" ,java-powermock-reflect) | |
654 | + | ("support" ,java-powermock-api-support) | |
655 | + | ("cglib" ,java-cglib))))) | |
656 | + | ||
657 | + | (define-public java-powermock-modules-junit4-common | |
658 | + | (package | |
659 | + | (inherit java-powermock-core) | |
660 | + | (name "java-powermock-modules-junit4-common") | |
661 | + | (build-system ant-build-system) | |
662 | + | (arguments | |
663 | + | `(#:jar-name "java-powermock-modules-junit4-common.jar" | |
664 | + | #:jdk ,icedtea-8 | |
665 | + | #:source-dir "powermock-modules/powermock-module-junit4-common/src/main/java" | |
666 | + | #:test-dir "powermock-modules/powermock-module-junit4-common/src/test")) | |
667 | + | (inputs | |
668 | + | `(("core" ,java-powermock-core) | |
669 | + | ("easymock" ,java-easymock) | |
670 | + | ("reflect" ,java-powermock-reflect) | |
671 | + | ("hamcrest" ,java-hamcrest-core) | |
672 | + | ("cglib" ,java-cglib))))) | |
673 | + | ||
674 | + | (define-public java-powermock-modules-junit4 | |
675 | + | (package | |
676 | + | (inherit java-powermock-core) | |
677 | + | (name "java-powermock-modules-junit4") | |
678 | + | (build-system ant-build-system) | |
679 | + | (arguments | |
680 | + | `(#:jar-name "java-powermock-modules-junit4.jar" | |
681 | + | #:jdk ,icedtea-8 | |
682 | + | #:source-dir "powermock-modules/powermock-module-junit4/src/main/java" | |
683 | + | #:test-dir "powermock-modules/powermock-module-junit4/src/test")) | |
684 | + | (inputs | |
685 | + | `(("core" ,java-powermock-core) | |
686 | + | ("reflect" ,java-powermock-reflect) | |
687 | + | ("common" ,java-powermock-modules-junit4-common) | |
688 | + | ("cglib" ,java-cglib))) | |
689 | + | (native-inputs | |
690 | + | `(("easymock" ,java-easymock) | |
691 | + | ("hamcrest" ,java-hamcrest-core) | |
692 | + | ("objenesis" ,java-objenesis) | |
693 | + | ("asm" ,java-asm) | |
694 | + | ("junit" ,java-junit))))) | |
695 | + | ||
540 | 696 | (define-public java-kafka-clients | |
541 | 697 | (package | |
542 | 698 | (name "java-kafka-clients") | |
… | |||
553 | 709 | `(#:jar-name "java-kafka-clients.jar" | |
554 | 710 | #:jdk ,icedtea-8 | |
555 | 711 | #:source-dir "clients/src/main/java" | |
712 | + | #:test-dir "clients/src/test" | |
713 | + | ;; FIXME: we have all test dependencies, but they fail with: | |
714 | + | ;; java.lang.UnsupportedOperationException: This code should have never made it into slf4j-api.jar | |
556 | 715 | #:tests? #f)) | |
557 | 716 | (inputs | |
558 | 717 | `(("java-slf4j-api" ,java-slf4j-api) | |
559 | 718 | ("java-lz4" ,java-lz4))) | |
719 | + | (native-inputs | |
720 | + | `(("junit" ,java-junit) | |
721 | + | ("hamcrest" ,java-hamcrest-all) | |
722 | + | ("objenesis" ,java-objenesis) | |
723 | + | ("asm" ,java-asm) | |
724 | + | ("easymock" ,java-easymock) | |
725 | + | ("powermock" ,java-powermock-core) | |
726 | + | ("powermock-easymock" ,java-powermock-api-easymock) | |
727 | + | ("powermock-junit4-common" ,java-powermock-modules-junit4-common) | |
728 | + | ("powermock-junit4" ,java-powermock-modules-junit4) | |
729 | + | ("powermock-support" ,java-powermock-api-support) | |
730 | + | ("bouncycastle" ,java-bouncycastle-bcprov) | |
731 | + | ("bouncycastle-bcpkix" ,java-bouncycastle-bcpkix))) | |
560 | 732 | (home-page "https://kafka.apache.org") | |
561 | 733 | (synopsis "") | |
562 | 734 | (description "") | |
… | |||
577 | 749 | (build-system ant-build-system) | |
578 | 750 | (arguments | |
579 | 751 | `(#:build-target "jarall" | |
580 | - | #:tests? #f | |
752 | + | #:test-target "junit-tests-all" | |
581 | 753 | #:phases | |
582 | 754 | (modify-phases %standard-phases | |
583 | 755 | (replace 'install | |
… | |||
605 | 777 | (arguments | |
606 | 778 | `(#:jar-name "java-hdrhistogram.jar" | |
607 | 779 | #:source-dir "src/main/java" | |
608 | - | #:tests? #f | |
609 | 780 | #:phases | |
610 | 781 | (modify-phases %standard-phases | |
611 | 782 | (add-before 'configure 'set-version | |
… | |||
616 | 787 | (substitute* version-java | |
617 | 788 | (("\\$VERSION\\$") ,version) | |
618 | 789 | (("\\$BUILD_TIME\\$") "0")))))))) | |
790 | + | (native-inputs | |
791 | + | `(("junit" ,java-junit) | |
792 | + | ("hamcrest" ,java-hamcrest-core))) | |
619 | 793 | (home-page "https://hdrhistogram.github.io/HdrHistogram") | |
620 | 794 | (synopsis "") | |
621 | 795 | (description "") | |
… | |||
641 | 815 | (arguments | |
642 | 816 | `(#:jar-name "java-jmock.jar" | |
643 | 817 | #:source-dir "jmock/src/main/java" | |
644 | - | #:tests? #f)) | |
818 | + | #:test-dir "jmock/src/test" | |
819 | + | #:phases | |
820 | + | (modify-phases %standard-phases | |
821 | + | (add-before 'check 'fix-tests | |
822 | + | (lambda _ | |
823 | + | ;; Otherwise the abstract class is tested, but junit cannot create | |
824 | + | ;; an instance of it. Then remove dependent. | |
825 | + | (for-each (lambda (file) (delete-file file)) | |
826 | + | '("jmock/src/test/java/org/jmock/test/unit/lib/AbstractMatcherTest.java" | |
827 | + | "jmock/src/test/java/org/jmock/test/unit/lib/CurrentStateMatcherTests.java"))))))) | |
828 | + | (native-inputs | |
829 | + | `(("cglib" ,java-cglib))) | |
645 | 830 | (home-page "https://github.com/jmock-developers/jmock-library") | |
646 | 831 | (synopsis "") | |
647 | 832 | (description "") | |
… | |||
654 | 839 | (arguments | |
655 | 840 | `(#:jar-name "java-jmock-junit4.jar" | |
656 | 841 | #:source-dir "jmock-junit4/src/main/java" | |
657 | - | #:tests? #f)) | |
842 | + | #:test-dir "jmock-junit4/src/test")) | |
658 | 843 | (inputs | |
659 | 844 | `(("java-hamcrest-all" ,java-hamcrest-all) | |
660 | 845 | ("java-asm" ,java-asm) | |
… | |||
662 | 847 | ("java-jmock" ,java-jmock) | |
663 | 848 | ("java-jumit" ,java-junit))))) | |
664 | 849 | ||
665 | - | ||
666 | 850 | (define-public java-jmock-legacy | |
667 | 851 | (package | |
668 | 852 | (inherit java-jmock) | |
… | |||
670 | 854 | (arguments | |
671 | 855 | `(#:jar-name "java-jmock-legacy.jar" | |
672 | 856 | #:source-dir "jmock-legacy/src/main/java" | |
673 | - | #:tests? #f)) | |
857 | + | #:test-dir "jmock-legacy/src/test" | |
858 | + | #:phases | |
859 | + | (modify-phases %standard-phases | |
860 | + | (add-before 'check 'copy-tests | |
861 | + | (lambda _ | |
862 | + | ;; This file is a dependance of some tests | |
863 | + | (copy-file "jmock/src/test/java/org/jmock/test/acceptance/PackageProtectedType.java" | |
864 | + | "jmock-legacy/src/test/java/org/jmock/test/acceptance/PackageProtectedType.java")))))) | |
674 | 865 | (inputs | |
675 | 866 | `(("java-hamcrest-all" ,java-hamcrest-all) | |
676 | 867 | ("java-objenesis" ,java-objenesis) | |
… | |||
678 | 869 | ("java-jmock" ,java-jmock) | |
679 | 870 | ("java-asm" ,java-asm) | |
680 | 871 | ("java-bsh" ,java-bsh) | |
681 | - | ("java-jumit" ,java-junit))))) | |
872 | + | ("java-junit" ,java-junit))) | |
873 | + | (native-inputs | |
874 | + | `(("java-jmock-junit4" ,java-jmock-junit4))))) | |
682 | 875 | ||
683 | 876 | (define-public java-lmax-disruptor | |
684 | 877 | (package | |
… | |||
695 | 888 | (arguments | |
696 | 889 | `(#:jar-name "java-lmax-disruptor.jar" | |
697 | 890 | #:jdk ,icedtea-8 | |
698 | - | #:source-dir "src" | |
699 | - | #:tests? #f)); no tests | |
891 | + | #:tests? #f)); tests hang | |
700 | 892 | (inputs | |
701 | 893 | `(("junit" ,java-junit) | |
702 | 894 | ("java-hdrhistogram" ,java-hdrhistogram) | |
… | |||
704 | 896 | ("java-jmock-legacy" ,java-jmock-legacy) | |
705 | 897 | ("java-jmock-junit4" ,java-jmock-junit4) | |
706 | 898 | ("java-hamcrest-all" ,java-hamcrest-all))) | |
899 | + | (native-inputs | |
900 | + | `(("cglib" ,java-cglib) | |
901 | + | ("objenesis" ,java-objenesis) | |
902 | + | ("asm" ,java-asm))) | |
707 | 903 | (home-page "https://www.lmax.com/disruptor") | |
708 | 904 | (synopsis "") | |
709 | 905 | (description "") | |
… | |||
732 | 928 | (description "") | |
733 | 929 | (license (list license:edl1.0 license:epl1.0)))) | |
734 | 930 | ||
931 | + | (define-public java-jboss-javassist | |
932 | + | (package | |
933 | + | (name "java-jboss-javassist") | |
934 | + | (version "3.21.0") | |
935 | + | (source (origin | |
936 | + | (method url-fetch) | |
937 | + | (uri (string-append "https://github.com/jboss-javassist/javassist/" | |
938 | + | "archive/rel_" | |
939 | + | (string-map (lambda (x) (if (eq? x #\.) #\_ x)) version) | |
940 | + | "_ga.tar.gz")) | |
941 | + | (sha256 | |
942 | + | (base32 | |
943 | + | "10lpcr3sbf7y6fq6fc2h2ik7rqrivwcy4747bg0kxhwszil3cfmf")))) | |
944 | + | (build-system ant-build-system) | |
945 | + | (arguments | |
946 | + | `(#:jar-name "java-jboss-javassist.jar" | |
947 | + | #:jdk ,icedtea-8 | |
948 | + | #:source-dir "src/main" | |
949 | + | #:tests? #f; FIXME: requires junit-awtui and junit-swingui from junit3 | |
950 | + | #:phases | |
951 | + | (modify-phases %standard-phases | |
952 | + | (add-before 'configure 'remove-binary | |
953 | + | (lambda _ | |
954 | + | (delete-file "javassist.jar")))))) | |
955 | + | (native-inputs | |
956 | + | `(("junit" ,java-junit))) | |
957 | + | (home-page "https://github.com/jboss-javassist/javassist") | |
958 | + | (synopsis "") | |
959 | + | (description "") | |
960 | + | (license (list license:gpl2 license:cddl1.0)))); either gpl2 only or cddl. | |
961 | + | ||
962 | + | (define-public java-jboss-annotations-api-spec | |
963 | + | (package | |
964 | + | (name "java-jboss-annotations-api-spec") | |
965 | + | (version "1.2") | |
966 | + | (source (origin | |
967 | + | (method url-fetch) | |
968 | + | (uri (string-append "https://github.com/jboss/jboss-annotations-api_spec/" | |
969 | + | "archive/jboss-annotations-api_" version | |
970 | + | "_spec-1.0.1.Final.tar.gz")) | |
971 | + | (sha256 | |
972 | + | (base32 | |
973 | + | "0zvglvscq177lahvp8n9nlm0vkdxlf6db0fs8jcy8zf82z6k4d2n")))) | |
974 | + | (build-system ant-build-system) | |
975 | + | (arguments | |
976 | + | `(#:jar-name "java-jboss-annotations-api_spec.jar" | |
977 | + | #:jdk ,icedtea-8 | |
978 | + | #:source-dir "." | |
979 | + | #:tests? #f)); no tests | |
980 | + | (home-page "https://github.com/jboss/jboss-annotations-api_spec") | |
981 | + | (synopsis "") | |
982 | + | (description "") | |
983 | + | (license (list license:gpl2 license:cddl1.0)))); either gpl2 only or cddl. | |
984 | + | ||
735 | 985 | (define-public java-jboss-interceptors-api-spec | |
736 | 986 | (package | |
737 | 987 | (name "java-jboss-interceptors-api-spec") | |
… | |||
770 | 1020 | (build-system ant-build-system) | |
771 | 1021 | (arguments | |
772 | 1022 | `(#:jar-name "java-jboss-el-api_spec.jar" | |
773 | - | #:jdk ,icedtea-8 | |
774 | - | #:source-dir "." | |
775 | - | #:tests? #f)); no tests | |
1023 | + | #:jdk ,icedtea-8)) | |
776 | 1024 | (inputs | |
777 | 1025 | `(("junit" ,java-junit))) | |
778 | 1026 | (home-page "https://github.com/jboss/jboss-el-api_spec") | |
… | |||
796 | 1044 | (arguments | |
797 | 1045 | `(#:jar-name "java-jboss-transaction-api_spec.jar" | |
798 | 1046 | #:jdk ,icedtea-8 | |
799 | - | #:source-dir "." | |
1047 | + | #:source-dir "src/main/java" | |
800 | 1048 | #:tests? #f)); no tests | |
801 | 1049 | (inputs | |
802 | 1050 | `(("cdi-api" ,java-cdi-api) | |
… | |||
845 | 1093 | `(#:jar-name "java-mail.jar" | |
846 | 1094 | #:jdk ,icedtea-8 | |
847 | 1095 | #:source-dir "mail/src/main/java" | |
848 | - | #:tests? #f; no tests | |
1096 | + | #:test-dir "mail/src/test" | |
849 | 1097 | #:phases | |
850 | 1098 | (modify-phases %standard-phases | |
851 | 1099 | (add-before 'configure 'move-version.java | |
852 | 1100 | (lambda _ | |
853 | 1101 | ;; this is done in build.xml (init target) | |
854 | 1102 | (copy-file "mail/src/main/resources/javax/mail/Version.java" | |
855 | - | "mail/src/main/java/javax/mail/Version.java")))))) | |
1103 | + | "mail/src/main/java/javax/mail/Version.java"))) | |
1104 | + | (add-before 'check 'remove-failing | |
1105 | + | (lambda _ | |
1106 | + | ;; This fails | |
1107 | + | (delete-file "mail/src/test/java/com/sun/mail/util/logging/CollectorFormatterTest.java") | |
1108 | + | ;; This one needs the previous one | |
1109 | + | (delete-file "mail/src/test/java/com/sun/mail/util/logging/CompactFormatterTest.java") | |
1110 | + | ;; This fails | |
1111 | + | (delete-file "mail/src/test/java/com/sun/mail/util/logging/DurationFilterTest.java") | |
1112 | + | (delete-file "mail/src/test/java/com/sun/mail/util/logging/MailHandlerTest.java") | |
1113 | + | (delete-file "mail/src/test/java/javax/mail/internet/GetLocalAddressTest.java") | |
1114 | + | ;; FIXME: ends with: | |
1115 | + | ;; java.lang.ClassNotFoundException: javax.mail.internet.MimeMultipartParseTest | |
1116 | + | (delete-file "mail/src/test/java/javax/mail/internet/MimeMultipartParseTest.java") | |
1117 | + | ;; FIXME: same here | |
1118 | + | (delete-file "mail/src/test/java/javax/mail/search/SearchTermSerializationTest.java") | |
1119 | + | )) | |
1120 | + | (add-before 'build 'copy-resources | |
1121 | + | (lambda _ | |
1122 | + | (mkdir-p "build/classes/META-INF") | |
1123 | + | (for-each (lambda (file) | |
1124 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1125 | + | (basename file)))) | |
1126 | + | (find-files "mail/src/main/resources/META-INF/" ".*"))))))) | |
1127 | + | (native-inputs | |
1128 | + | `(("junit" ,java-junit) | |
1129 | + | ("hamcrest" ,java-hamcrest-core))) | |
856 | 1130 | (home-page "https://javaee.github.io/javamail") | |
857 | 1131 | (synopsis "") | |
858 | 1132 | (description "") | |
… | |||
875 | 1149 | (arguments | |
876 | 1150 | `(#:jar-name "jackson-annotations.jar" | |
877 | 1151 | #:source-dir "src/main/java" | |
878 | - | #:tests? #f)); how to run them? src/test/java | |
1152 | + | #:test-dir "src/test")) | |
1153 | + | (native-inputs | |
1154 | + | `(("junit" ,java-junit))) | |
879 | 1155 | (home-page "https://github.com/FasterXML/jackson-annotations") | |
880 | 1156 | (synopsis "") | |
881 | 1157 | (description "") | |
… | |||
897 | 1173 | (arguments | |
898 | 1174 | `(#:jar-name "jackson-core.jar" | |
899 | 1175 | #:source-dir "src/main/java" | |
900 | - | #:tests? #f; how to run them? src/test/java | |
1176 | + | #:test-dir "src/test" | |
901 | 1177 | #:phases | |
902 | 1178 | (modify-phases %standard-phases | |
903 | 1179 | (add-before 'configure 'generate-PackageVersion.java | |
… | |||
909 | 1185 | (("@package@") "com.fasterxml.jackson.core.json") | |
910 | 1186 | (("@projectversion@") ,version) | |
911 | 1187 | (("@projectgroupid@") "com.fasterxml.jackson.core") | |
912 | - | (("@projectartifactid@") "jackson-core")))))))) | |
1188 | + | (("@projectartifactid@") "jackson-core"))))) | |
1189 | + | (add-before 'build 'copy-resources | |
1190 | + | (lambda _ | |
1191 | + | (mkdir-p "build/classes/META-INF") | |
1192 | + | (for-each (lambda (file) | |
1193 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1194 | + | (basename file)))) | |
1195 | + | (find-files "src/main/resources/META-INF/" ".*")))) | |
1196 | + | (add-before 'check 'copy-test-resources | |
1197 | + | (lambda _ | |
1198 | + | (mkdir-p "build/test-classes") | |
1199 | + | (for-each (lambda (file) | |
1200 | + | (copy-file file (string-append "build/classes" | |
1201 | + | (basename file)))) | |
1202 | + | (find-files "src/test/resources/" ".*\\.json")))) | |
1203 | + | (add-before 'check 'exclude-base | |
1204 | + | (lambda _ | |
1205 | + | ;; not really tests | |
1206 | + | (substitute* "build.xml" | |
1207 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1208 | + | (string-append "<include name=\"**/*Test.java\" />" | |
1209 | + | "<exclude name=\"**/failing/**\" />" | |
1210 | + | "<exclude name=\"**/BaseTest.java\" />" | |
1211 | + | "<exclude name=\"**/ConcurrencyReadTest.java\" />" | |
1212 | + | "<exclude name=\"**/ManualCharAccessTest.java\" />" | |
1213 | + | "<exclude name=\"**/TrailingCommasTest.java\" />" | |
1214 | + | "<exclude name=\"**/AsyncMissingValuesInObjectTest.java\" />" | |
1215 | + | "<exclude name=\"**/AsyncMissingValuesInArrayTest.java\" />"))))) | |
1216 | + | (add-before 'build 'copy-resources | |
1217 | + | (lambda _ | |
1218 | + | (mkdir-p "build/classes/META-INF") | |
1219 | + | (for-each (lambda (file) | |
1220 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1221 | + | (basename file)))) | |
1222 | + | (find-files "src/main/resources/META-INF/" ".*"))))))) | |
1223 | + | (native-inputs | |
1224 | + | `(("junit" ,java-junit) | |
1225 | + | ("hamcrest" ,java-hamcrest-core))) | |
913 | 1226 | (home-page "https://github.com/FasterXML/jackson-core") | |
914 | 1227 | (synopsis "") | |
915 | 1228 | (description "") | |
916 | 1229 | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
917 | 1230 | ||
918 | - | (define-public java-fasterxml-jackson-databind | |
1231 | + | (define-public java-fasterxml-jackson-databind | |
1232 | + | (package | |
1233 | + | (name "java-fasterxml-jackson-databind") | |
1234 | + | (version "2.9.0") | |
1235 | + | (source (origin | |
1236 | + | (method url-fetch) | |
1237 | + | (uri (string-append "https://github.com/FasterXML/" | |
1238 | + | "jackson-databind/archive/" | |
1239 | + | "jackson-databind-" version ".tar.gz")) | |
1240 | + | (sha256 | |
1241 | + | (base32 | |
1242 | + | "01a60dwy1q11xizvimphmhjfbk41rwar3rl1q3xcwlhic2vdw147")))) | |
1243 | + | (build-system ant-build-system) | |
1244 | + | (arguments | |
1245 | + | `(#:jar-name "jackson-databind.jar" | |
1246 | + | #:source-dir "src/main/java" | |
1247 | + | #:tests? #f; requires javax.measures for which I can't find a free implementation | |
1248 | + | #:phases | |
1249 | + | (modify-phases %standard-phases | |
1250 | + | (add-before 'configure 'generate-PackageVersion.java | |
1251 | + | (lambda _ | |
1252 | + | (let* ((out "src/main/java/com/fasterxml/jackson/databind/cfg/PackageVersion.java") | |
1253 | + | (in (string-append out ".in"))) | |
1254 | + | (copy-file in out) | |
1255 | + | (substitute* out | |
1256 | + | (("@package@") "com.fasterxml.jackson.databind.cfg") | |
1257 | + | (("@projectversion@") ,version) | |
1258 | + | (("@projectgroupid@") "com.fasterxml.jackson.databind") | |
1259 | + | (("@projectartifactid@") "jackson-databind"))))) | |
1260 | + | (add-before 'build 'copy-resources | |
1261 | + | (lambda _ | |
1262 | + | (mkdir-p "build/classes/META-INF") | |
1263 | + | (for-each (lambda (file) | |
1264 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1265 | + | (basename file)))) | |
1266 | + | (find-files "src/main/resources/META-INF/" ".*"))))))) | |
1267 | + | (inputs | |
1268 | + | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
1269 | + | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core))) | |
1270 | + | (native-inputs | |
1271 | + | `(("junit" ,java-junit))) | |
1272 | + | (home-page "https://github.com/FasterXML/jackson-databind") | |
1273 | + | (synopsis "") | |
1274 | + | (description "") | |
1275 | + | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
1276 | + | ||
1277 | + | (define-public java-fasterxml-jackson-modules-base | |
1278 | + | (package | |
1279 | + | (name "java-fasterxml-jackson-modules-base") | |
1280 | + | (version "2.9.0") | |
1281 | + | (source (origin | |
1282 | + | (method url-fetch) | |
1283 | + | (uri (string-append "https://github.com/FasterXML/" | |
1284 | + | "jackson-modules-base/archive/" | |
1285 | + | "jackson-modules-base-" version ".tar.gz")) | |
1286 | + | (sha256 | |
1287 | + | (base32 | |
1288 | + | "054f1rk3k7way7d2a67q2j81yi33n1q9l4rp14jb864y46zdaayy")))) | |
1289 | + | (build-system ant-build-system) | |
1290 | + | (arguments | |
1291 | + | `(#:jar-name "jackson-modules-base.jar" | |
1292 | + | #:source-dir "jaxb/src/main/java" | |
1293 | + | #:test-dir "jaxb/src/test" | |
1294 | + | #:phases | |
1295 | + | (modify-phases %standard-phases | |
1296 | + | (add-before 'configure 'generate-PackageVersion.java | |
1297 | + | (lambda _ | |
1298 | + | (let* ((out (string-append "jaxb/src/main/java/com/fasterxml/" | |
1299 | + | "jackson/module/jaxb/PackageVersion.java")) | |
1300 | + | (in (string-append out ".in"))) | |
1301 | + | (copy-file in out) | |
1302 | + | (substitute* out | |
1303 | + | (("@package@") "com.fasterxml.jackson.module.jaxb") | |
1304 | + | (("@projectversion@") ,version) | |
1305 | + | (("@projectgroupid@") "com.fasterxml.jackson.module.jaxb") | |
1306 | + | (("@projectartifactid@") "jackson-module-jaxb"))))) | |
1307 | + | (add-before 'check 'disable-failing | |
1308 | + | (lambda _ | |
1309 | + | (substitute* "build.xml" | |
1310 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1311 | + | (string-append "<include name=\"**/*Test.java\" />" | |
1312 | + | ;; The base class for tests, not a test in itself | |
1313 | + | "<exclude name=\"**/BaseJaxbTest.java\" />"))))) | |
1314 | + | (add-before 'build 'copy-resources | |
1315 | + | (lambda _ | |
1316 | + | (mkdir-p "build/classes/META-INF") | |
1317 | + | (for-each (lambda (file) | |
1318 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1319 | + | (basename file)))) | |
1320 | + | (find-files "jaxb/src/main/resources/META-INF/" ".*"))))))) | |
1321 | + | (inputs | |
1322 | + | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
1323 | + | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core) | |
1324 | + | ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind))) | |
1325 | + | (native-inputs | |
1326 | + | `(("java-junit" ,java-junit))) | |
1327 | + | (home-page "https://github.com/FasterXML/jackson-dataformat-xml") | |
1328 | + | (synopsis "") | |
1329 | + | (description "") | |
1330 | + | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
1331 | + | ||
1332 | + | (define-public java-woodstox-core | |
1333 | + | (package | |
1334 | + | (name "java-woodstox-core") | |
1335 | + | (version "5.0.3") | |
1336 | + | (source (origin | |
1337 | + | (method url-fetch) | |
1338 | + | (uri (string-append "https://github.com/FasterXML/woodstox/archive/woodstox-core-5.0.3.tar.gz")) | |
1339 | + | (sha256 | |
1340 | + | (base32 | |
1341 | + | "1i7pdgb8jbw6gdy5kmm0l6rz109n2ns92pqalpyp24vb8vlvdfd4")))) | |
1342 | + | (build-system ant-build-system) | |
1343 | + | (arguments | |
1344 | + | `(#:jar-name "woodstox.jar" | |
1345 | + | #:phases | |
1346 | + | (modify-phases %standard-phases | |
1347 | + | (add-before 'build 'remove-msv-dep | |
1348 | + | (lambda _ | |
1349 | + | ;; we don't need osgi, and it depends on msv | |
1350 | + | (delete-file-recursively "src/main/java/com/ctc/wstx/osgi") | |
1351 | + | ;; msv's latest release is from 2011 | |
1352 | + | (delete-file-recursively "src/main/java/com/ctc/wstx/msv") | |
1353 | + | (delete-file-recursively "src/test/java/wstxtest/osgi") | |
1354 | + | (delete-file-recursively "src/test/java/wstxtest/msv"))) | |
1355 | + | (add-before 'check 'remove-failing | |
1356 | + | (lambda _ | |
1357 | + | (substitute* "build.xml" | |
1358 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1359 | + | (string-append "<include name=\"**/*Test.java\" />" | |
1360 | + | "<exclude name=\"**/Base*.java\" />" | |
1361 | + | "<exclude name=\"failing/**\" />"))))) | |
1362 | + | (add-before 'build 'copy-resources | |
1363 | + | (lambda _ | |
1364 | + | (mkdir-p "build/classes/META-INF") | |
1365 | + | (for-each (lambda (file) | |
1366 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1367 | + | (basename file)))) | |
1368 | + | (find-files "src/main/resources/META-INF/" ".*"))))))) | |
1369 | + | (inputs | |
1370 | + | `(("stax2" ,java-stax2-api))) | |
1371 | + | (native-inputs | |
1372 | + | `(("junit" ,java-junit))) | |
1373 | + | (home-page "https://github.com/FasterXML/woodstox") | |
1374 | + | (synopsis "") | |
1375 | + | (description "") | |
1376 | + | (license license:asl2.0))) | |
1377 | + | ||
1378 | + | (define-public java-fasterxml-jackson-dataformat-xml | |
1379 | + | (package | |
1380 | + | (name "java-fasterxml-jackson-dataformat-xml") | |
1381 | + | (version "2.9.0") | |
1382 | + | (source (origin | |
1383 | + | (method url-fetch) | |
1384 | + | (uri (string-append "https://github.com/FasterXML/" | |
1385 | + | "jackson-dataformat-xml/archive/" | |
1386 | + | "jackson-dataformat-xml-" version ".tar.gz")) | |
1387 | + | (sha256 | |
1388 | + | (base32 | |
1389 | + | "1iv8brs68szk2d4fghji1bgg5g8fcc4y1yp363phiy794f40vxfc")))) | |
1390 | + | (build-system ant-build-system) | |
1391 | + | (arguments | |
1392 | + | `(#:jar-name "jackson-dataformat-xml.jar" | |
1393 | + | #:source-dir "src/main/java" | |
1394 | + | ;; FIXME: tests fail to find the SAX API implementation in woodstox. | |
1395 | + | ;; It probably means this package is broken. | |
1396 | + | #:tests? #f | |
1397 | + | #:phases | |
1398 | + | (modify-phases %standard-phases | |
1399 | + | (add-before 'configure 'generate-PackageVersion.java | |
1400 | + | (lambda _ | |
1401 | + | (let* ((out "src/main/java/com/fasterxml/jackson/dataformat/xml/PackageVersion.java") | |
1402 | + | (in (string-append out ".in"))) | |
1403 | + | (copy-file in out) | |
1404 | + | (newline) | |
1405 | + | (substitute* out | |
1406 | + | (("@package@") "com.fasterxml.jackson.dataformat.xml") | |
1407 | + | (("@projectversion@") ,version) | |
1408 | + | (("@projectgroupid@") "com.fasterxml.jackson.dataformat.xml") | |
1409 | + | (("@projectartifactid@") "jackson-dataformat-xml"))))) | |
1410 | + | (add-before 'build 'copy-resources | |
1411 | + | (lambda _ | |
1412 | + | (mkdir-p "build/classes/META-INF") | |
1413 | + | (for-each (lambda (file) | |
1414 | + | (copy-file file (string-append "build/classes/META-INF/" | |
1415 | + | (basename file)))) | |
1416 | + | (find-files "src/main/resources/META-INF/" ".*"))))))) | |
1417 | + | (inputs | |
1418 | + | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
1419 | + | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core) | |
1420 | + | ("java-fasterxml-jackson-modules-base" ,java-fasterxml-jackson-modules-base) | |
1421 | + | ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind) | |
1422 | + | ("java-stax2-api" ,java-stax2-api) | |
1423 | + | ("woodstox" ,java-woodstox-core))) | |
1424 | + | (native-inputs | |
1425 | + | `(("junit" ,java-junit) | |
1426 | + | ("hamcrest" ,java-hamcrest-core))) | |
1427 | + | (home-page "https://github.com/FasterXML/jackson-dataformat-xml") | |
1428 | + | (synopsis "") | |
1429 | + | (description "") | |
1430 | + | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
1431 | + | ||
1432 | + | (define-public java-stax2-api | |
1433 | + | (package | |
1434 | + | (name "java-stax2-api") | |
1435 | + | (version "4.0.0") | |
1436 | + | (source (origin | |
1437 | + | (method url-fetch) | |
1438 | + | (uri (string-append "https://github.com/FasterXML/stax2-api/archive/" | |
1439 | + | "stax2-api-" version ".tar.gz")) | |
1440 | + | (sha256 | |
1441 | + | (base32 | |
1442 | + | "1amc1si0l0hyyw2sawmnzy4hkna3z6fp195y4nm5m9wb9ld5awkq")))) | |
1443 | + | (build-system ant-build-system) | |
1444 | + | (arguments | |
1445 | + | `(#:jar-name "java-stax2-api.jar" | |
1446 | + | #:source-dir "src/main/java" | |
1447 | + | #:tests? #f)); no tests | |
1448 | + | (home-page "https://github.com/FasterXML/stax2-api") | |
1449 | + | (synopsis "Stax2 API") | |
1450 | + | (description "Stax2 API is an extension to basic Stax 1.0 API that adds | |
1451 | + | significant new functionalities, such as full-featured bi-direction validation | |
1452 | + | interface and high-performance Typed Access API.") | |
1453 | + | (license license:bsd-2))) | |
1454 | + | ||
1455 | + | (define-public java-aspectj-weaver | |
1456 | + | (package | |
1457 | + | (name "java-aspectj-weaver") | |
1458 | + | (version "1.8.10") | |
1459 | + | (source (origin | |
1460 | + | (method url-fetch) | |
1461 | + | (uri (string-append "http://eclipsemirror.itemis.de/eclipse/tools" | |
1462 | + | "/aspectj/aspectj-" version "-src.jar")) | |
1463 | + | (sha256 | |
1464 | + | (base32 | |
1465 | + | "0r16lgzindqf4xhdmdyk9j6p15nak2fwhqlp42yg3axvn8fx6r23")))) | |
1466 | + | (build-system ant-build-system) | |
1467 | + | (arguments | |
1468 | + | `(#:jar-name "java-aspectj-weaver.jar" | |
1469 | + | #:source-dir "." | |
1470 | + | #:jdk ,icedtea-8 | |
1471 | + | #:tests? #f; no tests | |
1472 | + | #:phases | |
1473 | + | (modify-phases %standard-phases | |
1474 | + | (add-before 'configure 'unpack-jar | |
1475 | + | (lambda _ | |
1476 | + | (mkdir-p "weaver-src") | |
1477 | + | (chdir "weaver-src") | |
1478 | + | (zero? (system* "jar" "xf" "../src/aspectjweaver1.8.10-src.jar")))) | |
1479 | + | (add-after 'unpack-jar 'remove-propriatory | |
1480 | + | (lambda _ | |
1481 | + | ;; this file depends on JRockit, for which I can't find a free implementation | |
1482 | + | (delete-file "org/aspectj/weaver/loadtime/JRockitAgent.java"))) | |
1483 | + | (add-after 'unpack-jar 'rename-lib-back | |
1484 | + | (lambda _ | |
1485 | + | ;; aj.org.objectweb.asm is actually java-asm, renamed | |
1486 | + | (substitute* "org/aspectj/weaver/bcel/asm/StackMapAdder.java" | |
1487 | + | (("aj.org.objectweb.asm") "org.objectweb.asm")))) | |
1488 | + | (add-before 'build 'copy-ressource | |
1489 | + | (lambda _ | |
1490 | + | (mkdir-p "build/classes") | |
1491 | + | (copy-file "aspectj_1_5_0.dtd" "build/classes/aspectj_1_5_0.dtd")))))) | |
1492 | + | (inputs | |
1493 | + | `(("commons-logging" ,java-commons-logging-minimal) | |
1494 | + | ("asm" ,java-asm))) | |
1495 | + | (home-page "https://www.eclipse.org/aspectj") | |
1496 | + | (synopsis "") | |
1497 | + | (description "") | |
1498 | + | (license license:asl2.0))) | |
1499 | + | ||
1500 | + | (define java-xmlunit-test-resources | |
1501 | + | (origin | |
1502 | + | (method git-fetch) | |
1503 | + | (uri (git-reference | |
1504 | + | (url "https://github.com/xmlunit/test-resources.git") | |
1505 | + | (commit "a590d2ae865c3e0455691d76ba8eefccc2215aec"))) | |
1506 | + | (file-name "java-xmlunit-test-resources") | |
1507 | + | (sha256 | |
1508 | + | (base32 | |
1509 | + | "0r0glj37pg5l868yjz78gckr91cs8fysxxbp9p328dssssi91agr")))) | |
1510 | + | ||
1511 | + | (define-public java-xmlunit | |
1512 | + | (package | |
1513 | + | (name "java-xmlunit") | |
1514 | + | (version "2.4.0") | |
1515 | + | (source (origin | |
1516 | + | (method url-fetch) | |
1517 | + | (uri (string-append "https://github.com/xmlunit/xmlunit/archive/v" | |
1518 | + | version ".tar.gz")) | |
1519 | + | (sha256 | |
1520 | + | (base32 | |
1521 | + | "0gy9wbrg682m5j4p7xw2lvvp1p86vrki83kcl59h084z262ks2pl")))) | |
1522 | + | (build-system ant-build-system) | |
1523 | + | (arguments | |
1524 | + | `(#:jar-name "java-xmlunit.jar" | |
1525 | + | #:source-dir "xmlunit-core/src/main/java" | |
1526 | + | #:test-dir "xmlunit-core/src/test" | |
1527 | + | #:phases | |
1528 | + | (modify-phases %standard-phases | |
1529 | + | (add-before 'check 'copy-test-resources | |
1530 | + | (lambda* (#:key inputs #:allow-other-keys) | |
1531 | + | (let ((dir (string-append (getcwd) "/../test-resources/"))) | |
1532 | + | (with-directory-excursion (assoc-ref inputs "resources") | |
1533 | + | (for-each (lambda (file) | |
1534 | + | (mkdir-p (dirname (string-append dir file))) | |
1535 | + | (copy-file file (string-append dir file))) | |
1536 | + | (find-files "." ".*")))))) | |
1537 | + | (add-before 'check 'disable-non-tests | |
1538 | + | (lambda _ | |
1539 | + | ;; not really tests | |
1540 | + | (substitute* "build.xml" | |
1541 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1542 | + | (string-append "<include name=\"**/*Test.java\" />" | |
1543 | + | "<exclude name=\"**/Abstract*Test.java\" />")))))))) | |
1544 | + | (native-inputs | |
1545 | + | `(("junit" ,java-junit) | |
1546 | + | ("mockito" ,java-mockito-1) | |
1547 | + | ("hamcrest" ,java-hamcrest-all) | |
1548 | + | ("objenesis" ,java-objenesis) | |
1549 | + | ("asm" ,java-asm) | |
1550 | + | ("cglib" ,java-cglib) | |
1551 | + | ("resources" ,java-xmlunit-test-resources))) | |
1552 | + | (home-page "https://github.com/xmlunit/xmlunit") | |
1553 | + | (synopsis "") | |
1554 | + | (description "") | |
1555 | + | (license license:asl2.0))) | |
1556 | + | ||
1557 | + | (define-public java-xmlunit-legacy | |
1558 | + | (package | |
1559 | + | (inherit java-xmlunit) | |
1560 | + | (name "java-xmlunit-legacy") | |
1561 | + | (arguments | |
1562 | + | `(#:jar-name "java-xmlunit-legacy.jar" | |
1563 | + | #:source-dir "xmlunit-legacy/src/main/java" | |
1564 | + | #:test-dir "xmlunit-legacy/src/test")) | |
1565 | + | (inputs | |
1566 | + | `(("xmlunit" ,java-xmlunit) | |
1567 | + | ("junit" ,java-junit))) | |
1568 | + | (native-inputs | |
1569 | + | `(("mockito" ,java-mockito-1))))) | |
1570 | + | ||
1571 | + | (define-public java-spring-framework-core | |
1572 | + | (package | |
1573 | + | (name "java-spring-framework-core") | |
1574 | + | (version "4.3.10") | |
1575 | + | (source (origin | |
1576 | + | (method url-fetch) | |
1577 | + | (uri (string-append "https://github.com/spring-projects/" | |
1578 | + | "spring-framework/archive/v" version | |
1579 | + | ".RELEASE.tar.gz")) | |
1580 | + | (sha256 | |
1581 | + | (base32 | |
1582 | + | "13vbshq61cb6r37yb87rky1q16dzh5l76l9iiskgbzqpzp4igjk5")))) | |
1583 | + | (arguments | |
1584 | + | `(#:jar-name "java-spring-framework-core.jar" | |
1585 | + | #:jdk ,icedtea-8 | |
1586 | + | #:source-dir "src/main/java" | |
1587 | + | #:test-dir "src/test" | |
1588 | + | #:phases | |
1589 | + | (modify-phases %standard-phases | |
1590 | + | (add-before 'configure 'chdir | |
1591 | + | (lambda _ | |
1592 | + | ;; Needed because tests look for data in src/... directly. | |
1593 | + | (chdir "spring-core"))) | |
1594 | + | (add-before 'configure 'rename-dep | |
1595 | + | (lambda _ | |
1596 | + | (substitute* "src/main/java/org/springframework/objenesis/SpringObjenesis.java" | |
1597 | + | (("org.springframework.objenesis") "org.objenesis")))) | |
1598 | + | (add-before 'configure 'add-import | |
1599 | + | (lambda _ | |
1600 | + | (substitute* "src/main/java/org/springframework/cglib/core/SpringNamingPolicy.java" | |
1601 | + | (("public class") | |
1602 | + | "import net.sf.cglib.core.DefaultNamingPolicy;\npublic class")))) | |
1603 | + | (add-before 'check 'remove-log4j-1-dep | |
1604 | + | (lambda _ | |
1605 | + | ;; this tests requires log4j-1 (not log4j-1.2-api) | |
1606 | + | (delete-file "src/test/java/org/springframework/util/MockLog4jAppender.java") | |
1607 | + | (delete-file "src/test/java/org/springframework/util/Log4jConfigurerTests.java"))) | |
1608 | + | (add-before 'check 'select-tests | |
1609 | + | (lambda _ | |
1610 | + | (substitute* "build.xml" | |
1611 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1612 | + | (string-append "<include name=\"**/*Tests.java\" />" | |
1613 | + | ;; these tests fail | |
1614 | + | "<exclude name=\"**/LocalVariableTableParameterNameDiscovererTests.java\" />" | |
1615 | + | "<exclude name=\"**/StandardReflectionParameterNameDiscoverTests.java\" />" | |
1616 | + | "<exclude name=\"**/SpringFactoriesLoaderTests.java\" />" | |
1617 | + | "<exclude name=\"**/PropertySourceTests.java\" />" | |
1618 | + | "<exclude name=\"**/StaxEventXMLReaderTests.java\" />" | |
1619 | + | "<exclude name=\"**/StaxStreamHandlerTests.java\" />" | |
1620 | + | ;; Unable to set MockitoNamingPolicy on cglib generator which creates FastClasses | |
1621 | + | "<exclude name=\"**/util/StreamUtilsTests.java\" />" | |
1622 | + | "<exclude name=\"**/Abstract*.java\" />"))))) | |
1623 | + | (add-before 'check 'copy-test-resources | |
1624 | + | (lambda* (#:key inputs #:allow-other-keys) | |
1625 | + | (let ((dir (string-append (getcwd) "/build/test-classes/"))) | |
1626 | + | (with-directory-excursion "src/test/resources" | |
1627 | + | (for-each (lambda (file) | |
1628 | + | (mkdir-p (dirname (string-append dir file))) | |
1629 | + | (copy-file file (string-append dir file))) | |
1630 | + | (find-files "." ".*"))))))))) | |
1631 | + | (inputs | |
1632 | + | `(("logging" ,java-commons-logging-minimal) | |
1633 | + | ("java-jopt-simple" ,java-jopt-simple) | |
1634 | + | ("java-commons-codec" ,java-commons-codec) | |
1635 | + | ("java-log4j-1.2-api" ,java-log4j-1.2-api) | |
1636 | + | ("objenesis" ,java-objenesis) | |
1637 | + | ("cglib" ,java-cglib) | |
1638 | + | ("weaver" ,java-aspectj-weaver))) | |
1639 | + | (native-inputs | |
1640 | + | `(("junit" ,java-junit) | |
1641 | + | ("hamcrest" ,java-hamcrest-all) | |
1642 | + | ("asm" ,java-asm) | |
1643 | + | ("java-jboss-annotations-api-spec" ,java-jboss-annotations-api-spec) | |
1644 | + | ("java-xmlunit-legacy" ,java-xmlunit-legacy) | |
1645 | + | ("java-xmlunit" ,java-xmlunit) | |
1646 | + | ("java-mockito" ,java-mockito-1))) | |
1647 | + | (build-system ant-build-system) | |
1648 | + | (home-page "https://projects.spring.io/spring-framework/") | |
1649 | + | (synopsis "") | |
1650 | + | (description "") | |
1651 | + | (license license:asl2.0))) | |
1652 | + | ||
1653 | + | ;(define-public java-spring-framework-web | |
1654 | + | ; (package (inherit java-spring-framework-core) | |
1655 | + | ; (name "java-spring-framework-web") | |
1656 | + | ; (arguments | |
1657 | + | ; `(#:jar-name "java-spring-framework-web.jar" | |
1658 | + | ; #:jdk ,icedtea-8 | |
1659 | + | ; #:source-dir "spring-web/src/main/java" | |
1660 | + | ; #:test-dir "spring-web/src/test")) | |
1661 | + | ; (inputs | |
1662 | + | ; `(("core" ,java-spring-framework-core) | |
1663 | + | ; ("aspectj" ,java-aspectj-weaver) | |
1664 | + | ; ("tomcat" ,java-tomcat) | |
1665 | + | ; ("logging" ,java-commons-logging-minimal))) | |
1666 | + | ; (native-inputs '()))) | |
1667 | + | ; | |
1668 | + | ;(define-public java-spring-framework-test | |
1669 | + | ; (package (inherit java-spring-framework-core) | |
1670 | + | ; (name "java-spring-framework-test") | |
1671 | + | ; (arguments | |
1672 | + | ; `(#:jar-name "java-spring-framework-test.jar" | |
1673 | + | ; #:jdk ,icedtea-8 | |
1674 | + | ; #:source-dir "spring-test/src/main/java" | |
1675 | + | ; #:test-dir "spring-test/src/test")) | |
1676 | + | ; (inputs | |
1677 | + | ; `(("core" ,java-spring-framework-core) | |
1678 | + | ; ("http" ,java-spring-framework-web) | |
1679 | + | ; ("aspectj" ,java-aspectj-weaver) | |
1680 | + | ; ("tomcat" ,java-tomcat) | |
1681 | + | ; ("logging" ,java-commons-logging-minimal))) | |
1682 | + | ; (native-inputs '()))) | |
1683 | + | ; | |
1684 | + | ;(define-public java-spring-framework-aop | |
1685 | + | ; (package (inherit java-spring-framework-core) | |
1686 | + | ; (name "java-spring-framework-aop") | |
1687 | + | ; (arguments | |
1688 | + | ; `(#:jar-name "java-spring-framework-aop.jar" | |
1689 | + | ; #:jdk ,icedtea-8 | |
1690 | + | ; #:source-dir "spring-aop/src/main/java" | |
1691 | + | ; #:test-dir "spring-aop/src/test")) | |
1692 | + | ; (inputs | |
1693 | + | ; `(("core" ,java-spring-framework-core) | |
1694 | + | ; ("beans" ,java-spring-framework-beans) | |
1695 | + | ; ("aspectj" ,java-aspectj-weaver) | |
1696 | + | ; ("logging" ,java-commons-logging-minimal))) | |
1697 | + | ; (native-inputs '()))) | |
1698 | + | ; | |
1699 | + | ;(define-public java-spring-framework-beans | |
1700 | + | ; (package (inherit java-spring-framework-core) | |
1701 | + | ; (name "java-spring-framework-beans") | |
1702 | + | ; (arguments | |
1703 | + | ; `(#:jar-name "java-spring-framework-beans.jar" | |
1704 | + | ; #:jdk ,icedtea-8 | |
1705 | + | ; #:source-dir "spring-beans/src/main/java" | |
1706 | + | ; #:test-dir "spring-beans/src/test" | |
1707 | + | ; #:phases | |
1708 | + | ; (modify-phases %standard-phases | |
1709 | + | ; (add-before 'configure 'fix-dep | |
1710 | + | ; (lambda _ | |
1711 | + | ; (substitute* "spring-beans/src/main/java/org/springframework/beans/factory/support/CglibSubclassingInstantiationStrategy.java" | |
1712 | + | ; (("org.springframework.cglib.proxy") "net.sf.cglib.proxy") | |
1713 | + | ; (("org.springframework.cglib.core.ClassGenerator") | |
1714 | + | ; "net.sf.cglib.core.ClassGenerator") | |
1715 | + | ; (("org.springframework.cglib.core.DefaultGeneratorStrategy") | |
1716 | + | ; "net.sf.cglib.core.DefaultGeneratorStrategy"))))))) | |
1717 | + | ; (inputs | |
1718 | + | ; `(("core" ,java-spring-framework-core) | |
1719 | + | ; ("cglib" ,java-cglib) | |
1720 | + | ; ("inject" ,java-javax-inject) | |
1721 | + | ; ("snakeyaml" ,java-snakeyaml-notests) | |
1722 | + | ; ("el" ,java-jboss-el-api-spec) | |
1723 | + | ; ("aspectj" ,java-aspectj-weaver) | |
1724 | + | ; ("logging" ,java-commons-logging-minimal))) | |
1725 | + | ; (native-inputs | |
1726 | + | ; `(("junit" ,java-junit) | |
1727 | + | ; ("hamcrest" ,java-hamcrest-all) | |
1728 | + | ; ("test" ,java-spring-framework-test) | |
1729 | + | ; ("mockito" ,java-mockito-1))))) | |
1730 | + | ; | |
1731 | + | ;(define-public java-spring-framework-context | |
1732 | + | ; (package (inherit java-spring-framework-core) | |
1733 | + | ; (name "java-spring-framework-context") | |
1734 | + | ; (arguments | |
1735 | + | ; `(#:jar-name "java-spring-framework-context.jar" | |
1736 | + | ; #:jdk ,icedtea-8 | |
1737 | + | ; #:source-dir "spring-context/src/main/java" | |
1738 | + | ; #:test-dir "spring-context/src/test")) | |
1739 | + | ; (inputs | |
1740 | + | ; `(("java-aopalliance" ,java-aopalliance) | |
1741 | + | ; ("java-commons-logging" ,java-commons-logging-minimal) | |
1742 | + | ; ("java-spring-framework-aop" ,java-spring-framework-aop))) | |
1743 | + | ; (native-inputs '()))) | |
1744 | + | ||
1745 | + | ||
1746 | + | (define-public java-snakeyaml | |
1747 | + | (package | |
1748 | + | (name "java-snakeyaml") | |
1749 | + | (version "1.18") | |
1750 | + | (source (origin | |
1751 | + | (method url-fetch) | |
1752 | + | (uri (string-append "https://bitbucket.org/asomov/snakeyaml/get/v" | |
1753 | + | version ".tar.gz")) | |
1754 | + | (sha256 | |
1755 | + | (base32 | |
1756 | + | "0rf5ha6w0waz50jz2479jsrbgmd0dnx0gs337m126j5z7zlmg7mg")))) | |
1757 | + | (build-system ant-build-system) | |
1758 | + | (arguments | |
1759 | + | `(#:jar-name "java-snakeyaml.jar" | |
1760 | + | #:source-dir "src/main/java" | |
1761 | + | #:test-dir "src/test")) | |
1762 | + | (native-inputs | |
1763 | + | `(("junit" ,java-junit) | |
1764 | + | ("hamcrest" ,java-hamcrest-core) | |
1765 | + | ("joda-time" ,java-joda-time) | |
1766 | + | ("java-velocity" ,java-velocity))) | |
1767 | + | ;; FIXME: requires java-spring-framework-context | |
1768 | + | (home-page "https://bitbucket.org/asomov/snakeyaml") | |
1769 | + | (synopsis "") | |
1770 | + | (description "") | |
1771 | + | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
1772 | + | ||
1773 | + | (define java-snakeyaml-notests | |
1774 | + | (package (inherit java-snakeyaml) | |
1775 | + | (native-inputs '()) | |
1776 | + | (arguments | |
1777 | + | `(#:tests? #f | |
1778 | + | ,@(package-arguments java-snakeyaml))))) | |
1779 | + | ||
1780 | + | (define-public java-ops4j-lang | |
1781 | + | (package | |
1782 | + | (name "java-ops4j-lang") | |
1783 | + | (version "1.5.0") | |
1784 | + | (source (origin | |
1785 | + | (method url-fetch) | |
1786 | + | (uri (string-append "https://github.com/ops4j/org.ops4j.base/" | |
1787 | + | "archive/base-" version ".tar.gz")) | |
1788 | + | (sha256 | |
1789 | + | (base32 | |
1790 | + | "18hl3lpchgpv8yh5rlk39l2gif5dlfgb8gxjmncf39pr2dprkniw")))) | |
1791 | + | (build-system ant-build-system) | |
1792 | + | (arguments | |
1793 | + | `(#:jar-name "java-ops4j-lang.jar" | |
1794 | + | #:source-dir "ops4j-base-lang/src/main/java" | |
1795 | + | #:tests? #f)); no tests | |
1796 | + | (home-page "https://ops4j1.jira.com/wiki/spaces/base/overview") | |
1797 | + | (synopsis "") | |
1798 | + | (description "") | |
1799 | + | (license license:asl2.0))) | |
1800 | + | ||
1801 | + | (define-public java-ops4j-monitors | |
1802 | + | (package | |
1803 | + | (inherit java-ops4j-lang) | |
1804 | + | (name "java-ops4j-monitors") | |
1805 | + | (arguments | |
1806 | + | `(#:jar-name "java-ops4j-monitors.jar" | |
1807 | + | #:source-dir "ops4j-base-monitors/src/main/java" | |
1808 | + | #:tests? #f)); no tests | |
1809 | + | (inputs | |
1810 | + | `(("lang" ,java-ops4j-lang))))) | |
1811 | + | ||
1812 | + | (define-public java-ops4j-io | |
1813 | + | (package | |
1814 | + | (inherit java-ops4j-lang) | |
1815 | + | (name "java-ops4j-io") | |
1816 | + | (arguments | |
1817 | + | `(#:jar-name "java-ops4j-io.jar" | |
1818 | + | #:source-dir "ops4j-base-io/src/main/java" | |
1819 | + | #:test-dir "ops4j-base-io/src/test" | |
1820 | + | #:phases | |
1821 | + | (modify-phases %standard-phases | |
1822 | + | (add-before 'check 'disable-failing | |
1823 | + | (lambda _ | |
1824 | + | (substitute* "build.xml" | |
1825 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
1826 | + | (string-append "<include name=\"**/*Test.java\" />" | |
1827 | + | "<exclude name=\"**/ListerTest.java\" />")))))))) | |
1828 | + | (inputs | |
1829 | + | `(("lang" ,java-ops4j-monitors) | |
1830 | + | ("lang" ,java-ops4j-lang))) | |
1831 | + | (native-inputs | |
1832 | + | `(("junit" ,java-junit) | |
1833 | + | ("hamcrest" ,java-hamcrest-core))))) | |
1834 | + | ||
1835 | + | (define-public java-ops4j-util | |
1836 | + | (package | |
1837 | + | (inherit java-ops4j-lang) | |
1838 | + | (name "java-ops4j-util") | |
1839 | + | (arguments | |
1840 | + | `(#:jar-name "java-ops4j-util.jar" | |
1841 | + | #:source-dir "ops4j-base-util/src/main/java" | |
1842 | + | #:test-dir "ops4j-base-util/src/test")) | |
1843 | + | (inputs | |
1844 | + | `(("lang" ,java-ops4j-lang))) | |
1845 | + | (native-inputs | |
1846 | + | `(("junit" ,java-junit))))) | |
1847 | + | ||
1848 | + | (define-public java-ops4j-util-property | |
1849 | + | (package | |
1850 | + | (inherit java-ops4j-lang) | |
1851 | + | (name "java-ops4j-util-property") | |
1852 | + | (arguments | |
1853 | + | `(#:jar-name "java-ops4j-util-property.jar" | |
1854 | + | #:source-dir "ops4j-base-util-property/src/main/java" | |
1855 | + | #:tests? #f)); no tests | |
1856 | + | (inputs | |
1857 | + | `(("lang" ,java-ops4j-lang) | |
1858 | + | ("util" ,java-ops4j-util))))) | |
1859 | + | ||
1860 | + | (define-public java-ops4j-store | |
1861 | + | (package | |
1862 | + | (inherit java-ops4j-lang) | |
1863 | + | (name "java-ops4j-store") | |
1864 | + | (arguments | |
1865 | + | `(#:jar-name "java-ops4j-store.jar" | |
1866 | + | #:source-dir "ops4j-base-store/src/main/java" | |
1867 | + | #:tests? #f)); no tests | |
1868 | + | (inputs | |
1869 | + | `(("lang" ,java-ops4j-lang) | |
1870 | + | ("slf4j" ,java-slf4j-api) | |
1871 | + | ("io" ,java-ops4j-io))))) | |
1872 | + | ||
1873 | + | (define-public java-ops4j-spi | |
1874 | + | (package | |
1875 | + | (inherit java-ops4j-lang) | |
1876 | + | (name "java-ops4j-spi") | |
1877 | + | (arguments | |
1878 | + | `(#:jar-name "java-ops4j-spi.jar" | |
1879 | + | #:source-dir "ops4j-base-spi/src/main/java" | |
1880 | + | #:test-dir "ops4j-base-spi/src/test")) | |
1881 | + | (native-inputs | |
1882 | + | `(("junit" ,java-junit) | |
1883 | + | ("hamcrest" ,java-hamcrest-core))))) | |
1884 | + | ||
1885 | + | (define java-asm-old | |
1886 | + | (package | |
1887 | + | (inherit java-asm) | |
1888 | + | (version "3.3.1") | |
1889 | + | (source (origin | |
1890 | + | (method url-fetch) | |
1891 | + | (uri (string-append "http://download.forge.ow2.org/asm/asm-" | |
1892 | + | version ".tar.gz")) | |
1893 | + | (sha256 | |
1894 | + | (base32 | |
1895 | + | "1xcp06wbqqq4jm93pafjw5jc08vy30qiw9s7kff9gmw23ka279b9")))))) | |
1896 | + | ||
1897 | + | (define-public java-microemulator | |
1898 | + | (package | |
1899 | + | (name "java-microemulator") | |
1900 | + | (version "2.0.4") | |
1901 | + | (source (origin | |
1902 | + | (method url-fetch) | |
1903 | + | (uri (string-append "mirror://sourceforge/microemulator/microemulator/" | |
1904 | + | version "/microemulator-" version ".zip")) | |
1905 | + | (sha256 | |
1906 | + | (base32 | |
1907 | + | "0x9a4xqw6747c130y2znfwg945jgpjnd4bzj5gdamxmi7848dslb")))) | |
1908 | + | (build-system ant-build-system) | |
1909 | + | (arguments | |
1910 | + | `(#:jar-name "microemulator.jar" | |
1911 | + | #:source-dir "src" | |
1912 | + | #:tests? #f; no tests | |
1913 | + | #:phases | |
1914 | + | (modify-phases %standard-phases | |
1915 | + | (add-before 'configure 'unpack-jar | |
1916 | + | (lambda _ | |
1917 | + | (mkdir-p "src") | |
1918 | + | (with-directory-excursion "src" | |
1919 | + | (zero? (system* "jar" "xf" "../microemulator-sources.jar"))))) | |
1920 | + | (add-before 'configure 'remove-old-dep | |
1921 | + | (lambda _ | |
1922 | + | ;; requires netscape.javascript for which I can't find a free implementation | |
1923 | + | (delete-file "src/org/microemu/applet/CookieRecordStoreManager.java") | |
1924 | + | ;; requires an old version of swt | |
1925 | + | (delete-file "src/org/microemu/app/Swt.java")))))) | |
1926 | + | (inputs | |
1927 | + | `(("java-swt" ,java-swt) | |
1928 | + | ("asm" ,java-asm-old))) | |
1929 | + | (native-inputs | |
1930 | + | `(("unzip" ,unzip))) | |
1931 | + | (home-page "https://sourceforge.net/projects/microemulator/") | |
1932 | + | (synopsis "") | |
1933 | + | (description "") | |
1934 | + | (license license:asl2.0))) | |
1935 | + | ||
1936 | + | (define-public java-osgi-cmpn | |
1937 | + | (package | |
1938 | + | (name "java-osgi-cmpn") | |
1939 | + | (version "6.0.0") | |
1940 | + | (source (origin | |
1941 | + | (method url-fetch) | |
1942 | + | (uri (string-append "http://central.maven.org/maven2/" | |
1943 | + | "org/osgi/osgi.cmpn/" version "/osgi.cmpn-" | |
1944 | + | version "-sources.jar")) | |
1945 | + | (sha256 | |
1946 | + | (base32 | |
1947 | + | "1lmb6xyrmkqdhv1kayf0514rlwq6ypvs4m44ibrck3snp8241wys")))) | |
1948 | + | (build-system ant-build-system) | |
1949 | + | (arguments | |
1950 | + | `(#:jar-name "osgi-cmpn.jar" | |
1951 | + | #:tests? #f)); no tests | |
1952 | + | (inputs | |
1953 | + | `(("annotation" ,java-osgi-annotation) | |
1954 | + | ("core" ,java-osgi-core) | |
1955 | + | ("java-datanucleus-javax-persistence" ,java-datanucleus-javax-persistence) | |
1956 | + | ("microemulator" ,java-microemulator) | |
1957 | + | ("tomcat" ,java-tomcat))) | |
1958 | + | (home-page "http://www.osgi.org") | |
1959 | + | (synopsis "Compendium specification module of OSGi framework") | |
1960 | + | (description | |
1961 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
1962 | + | and service platform for the Java programming language. This package contains | |
1963 | + | the compendium specification module, providing interfaces and classes for use | |
1964 | + | in compiling bundles.") | |
1965 | + | (license license:asl2.0))) | |
1966 | + | ||
1967 | + | (define-public java-osgi-service-component-annotations | |
1968 | + | (package | |
1969 | + | (name "java-osgi-service-component-annotations") | |
1970 | + | (version "1.3.0") | |
1971 | + | (source (origin | |
1972 | + | (method url-fetch) | |
1973 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
1974 | + | "org.osgi.service.component.annotations/" | |
1975 | + | version "/org.osgi.service.component.annotations-" | |
1976 | + | version "-sources.jar")) | |
1977 | + | (sha256 | |
1978 | + | (base32 | |
1979 | + | "15rq9cmp4fpn74q44m4j35qsqmjf5lx3hcrk6pzvbhc08igic2f0")))) | |
1980 | + | (build-system ant-build-system) | |
1981 | + | (arguments | |
1982 | + | `(#:jar-name "osgi-service-component-annotations.jar" | |
1983 | + | #:tests? #f)); no tests | |
1984 | + | (inputs | |
1985 | + | `(("annotation" ,java-osgi-annotation))) | |
1986 | + | (home-page "http://www.osgi.org") | |
1987 | + | (synopsis "Support annotations for osgi-service-component") | |
1988 | + | (description | |
1989 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
1990 | + | and service platform for the Java programming language. This package contains | |
1991 | + | the support annotations for osgi-service-component.") | |
1992 | + | (license license:asl2.0))) | |
1993 | + | ||
1994 | + | (define-public java-osgi-dto | |
1995 | + | (package | |
1996 | + | (name "java-osgi-dto") | |
1997 | + | (version "1.0.0") | |
1998 | + | (source (origin | |
1999 | + | (method url-fetch) | |
2000 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2001 | + | "org.osgi.dto/" version "/org.osgi.dto-" | |
2002 | + | version "-sources.jar")) | |
2003 | + | (sha256 | |
2004 | + | (base32 | |
2005 | + | "0f4bqjzadn0hwk6sd3h5gvbyfp3yci1s6r0v770cc15p0pg627yr")))) | |
2006 | + | (build-system ant-build-system) | |
2007 | + | (arguments | |
2008 | + | `(#:jar-name "osgi-resource.jar" | |
2009 | + | #:tests? #f)); no tests | |
2010 | + | (inputs | |
2011 | + | `(("annotation" ,java-osgi-annotation))) | |
2012 | + | (home-page "http://www.osgi.org") | |
2013 | + | (synopsis "") | |
2014 | + | (description "") | |
2015 | + | (license license:asl2.0))) | |
2016 | + | ||
2017 | + | (define-public java-osgi-resource | |
2018 | + | (package | |
2019 | + | (name "java-osgi-resource") | |
2020 | + | (version "1.0.0") | |
2021 | + | (source (origin | |
2022 | + | (method url-fetch) | |
2023 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2024 | + | "org.osgi.resource/" | |
2025 | + | version "/org.osgi.resource-" | |
2026 | + | version "-sources.jar")) | |
2027 | + | (sha256 | |
2028 | + | (base32 | |
2029 | + | "0hi0fsc5v99q22bd7lrkvpz1y0ds4w9arjldpwsrcpqvz2js7q2d")))) | |
2030 | + | (build-system ant-build-system) | |
2031 | + | (arguments | |
2032 | + | `(#:jar-name "osgi-resource.jar" | |
2033 | + | #:tests? #f)); no tests | |
2034 | + | (inputs | |
2035 | + | `(("annotation" ,java-osgi-annotation) | |
2036 | + | ("dto" ,java-osgi-dto))) | |
2037 | + | (home-page "http://www.osgi.org") | |
2038 | + | (synopsis "") | |
2039 | + | (description "") | |
2040 | + | (license license:asl2.0))) | |
2041 | + | ||
2042 | + | (define-public java-osgi-namespace-contract | |
2043 | + | (package | |
2044 | + | (name "java-osgi-namespace-contract") | |
2045 | + | (version "1.0.0") | |
2046 | + | (source (origin | |
2047 | + | (method url-fetch) | |
2048 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2049 | + | "org.osgi.namespace.contract/" | |
2050 | + | version "/org.osgi.namespace.contract-" | |
2051 | + | version "-sources.jar")) | |
2052 | + | (sha256 | |
2053 | + | (base32 | |
2054 | + | "1iz4f2i0fvqrlq90ki9nfzcfpvy2av434ri25bglywqssx8mmp36")))) | |
2055 | + | (build-system ant-build-system) | |
2056 | + | (inputs | |
2057 | + | `(("resource" ,java-osgi-resource) | |
2058 | + | ("annotation" ,java-osgi-annotation))) | |
2059 | + | (arguments | |
2060 | + | `(#:jar-name "osgi-namespace-contract.jar" | |
2061 | + | #:tests? #f)); no tests | |
2062 | + | (home-page "http://www.osgi.org") | |
2063 | + | (synopsis "") | |
2064 | + | (description "") | |
2065 | + | (license license:asl2.0))) | |
2066 | + | ||
2067 | + | (define-public java-osgi-namespace-extender | |
2068 | + | (package | |
2069 | + | (name "java-osgi-namespace-extender") | |
2070 | + | (version "1.0.1") | |
2071 | + | (source (origin | |
2072 | + | (method url-fetch) | |
2073 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2074 | + | "org.osgi.namespace.extender/" | |
2075 | + | version "/org.osgi.namespace.extender-" | |
2076 | + | version "-sources.jar")) | |
2077 | + | (sha256 | |
2078 | + | (base32 | |
2079 | + | "0jgqiak2i05qv6j3gd33xlaifzzc0ylxxk376v2x0apfg3vvixmz")))) | |
2080 | + | (build-system ant-build-system) | |
2081 | + | (inputs | |
2082 | + | `(("resource" ,java-osgi-resource) | |
2083 | + | ("annotation" ,java-osgi-annotation))) | |
2084 | + | (arguments | |
2085 | + | `(#:jar-name "osgi-namespace-contract.jar" | |
2086 | + | #:tests? #f)); no tests | |
2087 | + | (home-page "http://www.osgi.org") | |
2088 | + | (synopsis "") | |
2089 | + | (description "") | |
2090 | + | (license license:asl2.0))) | |
2091 | + | ||
2092 | + | (define-public java-osgi-namespace-service | |
2093 | + | (package | |
2094 | + | (name "java-osgi-namespace-service") | |
2095 | + | (version "1.0.0") | |
2096 | + | (source (origin | |
2097 | + | (method url-fetch) | |
2098 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2099 | + | "org.osgi.namespace.service/" | |
2100 | + | version "/org.osgi.namespace.service-" | |
2101 | + | version "-sources.jar")) | |
2102 | + | (sha256 | |
2103 | + | (base32 | |
2104 | + | "0qmw8n2449nkmm56d1znz9zhazb6ya3vsimd5bf5jg23zzhgl8c8")))) | |
2105 | + | (build-system ant-build-system) | |
2106 | + | (inputs | |
2107 | + | `(("resource" ,java-osgi-resource) | |
2108 | + | ("annotation" ,java-osgi-annotation))) | |
2109 | + | (arguments | |
2110 | + | `(#:jar-name "osgi-namespace-contract.jar" | |
2111 | + | #:tests? #f)); no tests | |
2112 | + | (home-page "http://www.osgi.org") | |
2113 | + | (synopsis "") | |
2114 | + | (description "") | |
2115 | + | (license license:asl2.0))) | |
2116 | + | ||
2117 | + | (define-public java-osgi-util-function | |
2118 | + | (package | |
2119 | + | (name "java-osgi-util-function") | |
2120 | + | (version "1.0.0") | |
2121 | + | (source (origin | |
2122 | + | (method url-fetch) | |
2123 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2124 | + | "org.osgi.util.function/" | |
2125 | + | version "/org.osgi.util.function-" | |
2126 | + | version "-sources.jar")) | |
2127 | + | (sha256 | |
2128 | + | (base32 | |
2129 | + | "04l7j3hwmmj28w23m7paca0afzncs42j2mdr3liqq8kvp548sc6x")))) | |
2130 | + | (build-system ant-build-system) | |
2131 | + | (arguments | |
2132 | + | `(#:jar-name "osgi-util-function.jar" | |
2133 | + | #:tests? #f)); no tests | |
2134 | + | (inputs | |
2135 | + | `(("annotation" ,java-osgi-annotation))) | |
2136 | + | (home-page "http://www.osgi.org") | |
2137 | + | (synopsis "") | |
2138 | + | (description "") | |
2139 | + | (license license:asl2.0))) | |
2140 | + | ||
2141 | + | (define-public java-osgi-util-promise | |
2142 | + | (package | |
2143 | + | (name "java-osgi-util-promise") | |
2144 | + | (version "1.0.0") | |
2145 | + | (source (origin | |
2146 | + | (method url-fetch) | |
2147 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2148 | + | "org.osgi.util.promise/" | |
2149 | + | version "/org.osgi.util.promise-" | |
2150 | + | version "-sources.jar")) | |
2151 | + | (sha256 | |
2152 | + | (base32 | |
2153 | + | "0y34dwiflg1c4ahvkswpf9z02xph2sr9fm04ia5493x3lshpw22c")))) | |
2154 | + | (build-system ant-build-system) | |
2155 | + | (arguments | |
2156 | + | `(#:jar-name "osgi-util-promise.jar" | |
2157 | + | #:tests? #f)); no tests | |
2158 | + | (inputs | |
2159 | + | `(("annotation" ,java-osgi-annotation) | |
2160 | + | ("function" ,java-osgi-util-function))) | |
2161 | + | (home-page "http://www.osgi.org") | |
2162 | + | (synopsis "") | |
2163 | + | (description "") | |
2164 | + | (license license:asl2.0))) | |
2165 | + | ||
2166 | + | (define-public java-osgi-service-metatype-annotations | |
2167 | + | (package | |
2168 | + | (name "java-osgi-service-metatype-annotations") | |
2169 | + | (version "1.3.0") | |
2170 | + | (source (origin | |
2171 | + | (method url-fetch) | |
2172 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2173 | + | "org.osgi.service.metatype.annotations/" | |
2174 | + | version "/org.osgi.service.metatype.annotations-" | |
2175 | + | version "-sources.jar")) | |
2176 | + | (sha256 | |
2177 | + | (base32 | |
2178 | + | "12rwm3349wk80vm88rcdgs4435m4jxkpkj5mrx326skkz2c6hyw6")))) | |
2179 | + | (build-system ant-build-system) | |
2180 | + | (arguments | |
2181 | + | `(#:jar-name "osgi-service-metatype-annotations.jar" | |
2182 | + | #:tests? #f)); no tests | |
2183 | + | (inputs | |
2184 | + | `(("annotation" ,java-osgi-annotation))) | |
2185 | + | (home-page "http://www.osgi.org") | |
2186 | + | (synopsis "Support annotations for metatype") | |
2187 | + | (description | |
2188 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
2189 | + | and service platform for the Java programming language. This package contains | |
2190 | + | the support annotations for metatype.") | |
2191 | + | (license license:asl2.0))) | |
2192 | + | ||
2193 | + | (define-public java-osgi-service-repository | |
2194 | + | (package | |
2195 | + | (name "java-osgi-service-repository") | |
2196 | + | (version "1.1.0") | |
2197 | + | (source (origin | |
2198 | + | (method url-fetch) | |
2199 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2200 | + | "org.osgi.service.repository/" | |
2201 | + | version "/org.osgi.service.repository-" | |
2202 | + | version "-sources.jar")) | |
2203 | + | (sha256 | |
2204 | + | (base32 | |
2205 | + | "1k41mhg7b58pd8nsghr2qwcjrxdnf1p9spsw9v11k4257g6rl06n")))) | |
2206 | + | (build-system ant-build-system) | |
2207 | + | (arguments | |
2208 | + | `(#:jar-name "osgi-service-repository.jar" | |
2209 | + | #:tests? #f)); no tests | |
2210 | + | (inputs | |
2211 | + | `(("annotation" ,java-osgi-annotation) | |
2212 | + | ("promise" ,java-osgi-util-promise) | |
2213 | + | ("resource" ,java-osgi-resource))) | |
2214 | + | (home-page "http://www.osgi.org") | |
2215 | + | (synopsis "service-repository") | |
2216 | + | (description | |
2217 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
2218 | + | and service platform for the Java programming language. This package contains | |
2219 | + | the service-repository.") | |
2220 | + | (license license:asl2.0))) | |
2221 | + | ||
2222 | + | (define-public java-osgi-framework | |
919 | 2223 | (package | |
920 | - | (name "java-fasterxml-jackson-databind") | |
921 | - | (version "2.9.0") | |
2224 | + | (name "java-osgi-framework") | |
2225 | + | (version "1.8.0") | |
922 | 2226 | (source (origin | |
923 | 2227 | (method url-fetch) | |
924 | - | (uri (string-append "https://github.com/FasterXML/" | |
925 | - | "jackson-databind/archive/" | |
926 | - | "jackson-databind-" version ".tar.gz")) | |
2228 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2229 | + | "org.osgi.framework/" version "/org.osgi.framework-" | |
2230 | + | version "-sources.jar")) | |
927 | 2231 | (sha256 | |
928 | 2232 | (base32 | |
929 | - | "01a60dwy1q11xizvimphmhjfbk41rwar3rl1q3xcwlhic2vdw147")))) | |
2233 | + | "1lwp2zfad3rybcc6q9bwz8xsgkc92ypzy5p6x54387f1qj65m73s")))) | |
930 | 2234 | (build-system ant-build-system) | |
931 | 2235 | (arguments | |
932 | - | `(#:jar-name "jackson-databind.jar" | |
933 | - | #:source-dir "src/main/java" | |
934 | - | #:tests? #f; how to run them? src/test/java | |
935 | - | #:phases | |
936 | - | (modify-phases %standard-phases | |
937 | - | (add-before 'configure 'generate-PackageVersion.java | |
938 | - | (lambda _ | |
939 | - | (let* ((out "src/main/java/com/fasterxml/jackson/databind/cfg/PackageVersion.java") | |
940 | - | (in (string-append out ".in"))) | |
941 | - | (copy-file in out) | |
942 | - | (substitute* out | |
943 | - | (("@package@") "com.fasterxml.jackson.databind.cfg") | |
944 | - | (("@projectversion@") ,version) | |
945 | - | (("@projectgroupid@") "com.fasterxml.jackson.databind") | |
946 | - | (("@projectartifactid@") "jackson-databind")))))))) | |
2236 | + | `(#:jar-name "osgi-framework.jar" | |
2237 | + | #:tests? #f)); no tests | |
947 | 2238 | (inputs | |
948 | - | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
949 | - | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core))) | |
950 | - | (home-page "https://github.com/FasterXML/jackson-databind") | |
951 | - | (synopsis "") | |
952 | - | (description "") | |
953 | - | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
2239 | + | `(("annotation" ,java-osgi-annotation) | |
2240 | + | ("resource" ,java-osgi-resource) | |
2241 | + | ("dto" ,java-osgi-dto))) | |
2242 | + | (home-page "http://www.osgi.org") | |
2243 | + | (synopsis "OSGi framework") | |
2244 | + | (description | |
2245 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
2246 | + | and service platform for the Java programming language.") | |
2247 | + | (license license:asl2.0))) | |
954 | 2248 | ||
955 | - | (define-public java-fasterxml-jackson-modules-base | |
2249 | + | (define-public java-osgi-service-log | |
956 | 2250 | (package | |
957 | - | (name "java-fasterxml-jackson-modules-base") | |
958 | - | (version "2.9.0") | |
2251 | + | (name "java-osgi-service-log") | |
2252 | + | (version "1.3.0") | |
959 | 2253 | (source (origin | |
960 | 2254 | (method url-fetch) | |
961 | - | (uri (string-append "https://github.com/FasterXML/" | |
962 | - | "jackson-modules-base/archive/" | |
963 | - | "jackson-modules-base-" version ".tar.gz")) | |
2255 | + | (uri (string-append "http://central.maven.org/maven2/org/osgi/" | |
2256 | + | "org.osgi.service.log/" | |
2257 | + | version "/org.osgi.service.log-" | |
2258 | + | version "-sources.jar")) | |
964 | 2259 | (sha256 | |
965 | 2260 | (base32 | |
966 | - | "054f1rk3k7way7d2a67q2j81yi33n1q9l4rp14jb864y46zdaayy")))) | |
2261 | + | "1029j30dzcwializzca0j3fkhwwz08kmmsha5agw1iccscimj6r0")))) | |
967 | 2262 | (build-system ant-build-system) | |
968 | 2263 | (arguments | |
969 | - | `(#:jar-name "jackson-modules-base.jar" | |
970 | - | #:source-dir "jaxb/src/main/java" | |
971 | - | #:tests? #f; how to run them? src/test/java | |
972 | - | #:phases | |
973 | - | (modify-phases %standard-phases | |
974 | - | (add-before 'configure 'generate-PackageVersion.java | |
975 | - | (lambda _ | |
976 | - | (let* ((out (string-append "jaxb/src/main/java/com/fasterxml/" | |
977 | - | "jackson/module/jaxb/PackageVersion.java")) | |
978 | - | (in (string-append out ".in"))) | |
979 | - | (copy-file in out) | |
980 | - | (substitute* out | |
981 | - | (("@package@") "com.fasterxml.jackson.module.jaxb") | |
982 | - | (("@projectversion@") ,version) | |
983 | - | (("@projectgroupid@") "com.fasterxml.jackson.module.jaxb") | |
984 | - | (("@projectartifactid@") "jackson-module-jaxb")))))))) | |
2264 | + | `(#:jar-name "osgi-service-log.jar" | |
2265 | + | #:tests? #f)); no tests | |
985 | 2266 | (inputs | |
986 | - | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
987 | - | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core) | |
988 | - | ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind))) | |
989 | - | (home-page "https://github.com/FasterXML/jackson-dataformat-xml") | |
990 | - | (synopsis "") | |
991 | - | (description "") | |
992 | - | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
2267 | + | `(("java-osgi-framework" ,java-osgi-framework))) | |
2268 | + | (home-page "http://www.osgi.org") | |
2269 | + | (synopsis "service-log") | |
2270 | + | (description | |
2271 | + | "OSGi, for Open Services Gateway initiative framework, is a module system | |
2272 | + | and service platform for the Java programming language. This package contains | |
2273 | + | the service-log.") | |
2274 | + | (license license:asl2.0))) | |
993 | 2275 | ||
994 | - | (define-public java-fasterxml-jackson-dataformat-xml | |
2276 | + | (define-public java-aqute-bndlib | |
995 | 2277 | (package | |
996 | - | (name "java-fasterxml-jackson-dataformat-xml") | |
997 | - | (version "2.9.0") | |
2278 | + | (name "java-aqute-bndlib") | |
2279 | + | (version "3.4.0") | |
998 | 2280 | (source (origin | |
999 | 2281 | (method url-fetch) | |
1000 | - | (uri (string-append "https://github.com/FasterXML/" | |
1001 | - | "jackson-dataformat-xml/archive/" | |
1002 | - | "jackson-dataformat-xml-" version ".tar.gz")) | |
2282 | + | (uri (string-append "https://github.com/bndtools/bnd/archive/" | |
2283 | + | version ".REL.tar.gz")) | |
1003 | 2284 | (sha256 | |
1004 | 2285 | (base32 | |
1005 | - | "1iv8brs68szk2d4fghji1bgg5g8fcc4y1yp363phiy794f40vxfc")))) | |
2286 | + | "158c9250v1q07hvj6v30lja4gq1s3y0v94j281rghz82lilwzb07")))) | |
1006 | 2287 | (build-system ant-build-system) | |
1007 | 2288 | (arguments | |
1008 | - | `(#:jar-name "jackson-dataformat-xml.jar" | |
1009 | - | #:source-dir "src/main/java" | |
1010 | - | #:tests? #f; how to run them? src/test/java | |
1011 | - | #:phases | |
1012 | - | (modify-phases %standard-phases | |
1013 | - | (add-before 'configure 'generate-PackageVersion.java | |
1014 | - | (lambda _ | |
1015 | - | (let* ((out "src/main/java/com/fasterxml/jackson/dataformat/xml/PackageVersion.java") | |
1016 | - | (in (string-append out ".in"))) | |
1017 | - | (copy-file in out) | |
1018 | - | (substitute* out | |
1019 | - | (("@package@") "com.fasterxml.jackson.dataformat.xml") | |
1020 | - | (("@projectversion@") ,version) | |
1021 | - | (("@projectgroupid@") "com.fasterxml.jackson.dataformat.xml") | |
1022 | - | (("@projectartifactid@") "jackson-dataformat-xml")))))))) | |
2289 | + | `(#:jar-name "java-bndlib.jar" | |
2290 | + | #:source-dir "biz.aQute.bndlib/src" | |
2291 | + | #:tests? #f)); no tests | |
1023 | 2292 | (inputs | |
1024 | - | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
1025 | - | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core) | |
1026 | - | ("java-fasterxml-jackson-modules-base" ,java-fasterxml-jackson-modules-base) | |
1027 | - | ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind) | |
1028 | - | ("java-stax2-api" ,java-stax2-api))) | |
1029 | - | (home-page "https://github.com/FasterXML/jackson-dataformat-xml") | |
2293 | + | `(("slf4j" ,java-slf4j-api) | |
2294 | + | ("osgi-annot" ,java-osgi-annotation) | |
2295 | + | ("java-aqute-libg" ,java-aqute-libg) | |
2296 | + | ("java-aqute-bnd-annotation" ,java-aqute-bnd-annotation) | |
2297 | + | ("java-osgi-service-component-annotations" ,java-osgi-service-component-annotations) | |
2298 | + | ("java-osgi-service-repository" ,java-osgi-service-repository) | |
2299 | + | ("java-osgi-service-log" ,java-osgi-service-log) | |
2300 | + | ("java-osgi-service-metatype-annotations" ,java-osgi-service-metatype-annotations) | |
2301 | + | ("java-osgi-namespace-contract" ,java-osgi-namespace-contract) | |
2302 | + | ("java-osgi-namespace-extender" ,java-osgi-namespace-extender) | |
2303 | + | ("java-osgi-namespace-service" ,java-osgi-namespace-service) | |
2304 | + | ("promise" ,java-osgi-util-promise) | |
2305 | + | ("osgi" ,java-osgi-core))) | |
2306 | + | (home-page "") | |
1030 | 2307 | (synopsis "") | |
1031 | 2308 | (description "") | |
1032 | - | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
2309 | + | (license license:asl2.0))) | |
1033 | 2310 | ||
1034 | - | (define-public java-stax2-api | |
2311 | + | (define-public java-aqute-libg | |
1035 | 2312 | (package | |
1036 | - | (name "java-stax2-api") | |
1037 | - | (version "4.0.0") | |
2313 | + | (inherit java-aqute-bndlib) | |
2314 | + | (name "java-aqute-libg") | |
2315 | + | (arguments | |
2316 | + | `(#:jar-name "java-aqute-libg.jar" | |
2317 | + | #:source-dir "aQute.libg/src" | |
2318 | + | #:tests? #f)); actually in "aQute.libg/test", not in .../java | |
2319 | + | (inputs | |
2320 | + | `(("slf4j" ,java-slf4j-api) | |
2321 | + | ("osgi-annot" ,java-osgi-annotation) | |
2322 | + | ("java-osgi-cmpn" ,java-osgi-cmpn) | |
2323 | + | ("osgi" ,java-osgi-core))))) | |
2324 | + | ||
2325 | + | (define-public java-aqute-bnd-annotation | |
2326 | + | (package | |
2327 | + | (inherit java-aqute-bndlib) | |
2328 | + | (name "java-aqute-bnd-annotation") | |
2329 | + | (arguments | |
2330 | + | `(#:jar-name "java-aqute-bnd-annotation.jar" | |
2331 | + | #:source-dir "biz.aQute.bnd.annotation/src" | |
2332 | + | #:tests? #f)); empty test dir | |
2333 | + | (inputs '()))) | |
2334 | + | ||
2335 | + | (define-public java-ops4j-pax-tinybundles | |
2336 | + | (package | |
2337 | + | (name "java-ops4j-pax-tinybundles") | |
2338 | + | (version "2.1.1") | |
1038 | 2339 | (source (origin | |
1039 | 2340 | (method url-fetch) | |
1040 | - | (uri (string-append "https://github.com/FasterXML/stax2-api/archive/" | |
1041 | - | "stax2-api-" version ".tar.gz")) | |
2341 | + | (uri (string-append "https://github.com/ops4j/org.ops4j.pax.tinybundles/" | |
2342 | + | "archive/tinybundles-" version ".tar.gz")) | |
1042 | 2343 | (sha256 | |
1043 | 2344 | (base32 | |
1044 | - | "1amc1si0l0hyyw2sawmnzy4hkna3z6fp195y4nm5m9wb9ld5awkq")))) | |
1045 | - | (build-system ant-build-system) | |
2345 | + | "0y0gq3pvv0iir2b885lmlwnvr724vv7vklzhhr4fs27d7mdkj871")))) | |
1046 | 2346 | (arguments | |
1047 | - | `(#:jar-name "java-stax2-api.jar" | |
1048 | - | #:source-dir "src/main/java" | |
1049 | - | #:tests? #f)) | |
1050 | - | (home-page "https://github.com/FasterXML/stax2-api") | |
2347 | + | `(#:jar-name "java-ops4j-pax-tinybundles.jar" | |
2348 | + | #:source-dir "src/main/java")) | |
2349 | + | (inputs | |
2350 | + | `(("lang" ,java-ops4j-lang) | |
2351 | + | ("io" ,java-ops4j-io) | |
2352 | + | ("store" ,java-ops4j-store) | |
2353 | + | ("slf4j" ,java-slf4j-api) | |
2354 | + | ("libg" ,java-aqute-libg) | |
2355 | + | ("bndlib" ,java-aqute-bndlib))) | |
2356 | + | (native-inputs | |
2357 | + | `(("junit" ,java-junit) | |
2358 | + | ("hamcrest" ,java-hamcrest-core) | |
2359 | + | ("framework" ,java-osgi-framework))) | |
2360 | + | (build-system ant-build-system) | |
2361 | + | (home-page "https://ops4j1.jira.com/wiki/spaces/ops4j/pages/12060312/Tinybundles") | |
1051 | 2362 | (synopsis "") | |
1052 | 2363 | (description "") | |
1053 | 2364 | (license license:asl2.0))) | |
1054 | 2365 | ||
1055 | - | ;(define-public java-woodstox | |
1056 | - | ; (package | |
1057 | - | ; (name "java-woodstox") | |
1058 | - | ; (version "5.0.3") | |
1059 | - | ; (source (origin | |
1060 | - | ; (method url-fetch) | |
1061 | - | ; (uri (string-append "https://github.com/FasterXML/woodstox/archive/" | |
1062 | - | ; "woodstox-core-" version ".tar.gz")) | |
1063 | - | ; (sha256 | |
1064 | - | ; (base32 | |
1065 | - | ; "1i7pdgb8jbw6gdy5kmm0l6rz109n2ns92pqalpyp24vb8vlvdfd4")))) | |
1066 | - | ; (build-system ant-build-system) | |
1067 | - | ; (arguments | |
1068 | - | ; `(#:jar-name "java-woodstox.jar" | |
1069 | - | ; #:source-dir "src/main/java" | |
1070 | - | ; #:tests? #f)) | |
1071 | - | ; (inputs | |
1072 | - | ; `(("java-stax2-api" ,java-stax2-api))) | |
1073 | - | ; (home-page "https://github.com/FasterXML/woodstox") | |
1074 | - | ; (synopsis "") | |
1075 | - | ; (description "") | |
1076 | - | ; (license license:asl2.0))) | |
1077 | - | ||
1078 | - | (define-public java-snakeyaml | |
2366 | + | (define-public java-ops4j-pax-exam-core | |
1079 | 2367 | (package | |
1080 | - | (name "java-snakeyaml") | |
1081 | - | (version "1.18") | |
2368 | + | (name "java-ops4j-pax-exam-core") | |
2369 | + | (version "4.11.0") | |
1082 | 2370 | (source (origin | |
1083 | 2371 | (method url-fetch) | |
1084 | - | (uri (string-append "https://bitbucket.org/asomov/snakeyaml/get/v" | |
1085 | - | version ".tar.gz")) | |
2372 | + | (uri (string-append "https://github.com/ops4j/org.ops4j.pax.exam2/" | |
2373 | + | "archive/exam-reactor-" version ".tar.gz")) | |
1086 | 2374 | (sha256 | |
1087 | 2375 | (base32 | |
1088 | - | "0rf5ha6w0waz50jz2479jsrbgmd0dnx0gs337m126j5z7zlmg7mg")))) | |
1089 | - | (build-system ant-build-system) | |
2376 | + | "0vk87df6m4shhqwd0wmkjklhnnqy98cxbhns06wzvb8rfgcl6wp5")))) | |
1090 | 2377 | (arguments | |
1091 | - | `(#:jar-name "java-snakeyaml.jar" | |
1092 | - | #:source-dir "src/main/java" | |
1093 | - | #:tests? #f)) | |
1094 | - | (home-page "https://bitbucket.org/asomov/snakeyaml") | |
2378 | + | `(#:jar-name "java-ops4j-pax-exam-core.jar" | |
2379 | + | #:source-dir "core/pax-exam/src/main/java" | |
2380 | + | #:test-dir "core/pax-exam/src/test")) | |
2381 | + | (inputs | |
2382 | + | `(("slf4j" ,java-slf4j-api) | |
2383 | + | ("lang" ,java-ops4j-lang) | |
2384 | + | ("io" ,java-ops4j-io) | |
2385 | + | ("util-property" ,java-ops4j-util-property) | |
2386 | + | ("util-store" ,java-ops4j-store) | |
2387 | + | ("java-osgi-core" ,java-osgi-core))) | |
2388 | + | (native-inputs | |
2389 | + | `(("junit" ,java-junit) | |
2390 | + | ("hamcrest" ,java-hamcrest-core))) | |
2391 | + | (build-system ant-build-system) | |
2392 | + | (home-page "https://ops4j1.jira.com/wiki/spaces/PAXEXAM4/overview") | |
1095 | 2393 | (synopsis "") | |
1096 | 2394 | (description "") | |
1097 | - | (license license:asl2.0))); found on wiki.fasterxml.com/JacksonLicensing | |
2395 | + | (license license:asl2.0))) | |
2396 | + | ||
2397 | + | (define-public java-ops4j-pax-exam-core-spi | |
2398 | + | (package | |
2399 | + | (inherit java-ops4j-pax-exam-core) | |
2400 | + | (name "java-ops4j-pax-exam-core-spi") | |
2401 | + | (arguments | |
2402 | + | `(#:jar-name "java-ops4j-pax-exam-spi.jar" | |
2403 | + | #:source-dir "core/pax-exam-spi/src/main/java" | |
2404 | + | #:test-dir "core/pax-exam-spi/src/test")) | |
2405 | + | (inputs | |
2406 | + | `(("java-ops4j-pax-exam-core" ,java-ops4j-pax-exam-core) | |
2407 | + | ("store" ,java-ops4j-store) | |
2408 | + | ("io" ,java-ops4j-io) | |
2409 | + | ("spi" ,java-ops4j-spi) | |
2410 | + | ("osgi" ,java-osgi-core) | |
2411 | + | ("slf4j" ,java-slf4j-api))))) | |
1098 | 2412 | ||
1099 | 2413 | ||
1100 | 2414 | (define-public java-fasterxml-jackson-dataformat-yaml | |
… | |||
1113 | 2427 | (arguments | |
1114 | 2428 | `(#:jar-name "jackson-dataformat-yaml.jar" | |
1115 | 2429 | #:source-dir "src/main/java" | |
1116 | - | #:tests? #f; how to run them? src/test/java | |
1117 | 2430 | #:phases | |
1118 | 2431 | (modify-phases %standard-phases | |
1119 | 2432 | (add-before 'configure 'generate-PackageVersion.java | |
… | |||
1130 | 2443 | `(("java-fasterxml-jackson-annotations" ,java-fasterxml-jackson-annotations) | |
1131 | 2444 | ("java-fasterxml-jackson-core" ,java-fasterxml-jackson-core) | |
1132 | 2445 | ("java-fasterxml-jackson-databind" ,java-fasterxml-jackson-databind) | |
1133 | - | ("java-snakeyaml" ,java-snakeyaml))) | |
2446 | + | ("java-snakeyaml" ,java-snakeyaml-notests))) | |
2447 | + | (native-inputs | |
2448 | + | `(("junit" ,java-junit) | |
2449 | + | ("java-ops4j-pax-exam" ,java-ops4j-pax-exam))) | |
1134 | 2450 | (home-page "https://github.com/FasterXML/jackson-dataformat-yaml") | |
1135 | 2451 | (synopsis "") | |
1136 | 2452 | (description "") | |
… | |||
1321 | 2637 | ("java-bsh" ,java-bsh) | |
1322 | 2638 | ("java-jcommander" ,java-jcommander) | |
1323 | 2639 | ("java-guice" ,java-guice) | |
1324 | - | ("snakeyaml" ,java-snakeyaml))) | |
2640 | + | ("snakeyaml" ,java-snakeyaml-notests))) | |
1325 | 2641 | (native-inputs | |
1326 | 2642 | `(("guava" ,java-guava) | |
1327 | 2643 | ("java-javax-inject" ,java-javax-inject) | |
… | |||
1836 | 3152 | ("java-jdom" ,java-jdom) | |
1837 | 3153 | ("java-tomcat" ,java-tomcat) | |
1838 | 3154 | ("java-avalon-logkit" ,java-avalon-logkit) | |
1839 | - | ;("java-log4j-api" ,java-log4j-api) | |
1840 | - | ;("java-log4j-core" ,java-log4j-core) | |
1841 | 3155 | ("java-log4j-1.2" ,java-log4j-1.2) | |
1842 | - | ("java-commons-logging-minimal" ,java-commons-logging) | |
3156 | + | ("java-commons-logging-minimal" ,java-commons-logging-minimal) | |
1843 | 3157 | ("java-commons-lang" ,java-commons-lang))) | |
1844 | 3158 | (home-page "https://velocity.apache.org/") | |
1845 | 3159 | (synopsis "") | |
… | |||
1881 | 3195 | (string-append "-Ddist.home=" (assoc-ref outputs "out") | |
1882 | 3196 | "/share/java")))))))) | |
1883 | 3197 | (propagated-inputs | |
1884 | - | `(("java-commons-logging" ,java-commons-logging) | |
3198 | + | `(("java-commons-logging" ,java-commons-logging-minimal) | |
1885 | 3199 | ("java-commons-codec" ,java-commons-codec))) | |
1886 | 3200 | (build-system ant-build-system) | |
1887 | 3201 | (home-page "https://hc.apache.org") | |
… | |||
2000 | 3314 | #:tests? #f)) | |
2001 | 3315 | (inputs | |
2002 | 3316 | `(("java-commons-pool2" ,java-commons-pool2) | |
2003 | - | ("java-commons-logging" ,java-commons-logging) | |
3317 | + | ("java-commons-logging" ,java-commons-logging-minimal) | |
2004 | 3318 | ("java-jboss-transaction-api-spec" ,java-jboss-transaction-api-spec))) | |
2005 | 3319 | (native-inputs | |
2006 | 3320 | `(("java-junit" ,java-junit))) | |
… | |||
2031 | 3345 | #:tests? #f)) | |
2032 | 3346 | (inputs | |
2033 | 3347 | `(("java-commons-pool" ,java-commons-pool) | |
2034 | - | ("java-commons-logging" ,java-commons-logging) | |
3348 | + | ("java-commons-logging" ,java-commons-logging-minimal) | |
2035 | 3349 | ("java-jboss-transaction-api-spec" ,java-jboss-transaction-api-spec))))) | |
2036 | 3350 | ||
2037 | 3351 | ||
… | |||
2538 | 3852 | #:jar-name (string-append ,name "-" ,version ".jar") | |
2539 | 3853 | #:source-dir "java-boot-classpath-detector/src/main/java")))) | |
2540 | 3854 | ||
2541 | - | (define-public java-guava | |
2542 | - | (package | |
2543 | - | (name "java-guava") | |
2544 | - | (version "20.0") | |
2545 | - | (source (origin | |
2546 | - | (method url-fetch) | |
2547 | - | (uri (string-append "https://github.com/google/guava/archive/v" | |
2548 | - | version ".tar.gz")) | |
2549 | - | (file-name (string-append name "-" version ".tar.gz")) | |
2550 | - | (sha256 | |
2551 | - | (base32 | |
2552 | - | "1kasavj973iblj1fj35gzbywhkljrnbjpymgqyqaibbbmmbzff8s")))) | |
2553 | - | (build-system ant-build-system) | |
2554 | - | (arguments | |
2555 | - | `(#:jar-name (string-append ,name "-" ,version ".jar") | |
2556 | - | #:source-dir "guava/src" | |
2557 | - | #:tests? #f)) | |
2558 | - | (inputs | |
2559 | - | `(("java-jsr305" ,java-jsr305) | |
2560 | - | ("java-j2objc-annotations" ,java-j2objc-annotations) | |
2561 | - | ("java-animal-sniffer-annotations" ,java-animal-sniffer-annotations) | |
2562 | - | ("java-error-prone-annotations" ,java-error-prone-annotations))) | |
2563 | - | (home-page "https://github.com/google/guava") | |
2564 | - | (synopsis "") | |
2565 | - | (description "") | |
2566 | - | (license license:asl2.0))) | |
2567 | - | ||
2568 | - | ;(define-public java-joda-convert | |
2569 | - | ; (package | |
2570 | - | ; (name "java-joda-convert") | |
2571 | - | ; (version "1.8.1") | |
2572 | - | ; (source (origin | |
2573 | - | ; (method url-fetch) | |
2574 | - | ; (uri (string-append "https://github.com/JodaOrg/joda-convert/archive/v" | |
2575 | - | ; version ".tar.gz")) | |
2576 | - | ; (file-name (string-append name "-" version ".tar.gz")) | |
2577 | - | ; (sha256 | |
2578 | - | ; (base32 | |
2579 | - | ; "1di9chp0pgvd2gxsmdaxhldwns9a2ss9705jmn97mdd69cg5zcnc")))) | |
2580 | - | ; (build-system ant-build-system) | |
2581 | - | ; (arguments | |
2582 | - | ; `(#:jar-name (string-append ,name "-" ,version ".jar") | |
2583 | - | ; #:source-dir "src/main/java" | |
2584 | - | ; #:tests? #f)) | |
2585 | - | ; (inputs | |
2586 | - | ; `(("java-google-collect" ,java-google-collect))) | |
2587 | - | ; (native-inputs | |
2588 | - | ; `(("junit" ,java-junit))) | |
2589 | - | ; (home-page "") | |
2590 | - | ; (synopsis "") | |
2591 | - | ; (description "") | |
2592 | - | ; (license license:asl2.0))) | |
2593 | - | ; | |
2594 | - | ;(define-public java-joda-time | |
3855 | + | ;(define-public java-guava | |
2595 | 3856 | ; (package | |
2596 | - | ; (name "java-joda-time") | |
2597 | - | ; (version "2.9.9") | |
3857 | + | ; (name "java-guava") | |
3858 | + | ; (version "20.0") | |
2598 | 3859 | ; (source (origin | |
2599 | 3860 | ; (method url-fetch) | |
2600 | - | ; (uri (string-append "https://github.com/JodaOrg/joda-time/archive/v" | |
3861 | + | ; (uri (string-append "https://github.com/google/guava/archive/v" | |
2601 | 3862 | ; version ".tar.gz")) | |
2602 | 3863 | ; (file-name (string-append name "-" version ".tar.gz")) | |
2603 | 3864 | ; (sha256 | |
2604 | 3865 | ; (base32 | |
2605 | - | ; "1i9x91mi7yg2pasl0k3912f1pg46n37sps6rdb0v1gs8hj9ppwc1")))) | |
3866 | + | ; "1kasavj973iblj1fj35gzbywhkljrnbjpymgqyqaibbbmmbzff8s")))) | |
2606 | 3867 | ; (build-system ant-build-system) | |
2607 | 3868 | ; (arguments | |
2608 | 3869 | ; `(#:jar-name (string-append ,name "-" ,version ".jar") | |
2609 | - | ; #:source-dir "src/main/java" | |
3870 | + | ; #:source-dir "guava/src" | |
2610 | 3871 | ; #:tests? #f)) | |
2611 | 3872 | ; (inputs | |
2612 | - | ; `(("java-joda-convert" ,java-joda-convert))) | |
2613 | - | ; (native-inputs | |
2614 | - | ; `(("junit" ,java-junit))) | |
2615 | - | ; (home-page "") | |
3873 | + | ; `(("java-jsr305" ,java-jsr305) | |
3874 | + | ; ("java-j2objc-annotations" ,java-j2objc-annotations) | |
3875 | + | ; ("java-animal-sniffer-annotations" ,java-animal-sniffer-annotations) | |
3876 | + | ; ("java-error-prone-annotations" ,java-error-prone-annotations))) | |
3877 | + | ; (home-page "https://github.com/google/guava") | |
2616 | 3878 | ; (synopsis "") | |
2617 | 3879 | ; (description "") | |
2618 | 3880 | ; (license license:asl2.0))) | |
2619 | 3881 | ||
3882 | + | (define-public java-joda-convert | |
3883 | + | (package | |
3884 | + | (name "java-joda-convert") | |
3885 | + | (version "1.8.1") | |
3886 | + | (source (origin | |
3887 | + | (method url-fetch) | |
3888 | + | (uri (string-append "https://github.com/JodaOrg/joda-convert/archive/v" | |
3889 | + | version ".tar.gz")) | |
3890 | + | (file-name (string-append name "-" version ".tar.gz")) | |
3891 | + | (sha256 | |
3892 | + | (base32 | |
3893 | + | "1di9chp0pgvd2gxsmdaxhldwns9a2ss9705jmn97mdd69cg5zcnc")))) | |
3894 | + | (build-system ant-build-system) | |
3895 | + | (arguments | |
3896 | + | `(#:jar-name (string-append ,name "-" ,version ".jar") | |
3897 | + | #:source-dir "src/main/java" | |
3898 | + | #:phases | |
3899 | + | (modify-phases %standard-phases | |
3900 | + | (add-before 'check 'activate-all-tests | |
3901 | + | (lambda _ | |
3902 | + | (substitute* "build.xml" | |
3903 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
3904 | + | (string-append "<include name=\"**/Test*.java\" />" | |
3905 | + | "<exclude name=\"**/test*/**.java\" />")))))))) | |
3906 | + | (inputs | |
3907 | + | `(("java-guava" ,java-guava))) | |
3908 | + | (native-inputs | |
3909 | + | `(("junit" ,java-junit) | |
3910 | + | ("hamcrest" ,java-hamcrest-core))) | |
3911 | + | (home-page "") | |
3912 | + | (synopsis "") | |
3913 | + | (description "") | |
3914 | + | (license license:asl2.0))) | |
3915 | + | ||
3916 | + | (define-public java-joda-time | |
3917 | + | (package | |
3918 | + | (name "java-joda-time") | |
3919 | + | (version "2.9.9") | |
3920 | + | (source (origin | |
3921 | + | (method url-fetch) | |
3922 | + | (uri (string-append "https://github.com/JodaOrg/joda-time/archive/v" | |
3923 | + | version ".tar.gz")) | |
3924 | + | (file-name (string-append name "-" version ".tar.gz")) | |
3925 | + | (sha256 | |
3926 | + | (base32 | |
3927 | + | "1i9x91mi7yg2pasl0k3912f1pg46n37sps6rdb0v1gs8hj9ppwc1")))) | |
3928 | + | (build-system ant-build-system) | |
3929 | + | (arguments | |
3930 | + | `(#:jar-name "java-joda-time.jar" | |
3931 | + | #:source-dir "src/main/java" | |
3932 | + | #:phases | |
3933 | + | (modify-phases %standard-phases | |
3934 | + | (add-after 'build 'build-resources | |
3935 | + | (lambda _ | |
3936 | + | (mkdir-p "build/classes/org/joda/time/tz/data") | |
3937 | + | (mkdir-p "build/classes/org/joda/time/format") | |
3938 | + | ;; This will produce an exception, but it's all right. | |
3939 | + | (zero? (system* "java" "-cp" (string-append "build/classes:" (getenv "CLASSPATH")) | |
3940 | + | "org.joda.time.tz.ZoneInfoCompiler" | |
3941 | + | "-src" "src/main/java/org/joda/time/tz/src" | |
3942 | + | "-dst" "build/classes/org/joda/time/tz/data" | |
3943 | + | "africa" "antarctica" "asia" "australasia" | |
3944 | + | "europe" "northamerica" "southamerica" | |
3945 | + | "pacificnew" "etcetera" "backward" "systemv")) | |
3946 | + | (for-each (lambda (f) | |
3947 | + | (copy-file f (string-append | |
3948 | + | "build/classes/org/joda/time/format/" | |
3949 | + | (basename f)))) | |
3950 | + | (find-files "src/main/java/org/joda/time/format" ".*.properties")))) | |
3951 | + | (add-before 'install 'regenerate-jar | |
3952 | + | (lambda _ | |
3953 | + | ;; We need to regenerate the jar file to add generated data. | |
3954 | + | (delete-file "build/jar/java-joda-time.jar") | |
3955 | + | (zero? (system* "jar" "-cf" "build/jar/java-joda-time.jar" "-C" | |
3956 | + | "build/classes" ".")))) | |
3957 | + | (add-before 'check 'copy-test-resources | |
3958 | + | (lambda _ | |
3959 | + | (mkdir-p "build/test-classes/org/joda/time/tz/data") | |
3960 | + | (copy-file "src/test/resources/tzdata/ZoneInfoMap" | |
3961 | + | "build/test-classes/org/joda/time/tz/data/ZoneInfoMap") | |
3962 | + | (for-each (lambda (file) | |
3963 | + | (copy-file file (string-append "build/test-classes/" | |
3964 | + | (basename file)))) | |
3965 | + | (find-files "src/test/resources/" ".*")))) | |
3966 | + | (add-before 'check 'exclude-non-tests | |
3967 | + | (lambda _ | |
3968 | + | (substitute* "build.xml" | |
3969 | + | (("<include name=\"\\*\\*/\\*Test.java\" />") | |
3970 | + | (string-append "<include name=\"**/Test*.java\" />" | |
3971 | + | "<exclude name=\"**/Test*Chronology.java\" />" | |
3972 | + | "<exclude name=\"**/Test*Field.java\" />")))))))) | |
3973 | + | (inputs | |
3974 | + | `(("java-joda-convert" ,java-joda-convert))) | |
3975 | + | (native-inputs | |
3976 | + | `(("junit" ,java-junit) | |
3977 | + | ("hamcrest" ,java-hamcrest-core) | |
3978 | + | ("tzdata" ,tzdata))) | |
3979 | + | (home-page "") | |
3980 | + | (synopsis "") | |
3981 | + | (description "") | |
3982 | + | (license license:asl2.0))) | |
3983 | + | ||
2620 | 3984 | (define-public java-xstream | |
2621 | 3985 | (package | |
2622 | 3986 | (name "java-xstream") | |
… | |||
2717 | 4081 | (arguments | |
2718 | 4082 | `(#:jar-name (string-append ,name "-" ,version ".jar") | |
2719 | 4083 | #:tests? #f | |
2720 | - | #:source-dir "src/main")))) | |
4084 | + | #:source-dir "src/main" | |
4085 | + | #:phases | |
4086 | + | (modify-phases %standard-phases | |
4087 | + | (add-before 'build 'generate-parser | |
4088 | + | (lambda _ | |
4089 | + | (with-directory-excursion "src/main/org/codehaus/groovy/antlr/java" | |
4090 | + | (zero? (system* "antlr4" "java.g")))))))))) | |
2721 | 4091 | ||
2722 | 4092 | ||
2723 | 4093 | ;(define-public antlr3-3.4 | |
… | |||
2851 | 4221 | (build-system ant-build-system) | |
2852 | 4222 | (arguments | |
2853 | 4223 | `(#:jar-name (string-append ,name "-" ,version ".jar") | |
2854 | - | #:tests? #f | |
2855 | 4224 | #:jdk ,icedtea-8 | |
4225 | + | #:tests? #f; no tests | |
2856 | 4226 | #:source-dir "src" | |
2857 | 4227 | #:phases | |
2858 | 4228 | (modify-phases %standard-phases |