ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From RAPPAZ Francois <francois.rap...@unifr.ch>
Subject RE: GenJar
Date Thu, 23 Nov 2017 07:00:23 GMT

MG>which specific task do you want ant to implement?

Make a jar using the regular ant jar task:
With using a file selector that 
- start with the class file having the main function called to start the application
- takes all the class it depends on, extract the corresponding class file from the jar archive
(using the path to find the archive), add this extracted class file in the jar under construction
- repeat this for the class that has been extracted

This is what genjar is doing (or PAR::Packer in perl) but it's a task in himself not a selector
in the regular jar task, and it's very convenient to have these  autonomous archive when you
want to distribute an application.

Fran├žois

MG>implement bcel regular expression code patterns?
MG>using Repository to lookup a clazz?
MG>using ClassGen to create files?
MG>something else?
https://commons.apache.org/proper/commons-bcel/manual/bcel-api.html
Apache Commons BCELT - The BCEL API<https://commons.apache.org/proper/commons-bcel/manual/bcel-api.html>
commons.apache.org
The BCEL API. The BCEL API abstracts from the concrete circumstances of the Java Virtual Machine
and how to read and write binary Java class files.




Is there examples of codes of these custom selectors ?

Correcting the original genjar code proved to be < 50 lines changes Writing this selector
from scratch is quiet harder for me

Fran├žois

-----Original Message-----
From: Dominique Devienne [mailto:ddevienne@gmail.com]
Sent: 21 November 2017 15:18
To: Ant Users List <user@ant.apache.org>
Subject: Re: GenJar

On Tue, Nov 21, 2017 at 11:19 AM, RAPPAZ Francois <francois.rappaz@unifr.ch>
wrote:

> Things turned out well at the end...
>
> since I could contact the original maintainer of genjar on sourceforge 
> and I was able to update my changes there.
>
> Note that this tool had some descendants. I have found on github:
> mx:genjar, genjar2.
>

All these IMHO are misguided in that they replace <jar> instead of just providing a
smarter BCEL-powered (or other) selector within <jar>.
Maybe I underestimate how easy that is perhaps though... --DD

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message